Problem with auto login on next char

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Message
Author
noobbotter
Posts: 527
Joined: Fri Aug 31, 2012 1:15 pm

Re: Problem with auto login on next char

#61 Post by noobbotter » Thu Jun 25, 2015 7:02 am

Thanks Administrator. I knew the file got attached so I figured it must have been something with the site upgrade that lost it.

Although I fixed my problem and it's working, I'm curious if the cause of my error was the fact that I killed the client, logged in with a different character and attempted to do a loadProfile() prior to doing a player:update?

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

Re: Problem with auto login on next char

#62 Post by rock5 » Fri Jun 26, 2015 2:31 am

player:update() is a very important function. Not only does it update the player details including it's address and skills but in the process it also detects character changes and in turn reruns setupMacros() which makes RoMScript function work. So it should always be one of the first things you do after changes such as changing class or changing character, etc.

So, yes, not running player:update() as soon as you change character can easily cause an error.
  • 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

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot] and 1 guest