Re: RoM bot
Posted: Sat Aug 22, 2009 8:14 am
How can i acces and set my own variables in waypoints ?
You could use the user fields from the bot:master121 wrote:How can i acces and set my own variables in waypoints ?
Code: Select all
player.free_field1 = nil; -- free field for user use
player.free_field2 = nil; -- free field for user use
player.free_field3 = nil; -- free field for user use
player.free_counter1 = 0; -- free counter for user use
player.free_counter2 = 0; -- free counter for user use
player.free_counter3 = 0; -- free counter for user use
player.free_flag1 = false; -- free flag for user use
player.free_flag2 = false; -- free flag for user use
player.free_flag3 = false; -- free flag for user use
Trymaster121 wrote:if( player.free_counter1 = 1 ) then
I get this error :
player.lua:876: assertion failed
Code: Select all
if( player.free_counter1 == 1 ) then
Code: Select all
tags for posting code.
Yes you are right that happens very often. I will have a further look at this and then report back ^^d003232 wrote:Except if you are using a waypoint/waypointfile type="RUN". But the bot will first finish the current mob and then wait until the client give hin the attacking target. And I suppose, normaly your are death until that happens.
Code: Select all
RoM Bot Version 2.45
C:/Program Files/scripts/rom/functions.lua:74: Wrong number of parameters
supplied to findWindowList().
Probably because it doesn't exist. It would make sense to create a waypoint file before trying to load it, as per the instructions.coolsteven2 wrote:i feel so stupid i cant get this to work -_- i get the "Bandits.xml cannot be read"
It has nothing to do with your monitor setup. Post your log.txt.I dont know if this has something to do with me running a dual screen monitor setup, but i did try turning it back to 1 monitor.
May you explain because i don't know how to make a waypoint file workAdministrator wrote:Probably because it doesn't exist. It would make sense to create a waypoint file before trying to load it, as per the instructions.coolsteven2 wrote:i feel so stupid i cant get this to work -_- i get the "Bandits.xml cannot be read"
It has nothing to do with your monitor setup. Post your log.txt.I dont know if this has something to do with me running a dual screen monitor setup, but i did try turning it back to 1 monitor.
Code: Select all
<profile>
<options>
<option name="HP_LOW" value="85" />
<option name="MP_LOW_POTION" value="50" />
<option name="HP_LOW_POTION" value="40" />
<option name="COMBAT_TYPE" value="melee" />
<option name="COMBAT_DISTANCE" value="200" />
<option name="ANTI_KS" value="true" />
<option name="WAYPOINTS" value="bandits.xml" />
<option name="RETURNPATH" value="" />
<option name="PATH_TYPE" value="waypoints" />
<option name="WANDER_RADIUS" value="500" />
<option name="WAYPOINT_DEVIATION" value="0" />
<option name="LOOT" value="true" />
<option name="LOOT_TIME" value="2000" />
<option name="LOOT_IN_COMBAT" value="true" />
<option name="LOOT_DISTANCE" value="100" />
<option name="POTION_COOLDOWN" value="15" />
<option name="MAX_FIGHT_TIME" value="15" />
<option name="DOT_PERCENT" value="90" />
<!-- rest if HP or Mana is below that level -->
<option name="HP_REST" value="15" />
<option name="MP_REST" value="15" />
<option name="LOGOUT_TIME" value="0" />
<option name="LOGOUT_SHUTDOWN" value="false" />
<!-- attack monsters 10 levels above or below your level -->
<option name="TARGET_LEVELDIF_BELOW" value="10" />
<option name="TARGET_LEVELDIF_ABOVE" value="10" />
<option name="QUICK_TURN" value="false" />
</options>
<friends>
<friend name="MyOtherCharacter1" />
<friend name="MyOtherCharacter2" />
</friends>
<hotkeys>
<hotkey name="HP_POTION" key="VK_MINUS" modifier="" />
<hotkey name="MP_POTION" key="VK_EQUAL" modifier="" />
<hotkey name="ATTACK" key="VK_0" modifier="" />
<hotkey name="RES_MACRO" key="VK_9" modifier="" />
<hotkey name="LOGOUT_MACRO" key="VK_8" modifier="" />
</hotkeys>
<skills>
<skill name="WARRIOR_SLASH" hotkey="VK_3" modifier="" />
<skill name="WARRIOR_PROBING_ATTACK" hotkey="VK_1" modifier="" />
<skill name="WARRIOR_ENRAGED" hotkey="VK_4" modifier="" />
</skills>
<onDeath>
-- Additional Lua code to execute on death
pauseOnDeath(); -- Stop the script
</onDeath>
<onLeaveCombat>
-- Additional Lua code to execute after killing an enemy
</onLeaveCombat>
<onSkillCast>
-- Additional Lua code to execute when casting a skill
-- Note: arg1 contains the skill being used.
-- i.e. arg1.Name will be the name of the skill being cast.
</onSkillCast>
</profile>
And is it named Bandits.xml and in the waypoints folder?coolsteven2 wrote: i did make a waypoint file -_-
Administrator wrote:And is it named Bandits.xml and in the waypoints folder?coolsteven2 wrote: i did make a waypoint file -_-
http://www.solarstrike.net/phpBB3/viewt ... f=21&t=445coolsteven2 wrote:Ok i got it to work! but how do i harvest? it keeps attacking mobs.....
You can use it...drizz wrote:I am using a labtop which doesnt have a num pad, so is there no way I could use this program?
It has nothing to do with your monitor setup. Post your log.txt.[/quote]I dont know if this has something to do with me running a dual screen monitor setup, but i did try turning it back to 1 monitor.
Code: Select all
Sun Aug 23 11:10:08 2009 : MicroMacro v1.0
Sun Aug 23 11:10:08 2009 : Processor Type: 2X 586, OS: Windows XP Service Pack 3
Sun Aug 23 11:10:08 2009 : LuaCoco is available.
Sun Aug 23 11:10:08 2009 : Lua glues exported.
Sun Aug 23 11:10:08 2009 : Keyboard layout: US English
Sun Aug 23 11:10:14 2009 : Executing script 'bot.lua'
==================================================
Sun Aug 23 11:10:15 2009 : RoM Bot Version 2.45
Sun Aug 23 11:10:15 2009 : Language: english
stack traceback:
C:\Program Files\****\lib\lib.lua:512: in function 'startMacro'
scripts\rom/bot.lua:414: in main chunk
----------TRACEBACK END----------
Sun Aug 23 11:10:15 2009 : C:/Program Files/****/scripts/rom/functions.lua:74: Wrong number of parameters supplied to findWindowList().
Sun Aug 23 11:10:15 2009 : Execution error: Runtime error
Code: Select all
<!-- # 1 --><waypoint x="00000" z="00000">
if( os.difftime(os.time(), player.BotStartTime) > 660 ) then
showWindow(getWin(), sw.show);
player:rest(2);
keyboardPress(key.VK_7);
player:rest(20);
load_paths("repair.xml");
player:BotStartTime = 0;
end
</waypoint>
Code: Select all
<!-- # 3 --><waypoint x="-14132" z="-684" type="RUN"></waypoint>
<!-- # 4 --><waypoint x="-14002" z="-870" type="RUN"></waypoint>
<!-- # 5 --><waypoint x="-13859" z="-1120" type="RUN"></waypoint>
Code: Select all
cprintf(cli.green, anguage[113]); -- we don't stop and don't fight back