Example #1
0
 private void Obj_AI_Hero_OnBuffRemove(Obj_AI_Base sender, Obj_AI_BaseBuffRemoveEventArgs args)
 {
     if (!sender.IsMe)
     {
         return;
     }
     if (args.Buff.Name.Equals(this.tahmEatPassive.ToLower()))
     {
         this.swallowedUnit           = SwallowedUnit.None;
         this.lastPosBeforeSwallowing = Vector3.Zero;
     }
 }
Example #2
0
 private void Obj_AI_Hero_OnBuffAdd(Obj_AI_Base sender, Obj_AI_BaseBuffAddEventArgs args)
 {
     if (args.Buff.Name.Equals(this.tahmEatingPassive))
     {
         this.lastPosBeforeSwallowing = ObjectManager.Player.Position;
         var hero = sender as Obj_AI_Hero;
         if (hero != null)
         {
             if (hero.IsAlly)
             {
                 this.swallowedUnit = SwallowedUnit.Ally;
             }
             else
             {
                 this.swallowedUnit = SwallowedUnit.Enemy;
             }
             return;
         }
         var minion = sender as Obj_AI_Minion;
         if (minion != null)
         {
             this.swallowedUnit = SwallowedUnit.Minion;
         }
     }
     else if (args.Buff.Name.Equals(this.tahmEatPassive.ToLower()) && !this.swallowedUnit.HasFlag(SwallowedUnit.Enemy | SwallowedUnit.Ally))
     {
         this.lastPosBeforeSwallowing = ObjectManager.Player.Position;
         var hero = sender as Obj_AI_Hero;
         if (hero != null)
         {
             if (hero.IsAlly)
             {
                 this.swallowedUnit = SwallowedUnit.Ally;
             }
         }
     }
 }
Example #3
0
 private void Obj_AI_Hero_OnBuffRemove(Obj_AI_Base sender, Obj_AI_BaseBuffRemoveEventArgs args)
 {
     if (!sender.IsMe)
     {
         return;
     }
     if (args.Buff.Name.Equals(this.tahmEatPassive.ToLower()))
     {
         this.swallowedUnit = SwallowedUnit.None;
         this.lastPosBeforeSwallowing = Vector3.Zero;
     }
 }
Example #4
0
 private void Obj_AI_Hero_OnBuffAdd(Obj_AI_Base sender, Obj_AI_BaseBuffAddEventArgs args)
 {
     if (args.Buff.Name.Equals(this.tahmEatingPassive))
     {
         this.lastPosBeforeSwallowing = ObjectManager.Player.Position;
         var hero = sender as Obj_AI_Hero;
         if (hero != null)
         {
             if (hero.IsAlly)
             {
                 this.swallowedUnit = SwallowedUnit.Ally;
             }
             else
             {
                 this.swallowedUnit = SwallowedUnit.Enemy;
             }
             return;
         }
         var minion = sender as Obj_AI_Minion;
         if (minion != null)
         {
             this.swallowedUnit = SwallowedUnit.Minion;
         }
     }
     else if (args.Buff.Name.Equals(this.tahmEatPassive.ToLower()) && !this.swallowedUnit.HasFlag(SwallowedUnit.Enemy | SwallowedUnit.Ally))
     {
         this.lastPosBeforeSwallowing = ObjectManager.Player.Position;
         var hero = sender as Obj_AI_Hero;
         if (hero != null)
         {
             if (hero.IsAlly)
             {
                 this.swallowedUnit = SwallowedUnit.Ally;
             }
         }
     }
 }