Example #1
0
        //Clear EntityWaitingList and Import all Entity From Current Player
        public void GetEntityListFromCurrPlayer()
        {
            List <Entity> tampon = ListPlayer[CurrPlayerNumber].EntityList;

            EntityWaitingList.Clear();
            foreach (Entity e in tampon)
            {
                if (e.Pos != -1)
                {
                    EntityWaitingList.Add(e);
                }
            }
        }
Example #2
0
 //Get the first Entity in EntityWaitingList, set it as currentEntity and remove it from EntityWaitingList. If there is no more entity waiting, currEntity=null
 public bool SetCurrentEntity()
 {
     if (EntityWaitingList.Count > 0)
     {
         CurrEntity = EntityWaitingList[0];
         EntityWaitingList.Remove(CurrEntity);
         return(true);
     }
     else
     {
         CurrEntity = null;
         return(false);
     }
 }