halo (Posted 16 hours ago)
Why do you comment? Why write the code twice?
Okay smart guy, tell me what this does:
AniBOB_PositionX(ThisEnemy\BOB, -32, 200-32, 500, 3, 1, 0, False, 0) AniBOB_PositionY(ThisEnemy\BOB, 500, 100, 1000, 0, 0, 0, True, 0)
No idea? That's not surprising. Heck, I wrote that function and I couldn't even tell you what that line does exactly. Not without searching for the function and reading the names of the parameters.
But if I comment that line like so:
; AniBOB_Frame(BOB.BOB, Start_Frame, End_Frame, Anim_Time, Anim_Mode, Anim_Velocity, New_Image=0, Trigger_Delay=0, Free_BOB=False, StartAge=0) AniBOB_PositionX(ThisEnemy\BOB, -32, 200-32, 500, 3, 1, 0, False, 0) AniBOB_PositionY(ThisEnemy\BOB, 500, 100, 1000, 0, 0, 0, True, 0)
Well now I have a lot more information. I'll still have to look up Anim_Time and Anim_Mode to see what they are six months from now, but right now at least I remember what the different values mean.
A better comment however would be the following, becayse while the above does show me what the function parameters mean, it doesn't tell me what that code DOES.
; AniBOB_Frame(BOB.BOB, Start_Frame, End_Frame, Anim_Time, Anim_Mode, Anim_Velocity, New_Image=0, Trigger_Delay=0, Free_BOB=False, StartAge=0) ; Make enemy follow a half circle path emerging from the left side of the screen. AniBOB_PositionX(ThisEnemy\BOB, -32, 200-32, 500, 3, 1, 0, False, 0) AniBOB_PositionY(ThisEnemy\BOB, 500, 100, 1000, 0, 0, 0, True, 0)