The object (usually stored in data.json) containing the full project data
Set if the session should be registered.
Returns if the game resolution should be automatically adapted when the game window or screen size change. This will only be the case if the game resolution resize mode is configured to adapt the width or the height of the game.
true if the game resolution is automatically changed according to the window/screen size.
Return the additional options passed to the RuntimeGame when created.
The additional options, if any.
Return the antialiasing mode used by the game ("none" or "MSAA").
Get the gdjs.BitmapFontManager of the RuntimeGame.
The bitmap font manager.
Get the effects manager of the game, which allows to manage effects on runtime objects or runtime layers.
The effects manager for the game
Gets an extension property from the project data.
The extension name.
The property name.
The property value.
Get the data associated to an external layout.
The name of the external layout.
The data associated to the external layout or null if not found.
Get the gdjs.FontManager of the RuntimeGame.
The font manager.
Get the object containing the game data
The object associated to the game.
Get the game resolution (the size at which the game is played and rendered) height.
The game resolution height, in pixels.
Returns if the width or the height of the game resolution should be changed to fit the game window - or if the game resolution should not be updated automatically (empty string).
Either "" (don't change game resolution), "adaptWidth" or "adaptHeight".
Get the game resolution (the size at which the game is played and rendered) width.
The game resolution width, in pixels.
Get the gdjs.ImageManager of the RuntimeGame.
The image manager.
Get the data representing all the global objects of the game.
The data associated to the global objects.
Get the input manager of the game, storing mouse, keyboard and touches states.
The input manager owned by the game
Get the JSON manager of the game, used to load JSON from game resources.
The json manager for the game
Return the minimal fps that must be guaranteed by the game (otherwise, game is slowed down).
Get the 3D model manager of the game, used to load 3D model from game resources.
The 3D model manager for the game
Get the original height of the game, as set on the startup of the game.
This is guaranteed to never change, even if the size of the game is changed afterwards.
Get the original width of the game, as set on the startup of the game.
This is guaranteed to never change, even if the size of the game is changed afterwards.
Return if the game is rounding pixels when rendering.
Return the scale mode of the game ("linear" or "nearest").
Get the data associated to a scene.
The name of the scene. If not defined, the first scene will be returned.
The data associated to the scene.
Return the stack of gdjs.RuntimeScene being played.
Get the gdjs.SoundManager of the RuntimeGame.
The sound manager.
Get the variables of the RuntimeGame.
The global variables
true during the first frame the game is back from being hidden.
This has nothing to do with _paused
.
Check if a scene exists
The name of the scene to search.
true if the scene exists. If sceneName is undefined, true if the game has a scene.
Return true if antialising is enabled on mobiles.
Check if the game is running as a preview, launched from an editor.
true if the current game is a preview.
Check if the game should call GDevelop development APIs or not.
Unless you are contributing to GDevelop, avoid using this.
Load all assets, displaying progress in renderer.
Called by the game renderer when the window containing the game has changed size (this can result from a resize of the window, but also other factors like a device orientation change on mobile).
Set or unset the game as paused. When paused, the game won't step and will be freezed. Useful for debugging.
true to pause the game, false to unpause
Resolves the name of an embedded resource.
The name of the resource containing the embedded resource.
The name of the embedded resource.
The resource name.
Set if the game resolution should be automatically adapted when the game window or screen size change. This will only be the case if the game resolution resize mode is configured to adapt the width or the height of the game.
true to change the game resolution according to the window/screen size.
Set if the width or the height of the game resolution should be changed to fit the game window - or if the game resolution should not be updated automatically.
Either "" (don't change game resolution), "adaptWidth" or "adaptHeight".
Change the game resolution.
The new width
The new height
Update the project data. Useful for hot-reloading, should not be used otherwise.
The object (usually stored in data.json) containing the full project data
Start the game loop, to be called once assets are loaded.
Stop the profiler for the currently running scene.
Return true if a scene was loaded, false otherwise (i.e: game not yet started).
Generated using TypeDoc
Represents a game being played.