World

World

Methods


get_game_pause()

Code Equivalent:
game.paused

get_world_property(property)

Parameters:
Name Type Description
property

property to get values from

Code Equivalent:
game.world.property

set_game_pause(paused)

Parameters:
Name Type Description
paused Boolean

sets the game paused to true or false

Code Equivalent:
game.paused = paused;

set_scale(x, y, object)

Parameters:
Name Type Description
x Number

amount to scale the object in the x direction

y Number

amount to scale the object in the y direction

object

object to scale

Code Equivalent:
object.scale.setTo(x, y);

set_world_bounds(x, y, w, h)


Sets the top-left coordinates and size/physical bounds of the game world.

Check out the third party documentation for a more in depth explanation.

Parameters:
Name Type Description
x Number

the x coordinate of the top-left corner of the world

y Number

the y coordinate of the top-left corner of the world

w Number

the width of the game world

h Number

the height of the game world

Code Equivalent:
game.world.setBounds(x, y, w, h);