Module box2d

Box2D plugin for STI

Info:

  • Copyright: 2017
  • License: MIT/X11
  • Author: Landon Manning

Functions

box2d_draw (tx, ty, sx, sy) Draw Box2D physics world.
box2d_init (world) Initialize Box2D physics world.
box2d_removeLayer (index) Remove Box2D fixtures and shapes from world.

Tables

Properties Custom Properties in Tiled are used to tell this plugin what to do.


Functions

box2d_draw (tx, ty, sx, sy)
Draw Box2D physics world.

Parameters:

  • tx Translate on X
  • ty Translate on Y
  • sx Scale on X
  • sy Scale on Y
box2d_init (world)
Initialize Box2D physics world.

Parameters:

  • world The Box2D world to add objects to.
box2d_removeLayer (index)
Remove Box2D fixtures and shapes from world.

Parameters:

  • index The index or name of the layer being removed

Tables

Properties
Custom Properties in Tiled are used to tell this plugin what to do.

Fields:

  • collidable set to true, can be used on any Layer, Tile, or Object
  • sensor set to true, can be used on any Tile or Object that is also collidable
generated by LDoc 1.4.6 Last updated 2017-05-18 17:36:07