Doing it your way would be something like:
give the boat an instance variable: angleframe
a key is down : set boat.angleframe to boat.angleframe-1
d key is down : set boat.angleframe to boat.angleframe+1
system compare two values: boat.angleframe=360 - set boat.angleframe : 0
system compare two values: boat.angleframe=-1 - set boat.angleframe : 359
every tick - boat set frame to: boat.angleframe
Btw instead of making the firing point on every frame why not make an invisible sprite with the imagepoints in the right place and rotate it to the angle of the boat.animationframe?
It would actually be far wiser to rotate your boatsprite itself instead of having animation for each angle..
You could have a few frames to give the impression of 3D but this seems like overkill..