When running my bot, I keep getting this error: Error in your profile: onleavecombat error: ....pawn.lua:537:bad argument #1 to 'gmatch' <string expected, got nil>
<onLeaveCombat><![CDATA[
-- Additional Lua code to execute after killing an enemy
useGoodie("mdmg2");
if (not player:hasBuff("506687")) then
inventory:useItem(207203);
end
if (not player:hasBuff("506686")) then
inventory:useItem(207202);
end
if (not player:hasBuff("506684")) then
inventory:useItem(207200);
end
catchCavy();
]]></onLeaveCombat>
Try not surrounding the id numbers with quotes. They are numbers, not strings.
Edit: Scratch that. Looks like the buff functions convert the string to a number anyway. Lisa is probably right. It's probably your useGoodie function.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
<onLeaveCombat><![CDATA[
-- Additional Lua code to execute after killing an enemy
if( not player:hasBuff("Unimaginable Salad") and inventory:itemTotalCount(207215) > 0 ) then
inventory:useItem(207215)
inventory:update()
yrest(750)
end
if not player:hasBuff(501823) then
player:cast("KNIGHT_ENHANCED_ARMOR");
yrest(300);
end
]]></onLeaveCombat>
Maybe without the item check it's getting an error if the item doesn't exist?
if (not player:hasBuff("495632")) then
inventory:useItem(207214);
end
for my delicious swamp mix and the problem is i eat the swamp mix after each combat, so if I kill one monster, I eat one swamp mix, another monster another swamp mix..... is there something wrong with my code?
i double checked the buff name id and it is right.
hmm its really weird that my character would just keep eating the swamp mix when the buff is already there...
/script i=1 while UnitBuff( "player", i) ~= nil do name, __, __, ID = UnitBuff( "player", i) SendSystemChat(name.." "..ID) i = i + 1 end
That will list your buffs and ids.
Another option might be to use the buff name instead of the id. useGoodie uses ids so that it's universal but for your own use there is no reason why you couldn't use the name instead. The name of the item too for that matter.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
If "Delicious Swamp Mix" is the name of the buff you see in the tooltip when you hover the mouse over it, then I don't know why it isn't working. Sorry. Unless you are using an older version of the bot.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
Could you post what you have in your profile if possible for eating housmaid potions and food?
Cuz this is the weirdest thing ever, when I fininshed eating Swamp mix after 50 fights (i had 50 swamp mixes and I ate one after every fight), I started consuming one lucky pot after one fight.......
I updated rombot to revision 605 and i have no idea how to fix this.... T.T. It was working fine before when I used to have goodie function in my profile, but the goodie fuction was causing my rombot to stop working.
I remember helping him get going on the bot to begin with. I had to be pretty detailed in how things were said... This isn't to be taken as an insult by him, but he's even more of a newbie than I was when I started out.
Fair enough. But if he didn't understand something he should have asked for clarification. If he doesn't, all I can assume is he tried it but it didn't help.
Pretty much my hands are tied if people don't try the thing I ask them to try and act as if they did.
I do get the impression it should have been sorted by now.
ahh sorry guys i am kind of noob and slow at learning things.
when rock5 first gave me the advice of /script i=1 while UnitBuff( "player", i) ~= nil do name, __, __, ID = UnitBuff( "player", i) SendSystemChat(name.." "..ID) i = i + 1 end, i didnt understand what he meant... T.T, that's why i had to ask again, but I got it to work now thanks to you guys.
sorry if i am slow at these kind of things .