Page 1 of 1

help r/k heal

Posted: Sat Jan 08, 2011 5:56 am
by mayainverse
having problem with r/k heal or buffs in general.

sometiems after being gone for long while half my buffs are not there.
so i tried to make a script for rebuffign when buffs fade but i always get a returns nil error. i uninstalled and it is fully updated as of 5 minutes ago. this is code im using.

Code: Select all

<onSkillCast><![CDATA[
      player:updateBuffs("player")
            if player.Class1 == CLASS_ROGUE then
               if not player:hasBuff("Enhanced Armor") then
                     player:cast(KNIGHT_ENHANCED_ARMOR);
               end
            else
               if not player:hasBuff("Lion's Protection") then
                     player:cast("ROGUE_LIONS_PROTECTION");
               end
            end
   ]]></onSkillCast>
if i cant get this to work i also can not use the r/k heal skill as it removes one of my key buffs 10% attack. in addition to not being able to heal again for the 15min bot takes to reclick manualy even then it sometiems fails to buff. atm the bot burns through hp potions crazy fast. when I am manually farming i never have to use them.

is there any way I can reliably get premed > stealth > sneak attack(that seems like hard one) into the rotation. but getting jsut bufffs to work right and th eheal would save me loads of money on hp pots.

Re: help r/k heal

Posted: Sat Jan 08, 2011 6:02 am
by top1
Already answered this in my other thread, but if anyone searches, here is my -lowbob- solution I used long time ago ^^

1. Make in the skills.xml a new "selfheal" [rogue_heal] skill with ~3 secounds casttime an 60 secounds CD
2. Build a new makro to /cast lionhealskill /wait 1 and then /cast lionprotection (please look up the correct english skillnames)
3. Asign the new makro to your quickbar and add the rogue_heal skill to you profile

Re: help r/k heal

Posted: Sat Jan 08, 2011 6:16 am
by rock5
KNIGHT_ENHANCED_ARMOR needs to be in quotes.

Code: Select all

                     player:cast("KNIGHT_ENHANCED_ARMOR")
Why do I feel like I've said that before?

Re: help r/k heal

Posted: Sat Jan 08, 2011 6:33 am
by mayainverse
what do you mean said that before?


and what is correct macroto to make I am not familiar with code for rom macros. I can probably figure out cast. but no idea how to make it wait.

it would still be nice to have a working buff script as sometimes it will fail to recast a buff and you will be without it. the holy dmg one I can live without. enhance armor no i cant.

Re: help r/k heal

Posted: Sat Jan 08, 2011 8:14 am
by rock5
mayainverse wrote:what do you mean said that before?
I seem to remember someone posted about code that was very similar to yours and was also missing quotes around one of them. I felt a bit of deja vu. :)

mayainverse wrote:and what is correct macroto to make I am not familiar with code for rom macros. I can probably figure out cast. but no idea how to make it wait.
Sorry I did not understand that. Could you repeat the question (was there a question)?
mayainverse wrote:it would still be nice to have a working buff script as sometimes it will fail to recast a buff and you will be without it. the holy dmg one I can live without. enhance armor no i cant.
One day the bot will include checking buffs from memory but until then we have to make do with code like yours. I really want to add it and I have it on my todo list but it's not high in priority. Mainly because I don't have much time at the moment so I try to tackle the smaller jobs first.

Re: help r/k heal

Posted: Sat Jan 08, 2011 11:27 am
by botje
yeah, it was me that had that xd

Botje

Re: help r/k heal

Posted: Sat Jan 08, 2011 12:40 pm
by mayainverse
well I do not know what is wrong with my code. and cant get it to work. I finaly got the macro to work and ty. at least for the time being I am able to heal. my heal is like almost 2k hp so that saves me like 4 pots every time it heals so alot of gold saved and extra survivability so thank you.