Bot should stand on place and wait

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Message
Author
booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Bot should stand on place and wait

#1 Post by booting1 » Sat Jul 21, 2012 10:46 am

hello,

when i will farm 1 litte boss, what i can do that the bot stand still, not move on stand left right left right and so on.

i will that the bot stand where i have make 1 waypoint and wait for the respawn, kill the enemy and loot and stand still on the marked waypoint.

this is my file.
<xml version="1.0" encoding="UTF-8"?>
-<waypoints>
<!-- # 1 -->
<waypoint y="39" z="1943" x="-1023"> </waypoint> </waypoints>

User avatar
gloover
Posts: 304
Joined: Wed Jul 07, 2010 4:31 am

Re: Bot should stand on place and wait

#2 Post by gloover » Sat Jul 21, 2012 2:11 pm

Code: Select all


<waypoint y="39" z="1943" x="-1023"> 
local Boss = player:findNearestNameOrId("Bossname")
repeat
 yrest(1000)
until Boss
</waypoint> 
I hope it is not Locface amd also hope you are not on the same server like me ;-)

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#3 Post by booting1 » Sun Jul 22, 2012 1:10 am

thx
but
this is in xml file now

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
	<!-- #  1 --><waypoint x="-1039" z="1870" y="52">
local Boss = player:findNearestNameOrId("bossname")
repeat
 yrest(1000)
until Boss	</waypoint>
</waypoints> 
the boss is on i start the bot
he kills the boss, run and loot, and than he look another targeht kill this and than he go back and sand still :)

when the boss respawn the bot do nothing again? yrest 1000 is this wait 1000 seconds befor do anything again?


isnt locface :) the is another player 24 on day :D

can i say the bot to change channel for m1 -2 from 2-3 und vom 3-1?

User avatar
gloover
Posts: 304
Joined: Wed Jul 07, 2010 4:31 am

Re: Bot should stand on place and wait

#4 Post by gloover » Sun Jul 22, 2012 2:25 am

yrest (1000) means the bot is looking for this npc every 1 sec. (yrest is allways in msec. player:rest(..) is in sec.)

this will solve your problem

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<!-- #  1 --><waypoint x="-1039" z="1870" y="52">
   local Boss = player:findNearestNameOrId("bossname")
   repeat
     yrest(1000)
   until Boss   
   player:target(Boss.Address)
  player:fight()
</waypoint>
</waypoints> 
yes, u can change channel i.e. after leave combat or in your wp:

Code: Select all

if( 1 == RoMScript("GetCurrentParallelID()") ) then 
			sendMacro("ChangeParallelID(2)");
		else 
			sendMacro("ChangeParallelID(1)");
		end		

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

Re: Bot should stand on place and wait

#5 Post by lisa » Sun Jul 22, 2012 3:10 am

wouldn't you need the find mob inside the loop? otherwise it would just be stuck in the loop forever as the variable has been defined before the loop?

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<!-- #  1 --><waypoint x="-1039" z="1870" y="52">
   repeat
     yrest(1000)
   local Boss = player:findNearestNameOrId("bossname")
   until Boss   
   player:target(Boss.Address)
  player:fight()
</waypoint>
</waypoints> 

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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#6 Post by booting1 » Sun Jul 22, 2012 3:15 am

@lisa

i stand range 100-120 from respawn the boss. the boss walk in a very litte lange.

i log in see the boss. start the bot / waypoint. he kills the boss and go to loot. than he look for an other target kills this when i kann, or go back to start waypoint. there he stand, but when the bot come again the bot do nothing. when the boss attacks the bot, the bot die because he does nothing :)

i will test this from gloover.

@ gloover where i can found the boss-adress?

User avatar
gloover
Posts: 304
Joined: Wed Jul 07, 2010 4:31 am

Re: Bot should stand on place and wait

#7 Post by gloover » Sun Jul 22, 2012 3:21 am

Lisa, you've right - it belongs inside the loop ;-)

@ botting

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<!-- #  1 --><waypoint x="-1039" z="1870" y="52">
   repeat
     yrest(1000)
     local Boss = player:findNearestNameOrId("bossname")
   until Boss   
   player:target(Boss.Address)
  player:fight()
</waypoint>
</waypoints> 

should work. You dont need the boss adress - using this as written should work.

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

Re: Bot should stand on place and wait

#8 Post by lisa » Sun Jul 22, 2012 4:05 am

don't forget to add the name of the "boss"

Code: Select all

local Boss = player:findNearestNameOrId("bossname")
bossname needs to be changed to the name of the boss, or the ID.
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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#9 Post by booting1 » Sun Jul 22, 2012 12:04 pm

status:
start game start bot
bot kill and loot boss, bot attack another targeht, bot goes back to startpoint and wait
boss comes agaein bot crash

look screen.

in the xml file is the last code from gloover
in bossname stand the name from boss
Attachments
bot.JPG

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

Re: Bot should stand on place and wait

#10 Post by rock5 » Sun Jul 22, 2012 12:56 pm

