Module mob.bat
Bat class, subclass of Mob .
A bat monster!
LIFE = 50
SPEED = 50
STATE = 'stop|walk'
State machine
Bat:_stopState (dt) | “stop” state of the state machine. |
Bat:_walkState (dt) | “walk” state of the state machine. |
Class Bat
Bat:initialize (x, y, level) | Initialize the object Bat . |
State machine
State machine.- Bat:_stopState (dt)
-
“stop” state of the state machine. The bat is stoped.
Parameters:
- dt delta time
- Bat:_walkState (dt)
-
“walk” state of the state machine. The bat is flying.
Parameters:
- dt delta time