Andor training

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
newton666
Posts: 81
Joined: Fri Oct 22, 2010 3:16 pm

Andor training

#1 Post by newton666 » Tue May 14, 2013 3:59 pm

Anyone have a working andor training scripte that swap accounts after it finishes?
Ive been trying to get this one to work but i give up and maybe you guys may have better luck :-

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints type="TRAVEL">
<onLoad>


   --=== User Options ===--


   When_Finished = "charlist"
      -- "end" to end script, "relog" to log next character, "charlist" to log next in 'charlist' and "waypointfilename" to load that waypointfile.

   CharList = {
			{account=1, chars= {1}},
			{account=2, chars= {1}},
			{account=3, chars= {1}},
			{account=4, chars= {1}},
			{account=5, chars= {3}},
			{account=6, chars= {3}},
			{account=7, chars= {1}},
			{account=9, chars= {2}},
			{account=10, chars= {1}},



		}

   --====================--
   


   local kate = GetIdName(121035)  --Kate Wesker
   local magelly = GetIdName(120687)  --Magelly Basac
   

   
   
   --== MINIGAME ==--
   repeat
      player:update()
      if getZoneId() ~= 355 then
         
         local empties = inventory:itemTotalCount(0)
         if 5 > empties then
            -- Wait for user to make some space in inventory.
            cprintf(cli.yellow,"Not much space left in inventory. Are you sure you want to continue with only %d spaces left?\n",empties)
            player:sleep()
         end
         if 30 > inventory:itemTotalCount(203038) then
            print("Not enough Phirius Token Coins.")
            logentry = "Not enough Phirius Token Coins."
         --   checkRelog()
            return
         end

         if player:target_NPC(kate) then
            sendMacro("ChoiceOption(1);");
            yrest(1000);
            waitForLoadingScreen(10)
            if getZoneId() ~= 360 then
            print("Failed to teleport into Ancient Treasure. Maybe you already done it today.")
            logentry = "Failed to teleport into Ancient Treasure. Maybe you already done it today."
            end
         --   checkRelog()
         end


         if player:target_NPC(magelly) then
            yrest(2000);
            sendMacro("ChoiceOption(2);");   --Make it 1 if you want Timed arena
            yrest(2000);
            sendMacro("ChoiceOption(1);");
            yrest(2000);
            sendMacro("ChoiceOption(1);");
            yrest(12000);
            --   checkRelog()
            --   return

         end
      end


      
      repeat
            yrest(10)
         until  player:findNearestNameOrId(106881)
         print("OK event has started")
         repeat
            tort()
            player:update()
            buffed = player:getBuff(622402)
            yrest(10)
         until buffed.Level >= 2800 or not player:hasBuff(622402)
         print("Event finished, end score was "..buffed.Level)
       error("Ending script")
      

    
   until false
   
   
</onLoad>
</waypoints>

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

Re: Andor training

#2 Post by lisa » Tue May 14, 2013 5:54 pm

bits to change are at the top

Code: Select all

		SetCharList({
			{account=5, chars= {}},
			{account=6, chars= {}},
			{account=7, chars= {}},
			{account=8, chars= {}},
			{account=9, chars= {}},
			{account=10, chars= {}},
		})

Code: Select all

local requiredscore = 30

Code: Select all

local goMessage = "Go"
there are descriptions for the last 2 in the file.
Attachments
andy1.xml
(3.55 KiB) Downloaded 387 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

newton666
Posts: 81
Joined: Fri Oct 22, 2010 3:16 pm

Re: Andor training

#3 Post by newton666 » Wed May 15, 2013 6:26 am

