예제 #1
0
        public static void ProcessCollision(GameObject obj, GameObject obj2)
        {
            // If an overlap is not detected, end the narrow testing here.
            if (!CollideDetect.IsOverlapping(obj, obj2))
            {
                return;
            }

            // Order the objects by archetype, and run them through the collision map.
            if (obj.Meta.Archetype < obj2.Meta.Archetype)
            {
                CollideNarrow.RefineCollision(obj, obj2);
            }
            else
            {
                CollideNarrow.RefineCollision(obj2, obj);
            }
        }