What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Making an Enchanting script using Professionbuddy and need some help :)

churobot

New Member
Joined
Dec 21, 2011
Messages
168
Reaction score
1
hi guys

making an enchanting script from 1 to 525. one part of my script requires me to override an existing enchant. how do i get professionbuddy to say "yes"

ie do you want to replace existing enchanting"

i want to hit yes

if you use a macro its the script

ReplaceEnchant()
 
Last edited:
I replied how to do that in your other thread. Another way could be buying enchanting vellums and just put the enchants on those. Then you could also sell them after.
 
View attachment help me.xml

yeah good idea but i want to nut out this problem!!!!

okay, here is my latest shot but still no luck, no error messages, but the yes/no button still pops up

give me some guidance and thanks in advance! i appreciate it (like eating a warm hot dog!)
 
In the example you just posted there's no code to click that button. After the CastSpell Action you add a Custom Action with this code:
PHP:
Thread.Sleep(500); Lua.DoString("ReplaceEnchant()");

The Thread.Sleep will make it wait 500 ms before clicking the button (to allow it to pop up)
The Lua.DoString will press the button.
 
Last edited:
In the example you just posted there's no code to click that button. After the CastSpell Action you add a Custom Action with this code:
PHP:
Thread.Sleep(500); Lua.DoString("ReplaceEnchant()");

The Thread.Sleep will make it wait 500 ms before clicking the button (to allow it to pop up)
The Lua.DoString will press the button.
View attachment chu.xml

no love............popup box still opens and doesnt shut :(

check me xml
 
Try putting it inside the while loop - RIGHT after the Cast Spell action.
 
Try putting it inside the while loop - RIGHT after the Cast Spell action.

PHP:
    <While Condition="Enchanting.Level &gt;=60 &amp;&amp; Enchanting.Level &lt; 105" IgnoreCanRun="False">
      <CastSpellAction Entry="7418" Repeat="20" RepeatType="Craftable" CastOnItem="True" ItemId="0" ItemType="Wrist" />
      <CustomAction Code="Thread.Sleep(1500); Lua.DoString(&quot;ReplaceEnchant()&quot;); " />

no luck big man :(
 
Yea that's what I thought.. The CastSpell Action is waiting for the cast to complete. You're gonna need to do the CastSpell in some other way, and then targetting the items will be a bitch. I'd say go ask highvoltz if he can add something to click that confirmation to the castspell action.
 
i have this manual macro which works in game.....but have i scripted it correctly here?


Thread.Sleep(5000);Lua.DoString("RunMacroText(/click StaticPopup1Button1)");
 
Last edited:
Instead of Lua.DoString("RunMacroText(/click StaticPopup1Button1)")
I'd use Lua.DoString("StaticPopup1Button1:Click()");
If you want to test it ingame (so you know this will work too) it's the same as typing /run StaticPopup1Button1:Click() ingame.
 
Back
Top