'Boss' was made a local variable so it would only have a value inside the 'repeat' loop. Try this.

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<!-- #  1 --><waypoint x="-1039" z="1870" y="52">
   local Boss
   repeat
     yrest(1000)
     Boss = player:findNearestNameOrId("bossname")
   until Boss   
   player:target(Boss.Address)
  player:fight()
</waypoint>
</waypoints>
  • 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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#11 Post by booting1 » Sun Jul 22, 2012 2:33 pm

thank you

it looks good at the time. but now my next wish.

the bot shoud change the channels

i start on 1 after kill change to 2, after kill to 3, after kill to 1 and so on....


groovler has written this

if( 1 == RoMScript("GetCurrentParallelID()") ) then
sendMacro("ChangeParallelID(2)");
else
sendMacro("ChangeParallelID(1)");
end

i but this in the waypointfile but nothing will do.

User avatar
gloover
Posts: 304
Joined: Wed Jul 07, 2010 4:31 am

Re: Bot should stand on place and wait

#12 Post by gloover » Mon Jul 23, 2012 12:56 am

Post your whole script - me and other doesnt know where you have pasted this, so may it is without the loop.

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

Re: Bot should stand on place and wait

#13 Post by rock5 » Mon Jul 23, 2012 2:03 am

To make it so you can use it with any number of channels, try this instead.

Code: Select all

	local NumChannels = RoMScript("GetNumParalleZones()")
	local NextChannel = RoMScript("GetCurrentParallelID()") + 1
	if NextChannel > NumChannels then
		NextChannel = 1
	end
	sendMacro("ChangeParallelID(".. NextChannel ..")");
  • 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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#14 Post by booting1 » Thu Aug 02, 2012 11:32 am

where i have to do this?
at least of the waypointfile?

there comes an error,

file: .....boss.xml
line 12
column 1
pos 280
message junk after document element

when i file it so:

Code: Select all

......
</waypoint>
local NumChannels = RoMScript("GetNumParalleZones()")
   local NextChannel = RoMScript("GetCurrentParallelID()") + 1
   if NextChannel > NumChannels then
      NextChannel = 1
   end
   sendMacro("ChangeParallelID(".. NextChannel ..")");
</waypoints>
it do nothing, kills boss go back and stand, kill boss go back and stand...

when i but it before

Code: Select all

</waypoint>
it do nothing, kills boss go back and stand, kill boss go back and stand...

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

Re: Bot should stand on place and wait

#15 Post by rock5 » Thu Aug 02, 2012 11:39 am

All code has to be between tags so it has to be before </waypoint>. If it's after "player:fight()" then it should change channel after the fight. If it doesn't, maybe you can't change channel at that location. Have you tried to manually?
  • 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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#16 Post by booting1 » Fri Aug 03, 2012 9:48 am

Code: Select all

player:target(Boss.Address)
  player:fight()
local NumChannels = RoMScript("GetNumParalleZones()")
   local NextChannel = RoMScript("GetCurrentParallelID()") + 1
   if NextChannel > NumChannels then
      NextChannel = 1
   end
   sendMacro("ChangeParallelID(".. NextChannel ..")");
</waypoint>
</waypoints>
manuall i can change the channel. but the bot kills the boss and other enemys around his target. loots and go back to startpoint und wait, if boss respawn the bot kill again boss und enemys loot und wait...

but no change channel

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

Re: Bot should stand on place and wait

#17 Post by rock5 » Fri Aug 03, 2012 9:58 am

Maybe it's because it moves. Add a yrest after changing channel, however long it takes to change channel. I'm not sure how long it is.
  • 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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#18 Post by booting1 » Fri Aug 03, 2012 11:29 am

change takes 25seconts at the moment when i klick.

Code: Select all

player:target(Boss.Address)
  player:fight()
yrest(25000)
local NumChannels = RoMScript("GetNumParalleZones()")
   local NextChannel = RoMScript("GetCurrentParallelID()") + 1
   if NextChannel > NumChannels then
but nothing do.
Last edited by booting1 on Fri Aug 03, 2012 11:40 am, edited 1 time in total.

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

Re: Bot should stand on place and wait

#19 Post by rock5 » Fri Aug 03, 2012 11:40 am

So after changing channel (that's the ChangeParallelID command) add

Code: Select all

yrest(25000)
yrest is in ms.
  • 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

booting1
Posts: 67
Joined: Wed Jul 20, 2011 2:41 am

Re: Bot should stand on place and wait

#20 Post by booting1 » Fri Aug 03, 2012 11:42 am

oh my edit was to late. this 25000 i have don but on the right place?

one time i change manual to 1, there the boss cant attack, i was everthing between me and the boss after i think 25 the bot chance the channel. i cancle this, than the bot attacks the boss, after that nothing :(

edit:

ok i think now its go?!?!

i chanche manual zu channel 3, the bot kills the boss. stand and change to ch 1, there he go back to the startpoint. now there i have to wait for the boss.... i tell you later more :D

edit2:

normal i goes ok.

but a little problem. when another enemy is in range than he will kill this, and the 25 seconds will be ignored.

so the bot will not change and wait for the boss again,

when no other enemey is in range the bot change after 25sec.

when i say 60 seconds than i think the bot change after the fight with another enemy. i will test this now.

Post Reply

Who is online

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