i'm just using your ""andy1.xml" file and just changed the accouts .
and "local requiredscore = 2700. But how come the file will just fire a few fireballs at the start then just stops and does nothing?

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<waypoints>
	<onLoad>
		unregisterTimer("GMdetection");
		SetCharList({
			{account=1, chars= {1}},
			{account=2, chars= {1}},
			{account=3, chars= {1}},
			{account=4, chars= {1}},
			{account=5, chars= {3}},
			{account=6, chars= {3}},
			{account=7, chars= {1}},
			{account=9, chars= {2}},
			{account=10, chars= {1}},

		})
	
	
		-- V 3.5
		<![CDATA[
		
			--=== user options ===--
			-- it will stop once this score is reached, bonuses will be added afterwards though 
			-- so 2700 will probably be total score of 3100
			local requiredscore = 2700
			
			-- alter to your local language, caps sensative, in english is "Go!!!", so "Go" is enough
			local goMessage = "Go"		
		
		
		
			if getZoneId() == 2 and 30 > inventory:itemTotalCount(203038) then
				LoginNextChar()
				loadProfile()
				loadPaths(__WPL.FileName)
				return
			end

			for k,v in pairs(settings.profile.skills) do
				v.AutoUse = false
			end

			id_kate		= 121035
			id_magelly	= 120687

			-- Move to Kate Wesker and enter
			if getZoneId() == 2 then
				repeat
					yrest(500)
				until player:target_NPC(id_kate)

				repeat
					yrest(500)
				until ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_24")) 

				yrest(1000)
				waitForLoadingScreen()
			end
			
			-- Move to Magelly Basac
			repeat
				yrest(500)
			until player:target_NPC(id_magelly)

			-- Check if we already completed
			repeat
				yrest(500)
			until ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_14")) 
			
 
			repeat
				yrest(500)
			until ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_25")) 
			

			repeat
				yrest(500)
			until ChoiceOptionByName(getTEXT("SYS_OKAY")) 
			yrest(1000)

			local round = 0
			local score = 0

			function tort()
				local proc = getProc()
				
				local function checkclicked(address)
					local tmp = memoryReadRepeat("int", proc, address + addresses.pawnAttackable_offset) or 0;
					if bitAnd(tmp,0x8) then
						return true
					else
						return false
					end
				end

				local function one(ID)
					--print("targeting: "..ID)
					local objectList = CObjectList();
					objectList:update();
					local objSize = objectList:size()
					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
				end
				if player:findNearestNameOrId(106881,106882,106883,106884) then
					--== monitor chat
					EventMonitorStart("Tortevent", "SYSTEM_MESSAGE");
					local time, moreToCome, name, msg, _go 
					repeat
						time, moreToCome, name, msg = EventMonitorCheck("Tortevent",1)
						yrest(10)
						if name and string.find(name,goMessage) then
							_go = true
						end
					until _go == true
					EventMonitorStop("Tortevent")
					round = round + 1
					print("Wave: "..round..", Score: "..score)
					yrest(1000)
					one(106882)
					yrest(1000)
					one(106882)
					one(106884)
					one(106884)
					one(106884)
				end
			end

			repeat
				yrest(100)
			until  player:findNearestNameOrId(106881)
			print("OK event has started")
			tort()
			repeat yrest(1000) until not RoMScript("TimeKeeperFrame:IsVisible()")
			yrest(15000)
			logloot()
			LoginNextChar()
			loadProfile()
			loadPaths(__WPL.FileName)
		]]>
	</onLoad>
</waypoints>

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

Re: Andor training

#4 Post by lisa » Wed May 15, 2013 8:51 am

forum search got this, just work out what you want to use from each
http://www.solarstrike.net/phpBB3/viewt ... 730#p48730
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

newton666
Posts: 81
Joined: Fri Oct 22, 2010 3:16 pm

Re: Andor training

#5 Post by newton666 » Wed May 15, 2013 2:33 pm

OMG you guys make it sound so easy and me tearing my hair out to get this to work. But still no joy. Can someone please edite my scripte so that it works and i can get some sleep

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<waypoints>
	<onLoad>
		-- V 3.2
		<![CDATA[
			--=== user options ===--
   SetCharList({
   {account=3 , chars= {1}},
   {account=5 , chars= {1}},
   {account=6 , chars= {1}},
   })
      LoginNextChar()
      loadprofile()
      loadPaths(__WPL.FileName);
    end
   local function loadprofile()
      -- Re-initialize player
      player = CPlayer.new();
      settings.load();
      settings.loadProfile(convertProfileName(player.Name))
   end

			-- it will stop once this score is reached, bonuses will be added afterwards though 
			-- so 4700 will probably be total score of 3100
			local requiredscore = 2700
			
			-- alter to your local language, caps sensative, in english is "Go!!!", so "Go" is enough
			local goMessage = "Go"
			
			id_kate		= 121035
			id_magelly	= 120687
						
			-- Move to Kate Wesker and enter
			if getZoneId() == 2 then
				player:target_NPC(id_kate)
				
				--ChoiceOptionByName("Transport to Andor Training Range"); 
				--yrest(1000)
				ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_24")) 
				yrest(1000)
				
				waitForLoadingScreen()
			end
			-- Move to Magelly Basac
			player:target_NPC(id_magelly)
			
			-- Check if we already completed
			--ChoiceOptionByName("Register for timed training"); yrest(1000)  
			ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_14")) yrest(1000)
			
			--ChoiceOptionByName("Participate in training"); yrest(1000)  
			ChoiceOptionByName(getTEXT("SKWERL_MOBIUS_25")) yrest(1000)
			
			--ChoiceOptionByName("Confirm"); yrest(1000)
			ChoiceOptionByName(getTEXT("SYS_OKAY")) yrest(1000) --(might be wrong)
			
			local round = 0
			local score = 0
			
			function tort()
				local proc = getProc()
				
				local function checkclicked(address)
					local tmp = memoryReadRepeat("int", proc, address + addresses.pawnAttackable_offset) or 0;
					if bitAnd(tmp,0x8) then
						return true
					else
						return false
					end
				end

				local function one(ID)
					--print("targeting: "..ID)
					local objectList = CObjectList();
					objectList:update();
					local objSize = objectList:size()
					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
				end
				if player:findNearestNameOrId(106881,106882,106883,106884) then
					--== monitor chat
					EventMonitorStart("Tortevent", "SYSTEM_MESSAGE");
					local time, moreToCome, name, msg, _go 
					repeat
						time, moreToCome, name, msg = EventMonitorCheck("Tortevent",1)
						yrest(10)
						if name and string.find(name,goMessage) then
							_go = true
						end
					until _go == true
					EventMonitorStop("Tortevent")
					round = round + 1
					print("Wave: "..round..", Score: "..score)
					repeat
						one(106882)
						one(106882)
						one(106881)
						one(106883)
						one(106884)
					until not player:findNearestNameOrId(106881,106882,106883,106884)
				end
			end
			
			repeat
				yrest(100)
			until  player:findNearestNameOrId(106881)
			print("OK event has started")
			repeat
				tort()
				player:update()
				yrest(100)
				buffed = player:getBuff(622402)
				if buffed then score = buffed.Level end
			until not player:hasBuff(622402) or ( buffed and buffed.Level > requiredscore )
			error("Event finished, end score was "..score)
		]]>
	</onLoad>
