Esempio n. 1
0
        void AddWarning(UInt64 owner)
        {
            Ientity            ownerEntity = EntityManager.AllEntitys[owner];
            BuildingAtkWarning warning     = new BuildingAtkWarning();

            warning.CreateCircleRes(ownerEntity);
            objDic.Add(warning, ownerEntity);
        }
Esempio n. 2
0
 bool ContainWarning(Ientity entity)
 {
     for (int i = objDic.Count - 1; i >= 0; i--)
     {
         BuildingAtkWarning warning = objDic.ElementAt(i).Key;
         if (warning.GetTarget() == entity)
         {
             return(true);
         }
     }
     return(false);
 }
Esempio n. 3
0
 public void OnUpdate()
 {
     if (objDic == null || objDic.Count == 0)
     {
         return;
     }
     for (int i = objDic.Count - 1; i >= 0; i--)
     {
         BuildingAtkWarning warning = objDic.ElementAt(i).Key;
         warning.OnUpdate();
     }
 }
Esempio n. 4
0
 public void RemoveWarning(BuildingAtkWarning warning)
 {
     warning.Clean();
     objDic.Remove(warning);
     warning = null;
 }