Example #1
0
 public CollisionBody(TransformableEntity entity, CollisionShape shape)
     : this()
 {
     Owner = entity;
     Shape = shape;
 }
Example #2
0
 // shortcut
 public static IWrappedBody CreateBody(TransformableEntity entity, CollisionShape shape)
 {
     return Create(entity, shape) as IWrappedBody;
 }
Example #3
0
 public static CollisionBody Create(TransformableEntity entity, CollisionShape shape)
 {
     CollisionBody collider = Pool.Acquire<CollisionBody>();
     collider.Owner = entity;
     collider.Shape = shape;
     collider.OnCollision += collider.HandleOnCollision;
     collider.BeforeCollision += collider.HandleBeforeCollision;
     return collider;
 }
Example #4
0
 // shortcut
 public static IWrappedBody CreateBody(CollisionShape shape)
 {
     return Create(null, shape) as IWrappedBody;
 }