Skip to content

Utilities

selimanac edited this page Jan 23, 2025 · 2 revisions

daabbcc3d.reset()

Removes all AABBs, groups, and game objects, resetting to the initial state. It is recommended to reset the DAABBC when you're done with it (e.g., when your game or level is over).

Example

daabbcc3d.reset()

daabbcc3d.run(state)

Pause or resume the internal game object position update iteration. This is enabled by default but will not iterate if no game objects are registered. Pausing the iteration can free up compute power (e.g., when the game is paused).

Parameters

  • state (boolean) - Pause or resume

Example

local state = true
daabbcc3d.run(state)

daabbcc3d.update_frequency(frequency)

It is possible to set an independent update frequency for the game object position update iteration. The default value is taken from the display.frequency setting in the game.project file. The update loop follows the same structure as in the Defold source.

This can be very useful if you're running a headless build on a server.

Parameters

  • frequency (int32) - Update frequency

Example

local frequency = 60
daabbcc3d.update_frequency(frequency)