KnightRyder 77 Posted October 16, 2016 Share Posted October 16, 2016 I'm trying to find a way to use the ExtraActionButton1 to cast an AoE spell to kill NPC's. I've tried several variations including InteractWithNpc with "ExtraActionButton1:Click()" in the macro. This will give me the AoE green circle to put down, but it never clicks or uses it. I've also tried the code from Use item on hostile "weakened" mob but I am not good enough with coding to change it from an item to a spell. Any suggestions? Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/ Share on other sites More sharing options...
NvD 7 Posted October 16, 2016 Share Posted October 16, 2016 i hae the same problem with quest i've asked also since he has fixed my issue, and i believe its the same issue. follow that forum also :) maybe we will get a reply :) Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19181 Share on other sites More sharing options...
Droidz 2738 Posted October 18, 2016 Share Posted October 18, 2016 Like here: http://wrobot.eu/forums/topic/2681-snippets-codes-for-quest-profiles/?do=findComment&comment=12204 try with this code: Thread t = new Thread(() => { uint itemId = 62899; uint spellId = 62899; int questId = 28000; while (robotManager.Products.Products.IsStarted) { if (Conditions.InGameAndConnectedAndAliveAndProductStartedNotInPause) { if (!Quest.HasQuest(questId)) break; if (ObjectManager.Target.IsValid && ObjectManager.Target.IsAlive) { if (itemId > 0) ItemsManager.UseItem(itemId); // if it is item if (spellId > 0) SpellManager.CastSpellByIdLUA(spellId); // if it is spell ClickOnTerrain.Pulse(new Vector3(ObjectManager.Target.Position)); // for AOE spell/item } } Thread.Sleep(500); } }); t.Start(); Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19286 Share on other sites More sharing options...
KnightRyder 77 Posted October 19, 2016 Author Share Posted October 19, 2016 Thread t = new Thread(() => { uint itemId = 0; uint spellId = 185887; int questId = 38582; while (robotManager.Products.Products.IsStarted) { if (Conditions.InGameAndConnectedAndAliveAndProductStartedNotInPause) { if (!Quest.HasQuest(questId)) break; if (ObjectManager.Target.IsValid && ObjectManager.Target.IsAlive) { if (itemId > 0) ItemsManager.UseItem(itemId); // if it is item if (spellId > 0) SpellManager.CastSpellByIdLUA(spellId); // if it is spell ClickOnTerrain.Pulse(new Vector3(ObjectManager.Target.Position)); // for AOE spell/item } } Thread.Sleep(500); } }); t.Start(); This appears to work for normal spells in spellbook, like Heroic Leap, but does not activate the ExtraActionButton1 spell. Spell in question is185887 Ysera's Wrath Quest 38582 To Old Friends Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19311 Share on other sites More sharing options...
Droidz 2738 Posted October 19, 2016 Share Posted October 19, 2016 When you run in your wow chat /cast Ysera's Wrath this works? Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19329 Share on other sites More sharing options...
Droidz 2738 Posted October 19, 2016 Share Posted October 19, 2016 ps: you can also replace if (itemId > 0) ItemsManager.UseItem(itemId); // if it is item if (spellId > 0) SpellManager.CastSpellByIdLUA(spellId); // if it is spell by Lua.LuaDoString("ExtraActionButton1:Click()"); Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19330 Share on other sites More sharing options...
KnightRyder 77 Posted October 20, 2016 Author Share Posted October 20, 2016 7 hours ago, Droidz said: When you run in your wow chat /cast Ysera's Wrath this works? Nope. 7 hours ago, Droidz said: ps: you can also replace if (itemId > 0) ItemsManager.UseItem(itemId); // if it is item if (spellId > 0) SpellManager.CastSpellByIdLUA(spellId); // if it is spell by Lua.LuaDoString("ExtraActionButton1:Click()"); This did. Link to comment https://wrobot.eu/forums/topic/4137-use-extraactionbutton-spell-to-kill-npc/#findComment-19351 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now