Ejemplo n.º 1
0
        //////////////////////////////////////////////////////////////////////////////

        #region Collider

        protected override bool HandleCollision(MovableCell other)
        {
            Debug.Assert(isActive);

            if (other.IsPlayer())
            {
                return(other.AsPlayer().HandleCollision(this));
            }

            if (other.IsBomb())
            {
                return(HandleCollision(other.AsBomb()));
            }

            if (other.IsObstacle())
            {
                return(HandleObstacleCollistion(other));
            }

            return(false);
        }
Ejemplo n.º 2
0
        protected override bool HandleCollision(MovableCell other)
        {
            Debug.Assert(isActive);

            if (other.IsPlayer())
            {
                return other.AsPlayer().HandleCollision(this);
            }

            if (other.IsBomb())
            {
                return HandleCollision(other.AsBomb());
            }

            if (other.IsObstacle())
            {
                return HandleObstacleCollistion(other);
            }

            return false;
        }