</waypoints>

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

Re: Andor training

#6 Post by lisa » Wed May 15, 2013 8:03 pm

Just so u know the score means nothing when it comes to the loot you receive, been running that exact same file I posted which literally scores 40-60 points and I regularly get 3 reward.
Attachments
andy1.xml
3.7
(3.83 KiB) Downloaded 375 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

newton666
Posts: 81
Joined: Fri Oct 22, 2010 3:16 pm

Re: Andor training

#7 Post by newton666 » Thu May 16, 2013 1:39 am

Thank for helping lisa but its still not logging out and changing to new acccounts or characters. instead i get attempt to call globe"logloot"<a Nil value" when finished?
do i need to download a function called "logloot"?

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

Re: Andor training

#8 Post by lisa » Thu May 16, 2013 2:12 am

I did a forum search for "logloot"

guess what it gave the link to the userfunction
http://www.solarstrike.net/phpBB3/viewt ... oot#p48909

You can just comment out the logloot() in the WP using --

so it would look like

Code: Select all

--logloot()
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

newton666
Posts: 81
Joined: Fri Oct 22, 2010 3:16 pm

Re: Andor training

#9 Post by newton666 » Thu May 16, 2013 1:36 pm

thankyou , thankyou lisa it works great !!!
I've got 1 more favour if its not too much of a trouble.
All i want this to do is exit and change account and character when it reaches waypoint 5. keep getting errors:-

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints type="TRAVEL">
   
<onLoad>
  SetCharList({
         {account=1, chars= {1}},
         {account=2, chars= {1}},
         {account=3, chars= {1}},
         {account=4, chars= {1}},
         {account=5, chars= {3}},
         {account=6, chars= {3}},
         {account=7, chars= {1}},
         {account=9, chars= {2}},
         {account=10, chars= {1}},



      
   })
      LoginNextChar()
      loadProfile()
      loadPaths("__WPL.FileName");
end
</onLoad>
   <!-- #  1 --><waypoint x="-626" z="-5927" y="25">   </waypoint>
   <!-- #  2 --><waypoint x="-613" z="-5837" y="23">      player:target_NPC("Logar Bulletin Board");
   </waypoint>
   <!-- #  3 --><waypoint x="-621" z="-5903" y="25">   </waypoint>
   <!-- #  4 --><waypoint x="-631" z="-5992" y="26">      player:target_NPC("Dell");
   <!-- #  5 --><waypoint x="-631" z="-5992" y="26">  </waypoint>
      LoginNextChar()
      loadProfile()
      loadPaths("__WPL.FileName");
</waypoints>
Thank again .

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

Re: Andor training

#10 Post by rock5 » Thu May 16, 2013 1:57 pm

Firstly, like I said before, __WPL.FileName is a variable, not a string. You should learn to tell the difference. So it should be loadPaths(__WPL.FileName);.

With the above fix, waypoint 5 should work, but you have a mistake in the onload. It looks like you tried to create the "relog" function but you missed the first line

Code: Select all

function relog()
So you have 2 choices to fix it.

1. Finish creating the relog function in the onload by adding function relog() like your other script and use relog() at waypoint 5.

or

2. Leave waypoint 5 as it is and change the onload to only set the character list.

Code: Select all

<onLoad>
  SetCharList({
         {account=1, chars= {1}},
         {account=2, chars= {1}},
         {account=3, chars= {1}},
         {account=4, chars= {1}},
         {account=5, chars= {3}},
         {account=6, chars= {3}},
         {account=7, chars= {1}},
         {account=9, chars= {2}},
         {account=10, chars= {1}},
    
   })
</onLoad>
  • 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

kenzu38
Posts: 279
Joined: Sun Dec 02, 2012 8:52 am

Re: Andor training

#11 Post by kenzu38 » Thu May 16, 2013 11:50 pm

Also, in that latest code you posted, you have a missing and a misplaced closing tag. Do take care where you put those </waypoint> .

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 9 guests