Automatic 'login' script

Additional botting resources. Addons may be either for the game itself or for the RoM bot.
Forum rules
Only post additional bot resources here. Please do not ask unrelated questions.
Message
Author
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Automatic 'login' script

#41 Post by rock5 » Fri May 03, 2013 5:14 am

Thanks for noticing. I'll fix it.
  • 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

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

Re: Automatic 'login' script

#42 Post by rock5 » Thu May 09, 2013 12:38 am

Updated userfunction_login.lua to version 3.4 to support the new version of 'fastLogin' with the 108 login buttons. Thx dx876234.

I've left version 3.3 up for people still using the 65 button versions because at this stage there is no reason to upgrade unless you need the extra buttons.
  • 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

Niko
Posts: 30
Joined: Sat Jul 28, 2012 8:23 am

Re: Automatic 'login' script

#43 Post by Niko » Fri May 10, 2013 6:15 pm

When i run the "rom/login" command, it runs the clien but it stays in the first window shown (the one with the news and the "play" button)...

if i hit manually the "play" button, then works fine, loading the character i'v choosen...

i'm using spanish client, does that haves anything to do?
Thank's

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

Re: Automatic 'login' script

#44 Post by rock5 » Sat May 11, 2013 6:02 am

It's supposed to skip that. It might be possible that on some servers they have disabled the NoCheckVersion option. You should test to see if it works. Create a shortcut for your client or use your regular shortcut. Right-Click it and select properties. Add the following to the "Target" box NoCheckVersion.

Now start the client with that shortcut and see if it skips the updater.

Note: the "login" shortcut has to be for the "client.exe" file.
  • 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

Niko
Posts: 30
Joined: Sat Jul 28, 2012 8:23 am

Re: Automatic 'login' script

#45 Post by Niko » Sat May 11, 2013 8:01 am

The NoCheckVersion works ok. Thank's ;)

nightdps
Posts: 5
Joined: Thu Oct 18, 2012 3:18 pm

Re: Automatic 'login' script

#46 Post by nightdps » Mon May 20, 2013 9:58 am

When I use auto login, the pause (end) does not work properly. After hitting the 'end' key, the console prints out "Paused." but the bot continues to move forward. It does not move to the next waypoint but just keeps moving forward.

I don't have any issues when manually running rom\bot from micromacro. Pausing/resuming works fine. One thing to note is the when I hit the 'end' key when I manually run rom\bot is the print on the console is different.

Manual:
Paused. (Delete) to continue, (CTRL+L) exit to shell, (CTRL+C) quit
Resumed.

Auto Login:
Paused.
Started.

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

Re: Automatic 'login' script

#47 Post by rock5 » Mon May 20, 2013 10:28 am

That implies that the "atPause" call is being replaced. That is not replaced in the login.lua or userfunction_login.lua files. But both getpos and getid replace that function and print "Paused". Have you tried using the login script and starting a regular waypoint file? Does it still do it then?
  • 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

nightdps
Posts: 5
Joined: Thu Oct 18, 2012 3:18 pm

Re: Automatic 'login' script

#48 Post by nightdps » Mon May 20, 2013 11:27 am

I just tried using autologin with "l1t_start" and it does the same thing.


micromacro 1.03
rombot r757
login script 3.4

Code: Select all

MicroMacro v1.03
SolarStrike Software
http://www.solarstrike.net
Please enter the script name to run.
Type in 'exit' (without quotes) to exit.
Script> rom\login acc:59 char:1 client:rom path:1-10Pioneers\l1t_start
Opening login.lua...
Starting script execution - Press CTRL+C to exit.
Press CTRL+L to cancel execution and load a new script.
-------------------------------------------------------------------------------
C:/Users/*******/Desktop/micromacro/scripts/rom
Press the (F6) key to stop/pause the script.
You can resume with the (F5) key.

    Rock5s 'login' script. Version 3

