コード例 #1
0
        public bool CheckAliens(ShieldPart inObj)
        {
            ListNode ptr = (ListNode)Aliens.getActiveHead();

            while (ptr != null)
            {
                Alien temp = (Alien)ptr.getData();

                if (temp.iSCollide(inObj.getCollisionObjRectangle()))
                {
                    GameObjMananger.getInstance().KillObject(inObj, SpriteBatchName.Shields);
                    return(true);
                }

                ptr = (ListNode)ptr.pNext;
            }

            return(false);
        }
コード例 #2
0
        public bool CheckParts(Super inSuper)
        {
            ListNode ptr = (ListNode)ShieldParts.getActiveHead();

            while (ptr != null)
            {
                ShieldPart temp = (ShieldPart)ptr.getData();

                if (inSuper.CheckColumns(temp))
                {
                    ListNode inTemp = (ListNode)ptr.pNext;
                    ShieldParts.Remove(ptr);
                    ptr = inTemp;
                }
                else
                {
                    ptr = (ListNode)ptr.pNext;
                }
            }

            return(true);
        }