Anonymous Login
2018-05-23 18:36 UTC

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0001927OpenClonkEnginepublic2017-07-13 14:57
Assigned To 
Product Version 
Target VersionFixed in Version 
Summary0001927: Feature Request: Pause/Resume the game via script
DescriptionI want to be able to "pause" and "resume" the game via function call(s). Ideally, the GUI, menu and controls would still work while the game is "paused".

This means that objects must not move, the landscape must not change, particles and effects must not advance their lifetime.

Maybe this could be solved by a script effect, instead of adding an engine function. The purpose is to have a custom ingame menu that you can operate, while not worrying about other objects/timeouts/whatever. Pausing the game in such a way can be a potential drawback in network games, right?
TagsNo tags attached.
Attached Files




Luchs (administrator)

There is already PauseGame(), but you obviously can't resume with that.


K-Pone (developer)

@Luchs: In theory you could resume via /script, but this seems kinda useless since you could simply press Pause instead. Although there might be some use for it if used by /script when it's part of a custom function, but I just can't imagine any for now.


Marky (developer)

The crucial part is where this pause function should still allow the interaction with GUIs, so it is not exactly the same as the ingame pause?
I know that pausing the game allows interaction with the player menu (switch music on/off, save the game), but it is not possible to interact with the interaction menu (the one that you get by pressing [E]).
This is also a tricky part. I requested that effects do not get executed, but the interaction menu works with effects internally :(


Sven2 (developer)

Last edited: 2017-07-13 01:42

View 2 revisions

The control queue is not run in paused mode, so any queued command cannot be executed. Some stuff like music is allowed because it doesn't affect synchronization. But pretty much any script command needs to be queued.

We could allow resuming as a special GUI action. But what exactly is the use case for this?


Marky (developer)

I want to be able to open a menu, for example an inventory or option menu, do some stuff there, then close it. Meanwhile, outside of the menu, the game state should be frozen: Enemies should not move/attack, objects should not fall, etc.
The words "paused"(or whatever happens when you normally pause the game) should not appear on screen in this state. There are many games that handle inventory selection and other things like that, but it is useful for single player only.

This is not needed in the base game, in my opinion.

-Issue History
Date Modified Username Field Change
2017-06-29 15:31 Marky New Issue
2017-06-29 18:33 Luchs Note Added: 0005685
2017-07-01 15:20 K-Pone Note Added: 0005686
2017-07-02 14:39 Marky Note Added: 0005687
2017-07-13 01:42 Sven2 Note Added: 0005694
2017-07-13 01:42 Sven2 Note Edited: 0005694 View Revisions
2017-07-13 14:57 Marky Note Added: 0005695
+Issue History