Advertisement
sibble

Untitled

Mar 24th, 2015
306
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.00 KB | None | 0 0
  1.                 #region Revenant check
  2.  
  3.                 //check to see if there are revenant types around
  4.                 List<Item> RevenantType = Find.FindItems(400).OrderBy(s => s.Distance).ToList();
  5.  
  6.                 foreach (Item revenant in RevenantType)
  7.                 {
  8.                     //loop through each type and check if it's a revenant
  9.                     if (revenant.Name == "a revenant" && revenant.Distance <= 4) //and if it's close enough to dispel
  10.                     {
  11.                         //keep trying until the bastard is gone!
  12.                         while (revenant.IsExists)
  13.                         {
  14.                             Console.WriteLine("Revenant found within range, casting Dispel Evil.");
  15.                             Self.Cast("Dispel Evil");
  16.                             Script.Wait(750);
  17.                         }
  18.                         Console.WriteLine("Whew, he's gone!");
  19.                     }
  20.                 }
  21.  
  22.                 #endregion Revenant check
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement