Пример #1
0
 /// <summary>
 /// Remove a specific collider from being checked for collisions by the Manager.
 /// </summary>
 /// <param name="collider">The collider to remove.</param>
 public static void RemoveCollider(BoxCollider collider)
 {
     removedColliders.Add(collider);
 }
Пример #2
0
 public override void LoadContent()
 {
     Tag      = "Portal";
     Collider = new BoxCollider(this, (int)(SpriteRect.Width * colliderExtension), (int)(SpriteRect.Height * colliderExtension), true);
     Collider.OnCollisionEnter += OnCollisionEnter;
 }
Пример #3
0
 /// <summary>
 /// Register a collider for collision checks in the Manager.
 /// </summary>
 /// <param name="collider">The collider to add.</param>
 public static void AddCollider(BoxCollider collider)
 {
     colliders.Add(collider);
 }