Starting client rom ...
Clicking account 59 ...
Selecting character 1 ...
Waiting until in-game ...
Stopping execution.
Installing userfunctions. [WARN]: ...ripts/romglobal/userfunctions/userfunction_
gmmonitor.lua:30
Failed to load sound file 'alarm.wav'

We read the hotkey settings from your bindings.txt file C:\Users\********\My
 Documents\Runes of Magic\bindings.txt instead of using the settings.xml file.
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
ññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññññ
Welcome to rom bot! press END to quitñññññññññññññññññññññññññññññññññññññ
RoM Bot Version 3.29, Revision 757ññññññññññññññññññññññññññññññññññññññññ
Press the (End) key to stop/pause the script.
You can resume with the (Delete) key.
Game Version is 5.0.10.2634
RoM windows size is 672x461, upper left corner at 8,30
Loading profile *******.xml
Testing 'ingamefunctions' macro. If it gets stuck here, please update the 'ingam
efunctions' by copying the 'ingamefunctions' folder from 'rom/devtools' to the g
ames 'interface/addons' folder.
MACRO Test: ok
Ranged skill found: SCOUT_REFLECTED_SHOT
[DEBUG] CPU Frequency 3117.255
Loaded waypoint path 1-10pioneers\l1t_start.xml
No return path with default naming 1-10pioneers\l1t_start_return.xml found.
We use the normal waypoint path 1-10pioneers\l1t_start.xml now.
Moving to waypoint #1, (-3779, -8480)
Paused.
Started.
Paused.
Started.
Moving to waypoint #2, (-3654, -8639)
Paused.
Started.
Moving to waypoint #3, (-3519, -8670)
Moving to waypoint #4, (-3399, -8700)
Did not find any crashed game clients.
12:20am - scripts\rom\login.lua:51: Script forcibly terminated.


Please enter the script name to run.
Type in 'exit' (without quotes) to exit.

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

Re: Automatic 'login' script

#49 Post by rock5 » Mon May 20, 2013 1:51 pm

Ok, I figured out what it's doing but not why. What it is doing is falling back to the default recall functions. I've confirmed that the pause function does change but then when you pause it, it uses the default one instead. I can't figure out why. I suspect it has something to do with the "protected" environment being called twice with the "startmacro" command but I don't know enough about it to debug it. It would be nice if Administrator could have a look at it or explain why it might be happening.
  • 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

dr-nuker
Posts: 143
Joined: Sun Oct 09, 2011 7:33 am

Re: Automatic 'login' script

#50 Post by dr-nuker » Tue May 21, 2013 1:46 pm

I think i've seen it work pausing when you press pause on a waypoint and not inbetween.
Also the bot says to use F5 and F6 and not inser and delete.

Just to ask:
I think i read about a fetch function that restarts the bot at the point it crashed. Anyone has the link to that topic/post?
I run several bots in parallel and it is kinda messy if all crash because of a disconnect and you have to restart allover again -.-

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

Re: Automatic 'login' script

#51 Post by rock5 » Wed May 22, 2013 2:37 am

When i tried to get it to restart after a crash, I ran into a few problems that I couldn't resolve. That was before my login script was as reliable as it is now. But you are always going to have unpredictable results when trying to recover from crashes mainly because you don't know where you will be or what code will be executing.

A much more reliable and easier way to avoid crashes is to restart the client after a certain number of character changes (assuming the reason it crashes is because you changed character too many times). Just use the latest fastlLogin and loginnextchar userfunction and use the new option

Code: Select all

local RestartClientInterval = 0 -- Restarts client after this many character changes. 0 means 'disabled'.
Set it to a number less than the number of relogs it would take to make your game crash.

Actually it's been a long time since I tested that bug. It used to be that, for me, it would crash after about 14 relogs so I could never go through 2 accounts without restarting the client. I just tested it now and changed character 32 times before giving up. So I think they may have fixed that bug. This is with cleanmem keeping the memory usage down. Without cleanmem it crashed after 16 relogs with over 2g of memory usage.

