b2w_createDynamicBody function

  1. @Native<Int64 Function(Int64, Float, Float, Float)>(ffi.Int64, ffi.Float, ffi.Float, ffi.Float)>()
int b2w_createDynamicBody(
  1. int worldHandle,
  2. double posX,
  3. double posY,
  4. double angle,
)

Create a dynamic body at (posX, posY), turned by angle. Returns its handle; 0 when the world has gone. Same as b2w_createBody with B2W_BODY_DYNAMIC.

Implementation

@ffi.Native<ffi.Int64 Function(ffi.Int64, ffi.Float, ffi.Float, ffi.Float)>()
external int b2w_createDynamicBody(
  int worldHandle,
  double posX,
  double posY,
  double angle,
);