Page 56 of 111

Re: RoM bot

Posted: Mon Jun 08, 2009 2:10 pm
by Administrator
Well, since you asked about this in PM, and since it isn't too difficult of a task, why don't you pick up working on that first suggestion? Most, if not all, of what you need can be found in bot.lua. Just copy how the profile option works.

For the second option, it may be best to use MicroMacro's own networking functions for this. The problem is that you can't create multiple true threads, so you wouldn't be able to output/process data while waiting for input. That is, the server (which would be the bot) would continue running fine, but the client (where you type in the commands) would be blocked when waiting for you to type in commands.

Re: RoM bot

Posted: Wed Jun 10, 2009 6:27 am
by kalexei
Hi,

I´m a little bit confused. Since the newest patch today (2.0.8.1841.en) the bot doesn´t loot. Autoloot is enable and in my profile LOOT_value is true.
The problem is in the logfile -when i started- the bot i can read that it "Looting Target" but it doesn´t. Any idea?

Thx Kale

Re: RoM bot

Posted: Wed Jun 10, 2009 6:44 am
by memcpy
kalexei wrote:i can read that it "Looting Target" but it doesn´t. Any idea?
if something doesn't work anymore after a patch that clearly worked before: be patient, devs will look into it.
maybe they changed something in the loot mechanics. stay tuned for updates on this issue.

Re: RoM bot

Posted: Wed Jun 10, 2009 8:20 am
by d003232
kalexei wrote:Hi,
The problem is in the logfile -when i started- the bot i can read that it "Looting Target" but it doesn´t. Any idea?
I dont have any problems today? Hmm. I'm on a europe server with 2.0.7.1839. Ok I will be forewarned.

On the other side: Have you set your standard attack hotkey? It is needed for looting because the client loots automaticly if you 'attack' a death corpse. :-)

Re: RoM bot

Posted: Wed Jun 10, 2009 9:18 am
by kalexei
d003232 wrote: On the other side: Have you set your standard attack hotkey? It is needed for looting because the client loots automaticly if you 'attack' a death corpse. :-)
thats it... have delete my attack key so it was empty and haven´t seen it. :oops:

thx a lot now it works like befor. :D

Kale

Re: RoM bot

Posted: Thu Jun 11, 2009 12:08 pm
by memcpy
little commandline patch to force the bot to use given waypoints via wp:<foo>

Code: Select all

examples:
# rom/bot.lua wp:wander
# rom/bot.lua wp:silverspring_tagena
to define the returnpath simply add the command wpret:<foo>

Code: Select all

exmples:
# rom/bot.lua wp:wander wpret:random_wanderspot_ret
# rom/bot.lua wp:aslan_goblins wpret:aslan_goblins_ret

Re: RoM bot

Posted: Thu Jun 11, 2009 2:44 pm
by stevenr
Hi,

i have a question - is it possible to press a key from the keyboard from the script?


I try this...

Code: Select all

FARM = {key = _G.key.VK_F12, modifier = nil},

Code: Select all

<waypoints>
	<waypoint x="-259" z="-6945" />
	<waypoint x="-305" z="-7165" />
	<waypoint x="-192" z="-7267" >
    keyboardHold(settings.hotkeys.FARM.key);
    yrest(500);
    keyboardRelease(settings.hotkeys.FARM.key);
	yrest(50000);
	</waypoint>
	<waypoint x="-156" z="-7317" />
	<waypoint x="-155" z="-7351" >
    keyboardHold(settings.hotkeys.FARM.key);
    yrest(500);
    keyboardRelease(settings.hotkeys.FARM.key);
	yrest(50000);
	</waypoint>	
</waypoints>
But there will not realy be clicked F12 - only the ingame funktion. And i will start with F12 a rightclick porgram.

Re: RoM bot

Posted: Thu Jun 11, 2009 3:26 pm
by Administrator
Why are you trying to press F12? If you want to send it globally, you'll need to detach input, then press F12, and reattach.

Code: Select all

detach()
keyboardPress(key.VK_F12);
attach(getWin());

Re: RoM bot

Posted: Fri Jun 12, 2009 5:48 pm
by GodHunter
First of all let me say that this bot is working fine also without waypoints, thats really fine coded.

But there is one thing i really miss in that bot and thats a way to farm objects like wood and all the other things, or is it possible? Coldnt find something there for!?

