Batch

Discuss, ask for help, share ideas, give suggestions, read tutorials, and tell us about bugs you have found with MicroMacro in here.

Do not post RoM-Bot stuff here. There is a subforum for that.
Forum rules
This is a sub-forum for things specific to MicroMacro.

This is not the place to ask questions about the RoM bot, which uses MicroMacro. There is a difference.
Post Reply
Message
Author
guzanit
Posts: 8
Joined: Fri Jun 29, 2012 9:35 am

Batch

#1 Post by guzanit » Fri Aug 24, 2012 2:58 am

Hi, is there a way I can make a batch file to run as a script into micromacro in the way

Code: Select all

rom/bot.lua profile:p1 character:c1 path:pa1
...
rom/bot.lua profile:p2 character:c2 path:pa2
...
Thanks a lot.
Sorry for my english

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Batch

#2 Post by lisa » Fri Aug 24, 2012 4:46 am

well you could do the first easy enough but MM would need to know when the first is finished what it is doing before starting the second.

batch file to start looks like this

Code: Select all

@echo off
FOR /F "tokens=1 delims=" %%A in ('cd') do SET folder=%%A
START ../../micromacro.exe "%folder%/bot.lua" profile:p1 path:pa1 character:c1
I got that from Rock's commandline batch file, otherwise I'd have no idea lol
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

guzanit
Posts: 8
Joined: Fri Jun 29, 2012 9:35 am

Re: Batch

#3 Post by guzanit » Fri Aug 24, 2012 5:15 am

Thanks lisa, i know that code but its only for one execution as you said. And i dont want to launch a new micromaco window in each iteration.
All the step of the batch file shoud execute inside the same micromacro window.

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Batch

#4 Post by lisa » Fri Aug 24, 2012 6:00 am

I would probably look at creating a new "control" .lua file to handle what you want to do, there are no commands at the moment to handle it.

GW2 launches tomorrow so I probably won't have to the time for it.

The way I would probably look at it would be to create your own launcher to start the bot.lua but also add in a new error() function so that when MM errors it will do the code in thise new launcher and continue on. Then in your WP files end it with an error().

I am sure this was posted somewhere before about using the error function like this, might be an idea to do a forum search for it =)
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

guzanit
Posts: 8
Joined: Fri Jun 29, 2012 9:35 am

Re: Batch

#5 Post by guzanit » Fri Aug 24, 2012 7:04 am

Thanks lisa again, i will look into forums for the error() function but as you said
lisa wrote: GW2 launches tomorrow so I probably won't have to the time for it.
...well left 19 hours.. :-)
i will have to delay this project a time.

See u in WvWvW in GW2

Sorry for my english

User avatar
Administrator
Site Admin
Posts: 5306
Joined: Sat Jan 05, 2008 4:21 pm

Re: Batch

#6 Post by Administrator » Fri Aug 24, 2012 10:16 am

You could just make your own loop to continually load bot.lua.

Code: Select all

while(true) do
    include("bot.lua", true);
end

Post Reply

Who is online

Users browsing this forum: No registered users and 17 guests