summary refs log tree commit diff stats
path: root/src/sprite.h
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2021-02-21 12:31:55 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2021-02-21 12:31:55 -0500
commitecbe17b582803aaeaa9ccee88a3d093ff93a6cd3 (patch)
treeb7e14ae55b6c38992598b8571ed217bc8f249887 /src/sprite.h
parentf0eab98e417bf648261a9027bef91fe935af76cb (diff)
downloadtanetane-ecbe17b582803aaeaa9ccee88a3d093ff93a6cd3.tar.gz
tanetane-ecbe17b582803aaeaa9ccee88a3d093ff93a6cd3.tar.bz2
tanetane-ecbe17b582803aaeaa9ccee88a3d093ff93a6cd3.zip
Added sprite pausing
All sprites are now paused when a cutscene starts and unpaused when it ends. Pausing means that the CharacterSystem and BehaviourSystem will not process them in their tick. This allows specific sprites to be unpaused during cutscenes if movement is needed.

The player character is halted and made non-controllable by the script when the cutscene starts and made controllable again when it ends. It is important to remember that if interacting with a sprite that might be moving, you have to manually call Halt() on them in their script to make them stop moving.
Diffstat (limited to 'src/sprite.h')
-rw-r--r--src/sprite.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/sprite.h b/src/sprite.h index 4e3e490..35ca7aa 100644 --- a/src/sprite.h +++ b/src/sprite.h
@@ -43,6 +43,7 @@ public:
43 43
44 std::string alias; 44 std::string alias;
45 bool persistent = false; 45 bool persistent = false;
46 bool paused = false;
46 47
47 // Transform 48 // Transform
48 vec2i loc { 0, 0 }; 49 vec2i loc { 0, 0 };