It used to be that I didn't think cleanmem was that inportant because the client would crash because of restarts, but if that's fixed then cleanmem is vital to keep the client running. I recommend you try it.
http://www.pcwintech.com/cleanmem
  • 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

dr-nuker
Posts: 143
Joined: Sun Oct 09, 2011 7:33 am

Re: Automatic 'login' script

#52 Post by dr-nuker » Wed May 22, 2013 2:21 pm

rock5 wrote: It used to be that I didn't think cleanmem was that inportant because the client would crash because of restarts, but if that's fixed then cleanmem is vital to keep the client running. I recommend you try it.
http://www.pcwintech.com/cleanmem
I already do everything you mention :;)

My main bot runs many regions and events. Tht's why i relog it after some zone changes and clean the memory.
The same applies to my characters running andor-training.

So i have to admit that i do not crash very often but it happens sometimes. If there was a solution, i would give it a try but as there isn't one, it's not a big deal eigther.

Anyways I wonder how you run so many chars after eachother.

For example my andor-script. It runs a character, let it hand in 3 dailies and then does andor. But after let's say 5 or 6 chars it does not find the logar board anymore. Or fails to find the snoop or other npc's. I think it's because of the zonechanges...

I've also tried lisa's very slim botting texture pack but this makes the bot crash on miller's ranch...

BillDoorNZ
Posts: 446
Joined: Wed Aug 03, 2011 7:37 pm

Re: Automatic 'login' script

#53 Post by BillDoorNZ » Wed May 22, 2013 3:15 pm

Just getting back into ROM atm, and the bot.

Nice to see you've solved this issue for us Rock! Bloody starting up clients etc was a pita.

Anyway, for some reason, the script won't work for me. It succeeds in launching the game, recognising it is at the login screen and logging in. However, for some reason it never figures out that it has progressed on to the character selection screen (the atCharacterSelection).

hmm...on further testing, it will recognise the character screen once I click on 'Create' (to create a new character) and then 'Back' to exit back out of the character creation screen.

AHA! (sorry, testing further as I write this) Found the problem - in rom/interface/loginxml/accountlogin.lua I had set fastLoginNoZoom to true. Once I set this to false, the bit being checked for the atCharacterSelection variable becomes 1 instead of 0.

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

Re: Automatic 'login' script

#54 Post by rock5 » Wed May 22, 2013 3:40 pm

Interesting. Thanks for working that out for me.

The simple solution would be to get rid of that option. It's not really necessary.
  • 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

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

Re: Automatic 'login' script

#55 Post by rock5 » Thu May 23, 2013 12:26 pm

Ok, had a chat with Administrator and I've settled on a solution for the pausing problem.

At the bottom of login.lua I'll be changing

Code: Select all

startMacro(main,true)
to just

Code: Select all

main()
  • 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

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

Re: Automatic 'login' script

#56 Post by rock5 » Fri May 24, 2013 9:17 am

I uploaded the above change to login.lua 3.1
  • 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

nightdps
Posts: 5
Joined: Thu Oct 18, 2012 3:18 pm

Re: Automatic 'login' script

#57 Post by nightdps » Tue May 28, 2013 9:12 am

It's working great. Thanks rock5 & Administrator.

dx876234
Posts: 188
Joined: Sat Jul 24, 2010 6:13 am

Re: Automatic 'login' script

#58 Post by dx876234 » Thu May 30, 2013 10:36 am

Great function!

One feature I would love to see is to be able to select channel to log into from commandline.

I.E. So I can start my bots from a .bat file with one bot in each channel.

-dx

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

Re: Automatic 'login' script

#59 Post by rock5 » Thu May 30, 2013 11:19 am

It would have to actually click the channel. At that point there is no way to know how many channels there actually are so you would be clicking blind. It's not worth the work for me. Just change channel once you have logged in.
  • 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

dx876234
Posts: 188
Joined: Sat Jul 24, 2010 6:13 am

Re: Automatic 'login' script

#60 Post by dx876234 » Thu May 30, 2013 3:59 pm

Ok, no problem :)

-dx

Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests