Example #1
0
        public static bool IsIgnoring(Collider.Collider c1, Collider.Collider c2)
        {
            ReactType reaction1 = c1.GetReaction(c2.GetCollisionChanell());
            ReactType reaction2 = c2.GetReaction(c1.GetCollisionChanell());

            return(reaction1 == ReactType.Ignore || reaction2 == ReactType.Ignore);
        }
Example #2
0
        /// <summary>
        /// Sprawdza, czy dane collidery blokują się ze sobą.
        /// </summary>
        public static bool IsBlocking(Collider.Collider c1, Collider.Collider c2)
        {
            bool reaction1 = c1.GetReaction(c2.GetCollisionChanell()).Equals(ReactType.Block);
            bool reaction2 = c2.GetReaction(c1.GetCollisionChanell()).Equals(ReactType.Block);

            return((reaction1 == reaction2) && reaction1);
        }