true when all the resources of the given scene are loaded (but maybe not parsed).
true when all the resources of the given scene are loaded and parsed.
Stop game loop, unload all scenes, dispose renderer and resources. After calling this method, the RuntimeGame should not be used anymore.
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
Returns the array of resources that are embedded to passed one.
The name of resource to find embedded resources of.
The array of related resources names.
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.
Helper function to get information about the platform running the game.
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.
The progress of assets loading in background for a scene (between 0 and 1).
Return the stack of gdjs.RuntimeScene being played.
Get the gdjs.SoundManager of the RuntimeGame.
The sound manager.
Get the Spine Atlas manager of the game, used to load atlases from game resources.
The Spine Atlas manager for the game
Get the Spine manager of the game, used to load and construct spine skeletons from game resources.
The Spine manager for the game
Get the variables of the RuntimeGame.
The global variables
Get the extension's global variables.
The extension name.
The extension's 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 needed to display the 1st scene, displaying progress in renderer.
Load all assets needed to display the 1st scene, displaying progress in renderer.
When a game is hot-reload, this method can be called with the current scene.
Load all assets for a given scene, 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
Preload a scene assets as soon as possible in background.
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).
The object (usually stored in data.json) containing the full project data
Generated using TypeDoc
Represents a game being played.