예제 #1
0
 public override void Update()
 {
     if (ClickFlag == true)
     {
         Thunderbolt_X = 0;
         List <Creature> CList = Land.GetCList(clickPosition);
         foreach (Creature creature in CList)
         {
             creature.HP = 0;
         }
         ClickFlag = false;
     }
 }
예제 #2
0
 public override void Update()
 {
     if (ClickFlag == true)
     {
         float           temDistance = 10000;//同エリア内でのカーソルと生物との暫定最短距離
         List <Creature> CList       = Land.GetCList(clickPosition);
         foreach (Creature creature in CList.Where(x => x.Alive))
         {
             Vector2D creaturePos = clickPosition - creature.Position;
             if (temDistance > creaturePos.SquareLength)
             {
                 temDistance = creaturePos.SquareLength;
                 Object      = creature;
             }
         }
         ClickFlag = false;
     }
 }