Advertisement
Guest User

Fate Auto Leveler Fixed Teleport

a guest
Oct 9th, 2015
557
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 2.33 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Configuration;
  5. using System.IO;
  6. using System.Threading;
  7. using ff14bot;
  8. using ff14bot.Helpers;
  9. using ff14bot.Interfaces;
  10. using ff14bot.Managers;
  11. using Newtonsoft.Json;
  12.  
  13. namespace FateAutoLeveler
  14. {
  15.   public class FateAutoLeveler : IBotPlugin
  16.   {
  17.     public string Author { get { return "Zamphire"; } }
  18.     public Version Version { get { return new Version(1, 1); } }
  19.     public string Name { get { return "Fate Auto Leveler"; } }
  20.     public string Description { get { return "Moves your character to appropriate level range."; } }
  21.     public bool WantButton { get { return false; } }
  22.     public string ButtonText { get { return "FateAutoLeveler"; } }
  23.     public bool Equals(IBotPlugin other) { throw new NotImplementedException(); }
  24.     public void OnInitialize() {}
  25.     public void OnShutdown() {}
  26.     public void OnEnabled() {}
  27.     public void OnDisabled() {}
  28.     public void OnButtonPress() {}
  29.     public void OnPulse()
  30.     {
  31.       if (BotManager.Current.Name == "Fate Bot")
  32.       {
  33.         ChangeZone();
  34.       }
  35.     }
  36.  
  37.     public void ChangeZone()
  38.     {
  39.       uint currentLocation = WorldManager.GetZoneForAetheryteId(GetLocation());
  40.  
  41.       if (currentLocation == 0 || WorldManager.ZoneId == currentLocation)
  42.       {
  43.         return;
  44.       }
  45.  
  46.       //TreeRoot.Stop();
  47.  
  48.       if (Core.Player.IsMounted)
  49.       {
  50.         Actionmanager.Dismount();
  51.         Thread.Sleep(1000);
  52.       }
  53.  
  54.       WorldManager.TeleportById(GetLocation());
  55.       Thread.Sleep(15000);
  56.       //TreeRoot.Start();
  57.     }
  58.  
  59.     public uint GetLocation()
  60.     {
  61.       var currentLevel = (int)Core.Player.ClassLevel;
  62.  
  63.       if (currentLevel < 10) {
  64.         return 52; //Summerford Farms
  65.       } else if (currentLevel >= 10 && currentLevel < 20) {
  66.         return 14; //Aleport
  67.       } else if (currentLevel >= 20 && currentLevel < 28) {
  68.         return 5; //Quarrymill
  69.       } else if (currentLevel >= 28 && currentLevel < 34) {
  70.         return 11; //Costa Del Sol
  71.       } else if (currentLevel >= 34 && currentLevel < 49) {
  72.         return 23; //Camp Dragonhead
  73.       } else if (currentLevel >= 49 && currentLevel < 60) {
  74.         return 22; //Ceruleum Processing Plant
  75.       }
  76.  
  77.       Logging.Write("Invalid level thats werid");
  78.       return 0;
  79.     }
  80.   }
  81. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement