Andor Training Range again (help request)

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
radulfizz
Posts: 19
Joined: Thu Sep 23, 2010 7:09 am

Andor Training Range again (help request)

#1 Post by radulfizz » Sat Mar 09, 2013 5:03 am

Hi all,

I only recently began to do this mini game, so I have no idea if they changed anything about it,
but none of the scripts in the other thread is really working for me.

As far as I see it, the problem is how the mobs are being targeted:
playing manually, it seems you have to first use the skill, then click a mob,
and player:target somehow isnt reproducing the clicking part.

So here's my sub-par code

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<waypoints>
  <onLoad>
        
    function ignore(a)
      return (math.random(100)>75)
    end

    creatures={106883,106882,106881,106884}	
    mytarget=nil
    while true do
      for k,id in pairs(creatures) do
        mytarget=player:findNearestNameOrId(id,0,ignore)
          if mytarget~=nil then
          print("shoot "..mytarget.Address.." "..mytarget.Name)                  
          player:target(mytarget)
          yrest(50)
          RoMScript("UseExtraAction(1)")
          rest(50)
          player:target(mytarget)
          yrest(50)
          break;
        end
      end
    end
    
  </onLoad>
</waypoints>
Sometimes it actually shoots at a mob, but very rarely.

Thanks for any input.

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

Re: Andor Training Range again (help request)

#2 Post by lisa » Sat Mar 09, 2013 5:31 am

I used this when I did it.

Code: Select all

player:target(obj)
RoMScript("UseExtraAction(1)")
yrest(10)
player:target(obj)
RoMScript("UseExtraAction(1)")
if ID == 106883 then
	yrest(10)
	player:target(obj)
	RoMScript("UseExtraAction(1)")	
end
I don't understand why your "ignore" is just a random number generator, that makes no sence

This is what I used to use.
AndorTraining.xml
(2.22 KiB) Downloaded 522 times
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

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

Re: Andor Training Range again (help request)

#3 Post by dr-nuker » Sat Mar 09, 2013 12:11 pm

I still use the script from the forum and it works great for me in timed training.
For survival i do not score very high points but it's okay.

http://www.solarstrike.net/phpBB3/viewt ... ilit=Andor

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: Andor Training Range again (help request)

#4 Post by Ego95 » Sat Mar 09, 2013 5:45 pm

Hi lisa,

I tried your script. Had to translate a few ChoiceOptionByName and decreased the countdown from 12 to 10 because it started too late. But After round 8 too many mobs went over the line so the game was over. The bot errored with this print in der micromacro window:

Code: Select all

resting a little before attacking, countdown starts now.
12
11
10
9
8
7
6
5
4
3
2
1
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
Did not find any crashed game clients.
11:38pm - [string "..."]:81: attempt to index global 'buffed' (a boolean value)


Please enter the script name to run.
Type in 'exit' (without quotes) to exit.
Script>
What happened? :O

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

Re: Andor Training Range again (help request)

#5 Post by lisa » Sat Mar 09, 2013 9:05 pm

line 83 has this

Code: Select all

			until buffed.Level >= 2800 or not player:hasBuff(622402)
swap them around so the not hasbuff is before the .Level


Code: Select all

			until not player:hasBuff(622402) or buffed.Level >= 2800
--=== It should actually stop there anyway as it is the end of the file, so I changed the print to an error ===--
AlterEgo95 wrote:I tried your script.
technically I wouldn't call it mine, pretty sure I just updated/fixed a version someone else posted, can't remember who.
AlterEgo95 wrote:Had to translate a few ChoiceOptionByName
If I get a little time later I will look up the ID's for the choices, I just search for them in CE.

Give this a try.
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

radulfizz
Posts: 19
Joined: Thu Sep 23, 2010 7:09 am

Re: Andor Training Range again (help request)

#6 Post by radulfizz » Sun Mar 10, 2013 3:30 am

I don't understand why your "ignore" is just a random number generator, that makes no sence
Just a quick way to make the bot shoot at different targets without having to keep a list of old objects.

Cindy
Posts: 237
Joined: Fri Sep 28, 2012 4:23 pm

Re: Andor Training Range again (help request)

#7 Post by Cindy » Sun Mar 10, 2013 4:09 pm

lisa wrote:line 83 has this

Code: Select all

			until buffed.Level >= 2800 or not player:hasBuff(622402)
swap them around so the not hasbuff is before the .Level


Code: Select all

			until not player:hasBuff(622402) or buffed.Level >= 2800
--=== It should actually stop there anyway as it is the end of the file, so I changed the print to an error ===--
AlterEgo95 wrote:I tried your script.
technically I wouldn't call it mine, pretty sure I just updated/fixed a version someone else posted, can't remember who.
AlterEgo95 wrote:Had to translate a few ChoiceOptionByName
If I get a little time later I will look up the ID's for the choices, I just search for them in CE.

Give this a try.

Hangs at dialog window with Magelly. Presumably the getTEXT?

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

Re: Andor Training Range again (help request)

#8 Post by lisa » Sun Mar 10, 2013 9:07 pm

Cindy wrote:Hangs at dialog window with Magelly. Presumably the getTEXT?
*slaps forehead*

I got the text but never actually used it for anything lol
AndorTraining.xml
V 1.6
(2.48 KiB) Downloaded 290 times
Attachments
AndorTraining.xml
V 1.7
(2.53 KiB) Downloaded 414 times
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

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: Andor Training Range again (help request)

#9 Post by Ego95 » Tue Mar 12, 2013 9:18 am

The game always crashes in wave 8 :/
Additionally the countdown doesn't work always like it should. It starts to early or to late. I think I'm going to try it with my alts the next days, my main already lost 90 phirius coins because the game was crashing

AlterEgo95

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

Re: Andor Training Range again (help request)

#10 Post by lisa » Tue Mar 12, 2013 10:19 am

yeah other people posted about the game crashing aswell, it never did for me though so I can't work out the issue as I don't have 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

Jandrana
Posts: 187
Joined: Thu Jul 05, 2012 5:53 am

Re: Andor Training Range again (help request)

#11 Post by Jandrana » Tue Mar 12, 2013 10:33 am

I don't know why you bother with this game except if you like to be ranked in the server list or want to get the titles.

The rewards are completely unrelated to the score you do. It is completely random. If you don't shoot anything you get the same stuff as if you reach round 10.

Some guild mates do shoot the rabbits in the first wave only, so the game is over quicker ;-).

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

Re: Andor Training Range again (help request)

#12 Post by dr-nuker » Tue Mar 12, 2013 5:47 pm

lisa wrote:yeah other people posted about the game crashing aswell, it never did for me though so I can't work out the issue as I don't have it.
I had that also but with updating the object before casting at it i did not reproduce crashes of the game in the last weeks.

Additionally I have to say that I feel like the rewards are a bit better if you do not loose too fast. So to say I receive two keys quite often...

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

Re: Andor Training Range again (help request)

#13 Post by lisa » Tue Mar 12, 2013 7:44 pm

So something like this?

Code: Select all

						if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then
							obj:update()
							player:target(obj)
							RoMScript("UseExtraAction(1)")
							yrest(10)
							obj:update()
							player:target(obj)
							RoMScript("UseExtraAction(1)")
							if ID == 106883 then
								yrest(10)
								obj:update()
								player:target(obj)
								RoMScript("UseExtraAction(1)")	
							end
							yrest(100)
						end
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

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

Re: Andor Training Range again (help request)

#14 Post by rock5 » Tue Mar 12, 2013 11:16 pm

I think the idea is that by the time you get to the end of the object list, items on the list may no longer be valid. So the idea of doing obj:update() is to detect invalid objects and not try to act on them. You added a few updates but only one is needed to check if the object is still valid. And you didn't even put one where it's really needed, after "obj = objectList:getObject(i)" and before "if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then". :) The update will make Id = 0 for invalid items which means the 'if' statement will skip 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
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Andor Training Range again (help request)

#15 Post by lisa » Wed Mar 13, 2013 1:48 am

so like this

Code: Select all

					for i = 0,objSize do 
						obj = objectList:getObject(i)
						obj:update()
						if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then
							player:target(obj)
							RoMScript("UseExtraAction(1)")
							yrest(10)
							player:target(obj)
							RoMScript("UseExtraAction(1)")
							if ID == 106883 then
								yrest(10)
								player:target(obj)
								RoMScript("UseExtraAction(1)")	
							end
							yrest(100)
						end
					end
AndorTraining.xml
V 1.9
(2.54 KiB) Downloaded 327 times
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

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

Re: Andor Training Range again (help request)

#16 Post by rock5 » Wed Mar 13, 2013 3:04 am

If it's like I said then that should work.
  • 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

C3PO
Posts: 109
Joined: Sun Jul 10, 2011 2:45 pm

Re: Andor Training Range again (help request)

#17 Post by C3PO » Wed Mar 13, 2013 8:44 am

Hi,

yesterday I used andorTraining V1.8 and it worked fine today (with another char) it didn't

Code: Select all

1
targeting: 106882
...
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
targeting: 106882
targeting: 106882
targeting: 106881
targeting: 106883
targeting: 106884
Did not find any crashed game clients.
2:37pm - [string "..."]:93: attempt to index global 'buffed' (a boolean value)

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

Re: Andor Training Range again (help request)

#18 Post by lisa » Wed Mar 13, 2013 8:47 pm

you could give 2.0 a try lol
eventually we might get a version that works for everyone.
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

C3PO
Posts: 109
Joined: Sun Jul 10, 2011 2:45 pm

Re: Andor Training Range again (help request)

#19 Post by C3PO » Thu Mar 14, 2013 4:26 pm

I will try it with my next char.

with andorTraining V1.8 I got today the error

Code: Select all

1
targeting: 106882
targeting: 106882
targeting: 106881
Did not find any crashed game clients.
10:20pm - D:/MicroMacro/scripts/rom/functions.lua:725: bad argument #1 to 'memor
yReadByte' ((null))
and the game crashed.


PS.: another question due to this failure ... should it be like this that the bot writes that it "Did not find any crashed game clients." when the game crashed?

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: Andor Training Range again (help request)

#20 Post by Ego95 » Thu Mar 14, 2013 5:12 pm

you could give 2.0 a try lol
eventually we might get a version that works for everyone.
The main problem is, that on the one hand the bot always waits 3-4 seconds after the mobs began to run, but on the other side sometimes there is one mob left which it doesn't notice. So the 12 seconds countdown start but the next wave comes about 10 seconds later. This is why the bot then tries to target the mobs too early. Best way really would be, to check for the messages: At first it says something like "Wave X" completed, then "Wave X", "Get ready!" and last "Go!"
I don't know why you bother with this game except if you like to be ranked in the server list or want to get the titles.

The rewards are completely unrelated to the score you do. It is completely random. If you don't shoot anything you get the same stuff as if you reach round 10.

Some guild mates do shoot the rabbits in the first wave only, so the game is over quicker ;-).
Wrong. If you get a high score you get a few epic items: you can get a lock or a key, sometimes you get two keys or two locks. If you change 1x lock and 1x key you get item shop prizes like 10x Transport Runes.

AlterEgo95

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Google [Bot] and 48 guests