How could we find a spell's Id? Any thing would be nice but all I can see is this thing casting pound and not a id.
Yesterday I was playing around and managed to echo all the available spells for my char by Name and I see no problems getting their Name & Guid which is Id -> http://docs.buddywing.com/html/T_Buddy_Swtor_Objects_TorAbility.htm We can then rewrite or add a function to Spell section of DefaultRoutine to call them by Id. Should work. It can also solve the translation problems.
ID is always preferable, provided we have access to the IDs as routine writers. However, if we can't get IDs, name would work fine.
You can get IDs. We'd just need every adv class and discipline to run some diagnostic plugin and we'd have ourselves a database of skill names with IDs. There is no other way than having that character class to output IDs. Here just an example for Merc Code: ... Name: Thermal Sensor Override ID: 147672092606 Name: Jet Boost ID: 147672092608 Name: Chaff Flare ID: 147672092610 Name: Rapid Shots ID: 147672092612 Name: Kolto Overload ID: 147672092614 Name: Death from Above ID: 147672092616 Name: Kolto Shot ID: 147672092628 Name: Flame Thrower ID: 147672092630 Name: Fusion Missile ID: 147672092638 Name: Rocket Punch ID: 147672092640 ... Plugin: Code: using System; using System.Windows; using Buddy.Common; using Buddy.CommonBot; using Buddy.Common.Plugins; using Buddy.Swtor; using Buddy.Swtor.Objects; namespace Buddywing.Plugins { public class Test : IPlugin { #region Implementation of IEquatable<IPlugin> /// <summary> /// Indicates whether the current object is equal to another object of the same type. /// </summary> /// <returns> /// true if the current object is equal to the <paramref name="other"/> parameter; otherwise, false. /// </returns> /// <param name="other">An object to compare with this object.</param> public bool Equals(IPlugin other) { return other.Name == Name; } #endregion #region Implementation of IPlugin public string Author { get { return "pindleskin"; } } public Version Version { get { return new Version(1, 0); } } public string Name { get { return "Use Test"; } } public string Description { get { return "Test Plugin"; } } public Window DisplayWindow { get { return null; } } /// <summary> Executes the pulse action. This is called every "tick" of the bot. </summary> public void OnPulse() { } /// <summary> Executes the initialize action. This is called at initial bot startup. (When the bot itself is started, not when Start() is called) </summary> public void OnInitialize() { } /// <summary> Executes the shutdown action. This is called when the bot is shutting down. (Not when Stop() is called) </summary> public void OnShutdown() { } /// <summary> Executes the enabled action. This is called when the user has enabled this specific plugin via the GUI. </summary> public void OnEnabled() { foreach (var ability in AbilityManager.KnownAbilities) { Logging.Write("Name: " + ability.Name + " ID: " + ability.Guid + Environment.NewLine); } } /// <summary> Executes the disabled action. This is called whent he user has disabled this specific plugin via the GUI. </summary> public void OnDisabled() { } #endregion } }
Hi Markeen. I will do some testing and join that group. My problem right now is the Combat Medic routine doesn't even load. It doesn't find an advanced class. I am at work right now but I will post a log later showing it not loading the advanced class.
pindleskin the plugin looks great, but for proper interrupt wouldnt we need the ids of the spells being cast by the NPCs, because if I understand correctly you are showing a list of all known spells by the player?
Probably because the routine wasn't updated for a very long time, it looks like a a copy paste from PureSwtor.
Yeah I thought we need this for ourselves? then Code: BuddyTor.Me.CurrentTaget.KnownAbilitiesContainer instead of Code: AbilityManager.KnownAbilities or find it here for example by name -> http://swtor.jedipedia.net/en/npc/white-maw-trapper
What we need to do is create a new .cs file in DefaultCombat named "Spell Book". In that file we'll have it set up like Code: class Spell_Book { public const int #region [Jedi Guardian] spellWardingStrike = 12345, #endregion #region [Jedi Consular] spellProject = 54321, #endregion } et cetera for everything. We can keep adding to it. Someone else will need to do it, my git version is fucked up and I haven't had time to fix it.
Here's a mock-up I did using pindleskin's information. We can't use int's because the numbers aren't 64-bit, so I had to use long's instead. Code: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace DefaultCombat.Helpers { class SpellBook { public const long #region [Mercenary] spellThermalSensorOverride = 147672092606, spellJetBoost = 147672092608, spellChaffFlare = 147672092610, spellRapidShots = 147672092612, spellKoltoOverload = 147672092614, spellDFA = 147672092616, spellKoltoShot = 147672092628, spellFlameThrower = 147672092630, spellFusionMissile = 147672092638, spellRocketPunch = 147672092640; #endregion } }
Having Issues with routines for trooper here is the log. Should be a Vanguard Shield Specialist. But for some reason its saying Can not be Determined 2016-01-09 03:58:13,222 [1] INFO Log - Starting Buddy Wing v1.0.1252.800 2016-01-09 03:59:15,754 [3] INFO Log - Logging in... 2016-01-09 03:59:17,056 [3] INFO Log - T: 5247565105989897645 H: 2243719007 2016-01-09 03:59:17,081 [3] INFO Log - Login Success! 2016-01-09 03:59:20,347 [6] INFO Log - First CPU: Intel(R) Core(TM) i7-3615QM CPU @ 2.30GHz 2016-01-09 03:59:20,348 [6] INFO Log - OS Version: Windows NT 6.2.9200.0 2016-01-09 03:59:20,349 [6] INFO Log - App Path: C:\Users\Downloads\BuddyWing 1.0.1252.800\Buddywing.exe 2016-01-09 03:59:29,098 [6] INFO Log - User is a Trooper 2016-01-09 03:59:30,402 [6] INFO Log - Advanced Class: Vanguard / Discipline: CanNotBeDetermined 2016-01-09 03:59:30,403 [6] INFO Log - Routine Path: Routines 2016-01-09 03:59:36,615 [6] INFO Log - Medpac Created! 2016-01-09 03:59:36,696 [6] INFO Log - [DefaultCombat] Level: 12 2016-01-09 03:59:36,698 [6] INFO Log - [DefaultCombat] Class: Trooper 2016-01-09 03:59:36,698 [6] INFO Log - [DefaultCombat] Advanced Class: Vanguard 2016-01-09 03:59:36,728 [6] INFO Log - [DefaultCombat] Discipline: CanNotBeDetermined 2016-01-09 03:59:36,783 [6] ERROR Log - Unhandled exception during init: System.ArgumentNullException: Value cannot be null. Parameter name: type at System.Activator.CreateInstance(Type type, Boolean nonPublic) at System.Activator.CreateInstance(Type type) at DefaultCombat.Core.RotationFactory.Build(String name) in c:\Users\Downloads\BuddyWing 1.0.1252.800\Routines\DefaultCombat\Core\RotationFactory.cs:line 54 at DefaultCombat.DefaultCombat.Initialize() in c:\Users\Downloads\BuddyWing 1.0.1252.800\Routines\DefaultCombat\DefaultCombat.cs:line 69 at Buddy.CommonBot.RoutineManager.set_Current(ICombat value) at Buddy.CommonBot.BotMain.SetCurrentCombatRoutine() at Buddywing.MainWindow.?????????????????????????????????????????() 2016-01-09 03:59:36,821 [6] INFO Log - Buddy Wing: The Old Robot is ready! 2016-01-09 04:04:51,538 [1] ERROR Log - System.Exception: There is no profile loaded. Please load a profile before starting the bot. at Buddy.CommonBot.BotMain.Start() at Buddywing.MainWindow.?????????????????????????????????????????(Object , RoutedEventArgs ) 2016-01-09 04:04:55,783 [1] INFO Log - Current bot set to Quest Bot 2016-01-09 04:04:55,818 [1] INFO Log - Loaded profile [R - Light] 1-10 Trooper and Smuggler - Ord Mantell [Kick] 2016-01-09 04:04:58,797 [1] INFO Log - Forcing profile reload. -- Temporary fix for behavior cache issues during start/stop. 2016-01-09 04:04:59,193 [1] INFO Log - Current bot set to Quest Bot 2016-01-09 04:04:59,197 [1] INFO Log - Loaded profile [R - Light] 1-10 Trooper and Smuggler - Ord Mantell [Kick] 2016-01-09 04:05:00,379 [Main Bot Thread] ERROR Log - TorNpc.Name Exception System.Exception: Function GetName does not exist. at ?????????????????????????????????????????.?????????????????????????????????????????.?????????????????????????????????????????[](Boolean , String , Object[] ) at Buddy.Swtor.Objects.TorObject.CallScript[T](Boolean hasReturnValue, String function, Object[] args) at Buddy.Swtor.Objects.TorNpc.get_Name() 2016-01-09 04:05:00,401 [Main Bot Thread] INFO Log - [Poi.Clear] Reason: Current quest behavior changed to PickupQuestTag: ObjectName: Corporal Dregg, X: -26.3844, Y: 2.823806, Z: -27.7099, Position: <-26.3844, 2.823806, -27.7099>, Type: Npc, ProfileUseRange: 5, ProfileSearchRadius: 5, SearchRadius: 0.5, WaitTime: 1, IgnoreLOS: False, UseRange: 0.5, Object: null, QuestId: 16140942117854255232, BranchId: 0, StepId: 0, TaskId: 0, QuestName: Republic Roulette: Questionable Ethics, IsDoneCache: False, Behavior: Buddy.BehaviorTree.PrioritySelector, . 2016-01-09 04:05:00,654 [Main Bot Thread] ERROR Log - TorNpc.Name Exception System.Exception: Function GetName does not exist. at ?????????????????????????????????????????.?????????????????????????????????????????.?????????????????????????????????????????[](Boolean , String , Object[] ) at Buddy.Swtor.Objects.TorObject.CallScript[T](Boolean hasReturnValue, String function, Object[] args) at Buddy.Swtor.Objects.TorNpc.get_Name() 2016-01-09 04:05:06,540 [1] INFO Log - Reason: 2016-01-09 04:05:06,581 [Main Bot Thread] INFO Log - Bot Thread Ended. Was this requested? 2016-01-09 04:05:08,647 [1] INFO Log - We slept way too long waiting for the bot thread to give control back. Aborting thread. Client may crash! 2016-01-09 04:05:08,648 [1] INFO Log - [Poi.Clear] Reason: Bot Stopped
weird. in the docs its UInt64 for that id. BTW why do we need this Ids? It will be hard to edit the rotations with all those numbers very confusing since every spell has a decent name.
Numbers are universal, which would allow people to use the routine in other languages. It would also prevent stupid shit like when I misspelled "missile" in the Merc rotations for like a month. You wouldn't use the numbers outside of the spell book, that's the point. You'd call a spell like: Code: Spell.Cast(SB.spellDFA) And the bot would use the spell book to cast spellID 147672092616=
It could also make tracking auras 1000% easier, since they like to change the name of DoTs every patch it seems. Not sure if we can get auras using your plugin though
I can modify it to detect our buffs/debuffs or current target's. Let me know if you need anything more for making this routine better...
We'd need both our buffs and target's debuffs. That way we can start building a massive spellbook with spells, buffs, and debuffs. When an entry changes, we'd just need to update the spellbook instead of each entry for each spec. This will be a massive undertaking though.