diff options
Diffstat (limited to 'core/config/engine.cpp')
-rw-r--r-- | core/config/engine.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/core/config/engine.cpp b/core/config/engine.cpp index 2735a1aa67..bcec1a0ad4 100644 --- a/core/config/engine.cpp +++ b/core/config/engine.cpp @@ -119,6 +119,10 @@ void Engine::set_time_scale(double p_scale) { } double Engine::get_time_scale() const { + return freeze_time_scale ? 0 : _time_scale; +} + +double Engine::get_unfrozen_time_scale() const { return _time_scale; } @@ -457,6 +461,10 @@ bool Engine::notify_frame_server_synced() { return server_syncs > SERVER_SYNC_FRAME_COUNT_WARNING; } +void Engine::set_freeze_time_scale(bool p_frozen) { + freeze_time_scale = p_frozen; +} + Engine::Engine() { singleton = this; } |