quick help needed - bot healing groupmember - only in battle

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
top1
Posts: 50
Joined: Mon Jan 03, 2011 4:57 pm

quick help needed - bot healing groupmember - only in battle

#1 Post by top1 »

Hi there

I want to repeat targeting one member of the group and quick heal him until the "in battle" flag of the priest dissapears.
Pretty easy, even a noob in scripting like me should manage that, I thought...
Im getting crazy with this!!! Spend hours and it still wont work!!

Code: Select all

repeat
      sendMacro('TargetUnit("party1")');
      player:cast("PRIEST_URGENT_HEAL");
      yrest(1030);
until  -- and here should be the "player not in battle"
I tried various things without any sucess :(

until
self.InBattle ~= true;
player.Battling ~= true;
GetPlayerCombatState() ~= true;

always the same problem of getting nil values (when not in battle) and so aborting the script :(


makes me crazy
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: quick help needed - bot healing groupmember - only in ba

#2 Post by rock5 »

'player.Battling' is the one you want. It's probably not working because you aren't updating the player. Just add a 'player:update()'. That should work.
  • 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.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
top1
Posts: 50
Joined: Mon Jan 03, 2011 4:57 pm

Re: quick help needed - bot healing groupmember - only in ba

#3 Post by top1 »

thx!!!!!!!

this fixed it !!!!!!
Post Reply