Re: RoM bot

Posted: Fri Jun 12, 2009 11:43 pm
by Administrator
GodHunter wrote:First of all let me say that this bot is working fine also without waypoints, thats really fine coded.

But there is one thing i really miss in that bot and thats a way to farm objects like wood and all the other things, or is it possible? Coldnt find something there for!?
It's incomplete. Currently the system is very buggy. Hopefully it'll be complete for the next version.

Re: RoM bot

Posted: Sun Jun 14, 2009 4:11 pm
by kolobok
I need to modify bot so he can just wlk around with or without targeting mobs and get all the resources! help me pls!

Re: RoM bot

Posted: Sun Jun 14, 2009 4:16 pm
by Administrator
The harvesting code is not finished yet. To disable targeting and attacking monsters, change player:moveTo(wp); to player:moveTo(wp, true); in bot.lua.

Re: RoM bot

Posted: Sun Jun 14, 2009 4:55 pm
by kolobok
how can i switch beetwen ranged magic attack and melee ! i want to attack target with magic till 50% hp then switch to melee damage! Thank you! :)

Re: RoM bot

Posted: Sun Jun 14, 2009 5:14 pm
by Administrator
By assigning both ranged magic and melee physical skills. Use "ranged" fighting type.

Re: RoM bot

Posted: Mon Jun 15, 2009 7:26 pm
by Abisbowa
For some reason, when the bot dies it just lays on the ground. I have set up a macro, put it on my hotbar, and assigned the key in my profile. What am I doing wrong?

Re: RoM bot

Posted: Tue Jun 16, 2009 5:39 am
by d003232
Abisbowa wrote:For some reason, when the bot dies it just lays on the ground. I have set up a macro, put it on my hotbar, and assigned the key in my profile. What am I doing wrong?
You have to press your 'assigned key' manual. Then the bot will helps you to come back to the botting area if you have defined a return path. It is not fully automatically.

Even if it would be supported, I would not want to make it totaly automatic. I don't like to have so much experience points debts after dieing x times. :-)

Re: RoM bot

Posted: Tue Jun 16, 2009 9:46 am
by d003232
Administrator wrote:A few minor changes made to the CWaypointList class to allow for running of a waypoint list in reverse (or reversing your direction at run-time). A few more skills have been added as well.
I know I can add a <type="TRAVEL"> to my waypoint file to use it for traveling. I'm unsure how to insert that tpy correct in the waypoint file and I don't find out how to reverse the direction of the waypoint file?

Re: RoM bot

Posted: Tue Jun 16, 2009 4:11 pm
by Administrator
Not resurrecting automatically and returning to your waypoint path is a bug. I cannot test everything every time there is a patch, so it is up to the users to report problems like this. I will check it out when I get some time.

To reverse your waypoints, simply add __WPL:reverse(); to the waypoint's script.

Re: RoM bot

Posted: Tue Jun 16, 2009 4:25 pm
by d003232
Administrator wrote:Not resurrecting automatically and returning to your waypoint path is a bug. I cannot test everything every time there is a patch,...
Perhaps it's simply in the character profile? If you generate it with the 'RoM Bot Configuration Tool V1.4' (like i did) it will place a 'pauseOnDeath();' in your character profile:

Code: Select all

<onDeath>-- Additional Lua code to execute on death
pauseOnDeath(); -- Stop the script</onDeath>
<onLeaveCombat>
...
That will cause an break.

Re: RoM bot

Posted: Tue Jun 16, 2009 5:03 pm
by Abisbowa
d003232 wrote:
Administrator wrote:Not resurrecting automatically and returning to your waypoint path is a bug. I cannot test everything every time there is a patch,...
Perhaps it's simply in the character profile? If you generate it with the 'RoM Bot Configuration Tool V1.4' (like i did) it will place a 'pauseOnDeath();' in your character profile:

Code: Select all

<onDeath>-- Additional Lua code to execute on death
pauseOnDeath(); -- Stop the script</onDeath>
<onLeaveCombat>
...
That will cause an break.
My profile has that, but I don't want it to break. When I die I want the program to press the res macro that I made, and start running back to my waypoints. Right now I have a few hours left on my "No XP debt" potion so I'm not worried about too much debt.

If I take out the "pauseOnDeath();" method call will it press the rez macro when the bot dies?