Quote:
Originally Posted by khortez
And in temp.x , does(player.dir[1]) mean the first direction?
|
No, it's erroneous and means nothing.
These are the directions in numbers:
0: Up
1: Left
2: Down
3: Right
Quote:
Originally Posted by khortez
In (temp.angle = (pi / 2) * (player.dir + 1);
Also does player.dir + 1 mean the first direction?
|
No, it's the player's current direction plus one. The entire line is used to convert the player's current direction into an angle value so it can be used with
shoot().