Stopping waypoint: Target aquired before moving

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
Se7en
Posts: 2
Joined: Thu Jul 14, 2011 3:04 am

Stopping waypoint: Target aquired before moving

#1 Post by Se7en » Tue Aug 09, 2011 8:56 am

As topic says this is the message i get when trying to farm tp around sardo castle. Just keep typing this and dounst run or attack anything. Any ideas to what the problem might be? I dont get this error while running around fireboot outpost. Just down at sardo.

Bot says:
Stopping waypoint: Target aquired before moving
Moving to waypoint
Stopping waypoint: Target aquired before moving
Moving to wayoint

and so on...

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

Re: Stopping waypoint: Target aquired before moving

#2 Post by rock5 » Tue Aug 09, 2011 9:06 am

Is it posible it is seeing a target that it can't attack, such as one behind a wall or something? If so you might have to reduce MAX_TARGET_DIST in those areas. Although, that doesn't sound like the right messages you would get so I could be wrong.
  • 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: Stopping waypoint: Target aquired before moving

#3 Post by lisa » Tue Aug 09, 2011 9:19 am

It's the invisible "hiden" mob I've mentioned before, add it to friend list in your profile.
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
silinky
Posts: 213
Joined: Mon Nov 23, 2009 5:07 am

Re: Stopping waypoint: Target aquired before moving

#4 Post by silinky » Mon Dec 31, 2012 4:50 am

ok, i am sorry to revive this thread, but the search threw this one out and didn't think i need to create a topic with the same issue.
the problem is, that i have a card farming script, that is scanning for a specific mob in a certain radius, with this code:

Code: Select all

local mob = player:findEnemy(false, "Mob ID here")
it is successful, but in the script i also inserted a command, to go back to the initial place, if all mobs with that ID are killed.
this also would work, but only if no other mobs around (with different ID's)
when there is any other mob around, it just stays in place, spamming the message in the screenshot, with blue, and writing also my message in white which means that the script works ok, it just does not move to the initial place.
the waypoint type is "TRAVEL"
can anyone clue me in as to where is the problem?

(also, i had to edit player:findEnemy() function in classes.lua, because it kept finding the dead mob after i looted it and before it disappeared. this wasted time. could you include a life check in the next revision? if not, can you tell me how to non destructively tell the function only to target live mob?)

thanks
Attachments
Clipboard01.jpg

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

Re: Stopping waypoint: Target aquired before moving

#5 Post by rock5 » Mon Dec 31, 2012 5:06 am

I think we would need to see your code to figure out what is happening.
  • 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
silinky
Posts: 213
Joined: Mon Nov 23, 2009 5:07 am

Re: Stopping waypoint: Target aquired before moving

#6 Post by silinky » Mon Dec 31, 2012 6:20 am

sure, no problem :)
here it is.
if you spot things that could use some optimization feel free to post it, thx

Code: Select all

startGMDetect()
	
	local farmmob = 105486
	local farmmobselected = nil
	local huntingradius = nil
	changeProfileOption("MAX_TARGET_DIST", 250)
	
	local playerAddress
	local starterX = 0
	local starterY = 0
	local starterZ = 0
	
	function lootBags()
		local _bag = player:findNearestNameOrId("Mysterious Bag")
		if _bag then
			printf("BAG FOUND... LOOTING\n");
			local _dist = distance(player.X,player.Z,_bag.X,_bag.Z)
			player:target(_bag.Address);
			player:target_Object(_bag.Id,nil,true,true)
			yrest(1000)
			player:target_Object(_bag.Id,nil,true,true)
			yrest(1000)
	   end
	end
	
	playerAddress = memoryReadIntPtr(getProc(), addresses.staticbase_char, addresses.charPtr_offset);
		starterX = memoryReadFloat(getProc(), playerAddress + addresses.pawnX_offset) or starterX
		starterY = memoryReadFloat(getProc(), playerAddress + addresses.pawnY_offset) or starterY
		starterZ = memoryReadFloat(getProc(), playerAddress + addresses.pawnZ_offset) or starterZ

	-- changeOptionFriendMob("mob", farmmob, "Add")
	changeProfileOption("HARVEST_DISTANCE", 80)
	changeProfileOption("COMBAT_RANGED_PULL", true)
	changeProfileOption("QUICK_TURN",true)
	changeProfileOption("MAX_FIGHT_TIME",15)
	changeProfileOption("TARGET_LEVELDIF_BELOW", 70)
	changeProfileOption("TARGET_LEVELDIF_ABOVE", 5)
	changeProfileOption("COMBAT_DISTANCE", 50)
	changeProfileOption("ANTI_KS", false)
	changeProfileOption("WAYPOINT_DEVIATION", 0)
	changeProfileOption("AUTO_ELITE_FACTOR", 99999999)
	
	settings.profile.events.onLeaveCombat = function()
		lootBags()
	end
				
	
	setwindow("Card - " .. farmmob)
	
	function run(speed)
		RunningSpeed = speed
		local playerAddress = memoryReadIntPtr(getProc(), addresses.staticbase_char, addresses.charPtr_offset);
		if playerAddress ~= 0 then
			memoryWriteFloat(getProc(), playerAddress + 0x40, RunningSpeed);
			printf("------------------------------\nCurrent speed is set to "..RunningSpeed..".\n------------------------------\n");
		end
	end

	function mobWait(_waitTime)
		local starttime = os.clock()
		repeat
			yrest(500)
			printf("Scanning for ".. farmmob ..".\n");
			if farmmob ~= "undefined" then farmmobselected = farmmob end
			local mob = player:findEnemy(false, farmmobselected)

			if not mob then
				printf("No ".. farmmob .." nearby.\n")
				lootBags()
				player:lootAll()
				if (distance(player.X,player.Z,starterX,starterZ) > 100) then
					printf("Moving home.\n")
					player:moveTo(CWaypoint(starterX, starterZ, starterY))
				end
				break
			end
			
			if (huntingradius ~= nil) and (distance(player.X,player.Z,starterX,starterZ) > huntingradius) then
				printf("We're far enough now, moving home.\n")
				player:moveTo(CWaypoint(starterX, starterZ, starterY))
				break
			end
			
			if mob then
				printf(farmmob .. " found, engaging...\n");
				player:target(mob)
				player:update()
				player:fight()
				player:loot()
				CleanBag(3000, 2)
				run(65)
				break				
			end
			
		until os.clock() - starttime > _waitTime
	end
	
	function unStick3()
		player:moveTo(CWaypoint(starterX, starterZ, starterY))
	end
	
	while (true) do
		mobWait(1)
	end
also, could you provide me a solution for the bot not to clear targets all the time? (after fight and loot, it cleares target 2 times, with 1 second interval, and wastes time. not a problem, just a nuisance)

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

Re: Stopping waypoint: Target aquired before moving

#7 Post by rock5 » Mon Dec 31, 2012 6:28 am

The player:moveTo function looks for mobs while moving unless you use 'true' as a second argument. eg.

Code: Select all

player:moveTo(CWaypoint(starterX, starterZ, starterY), true)
  • 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
silinky
Posts: 213
Joined: Mon Nov 23, 2009 5:07 am

Re: Stopping waypoint: Target aquired before moving

#8 Post by silinky » Mon Dec 31, 2012 6:40 am

wow thanks, i didn't know that :)

Post Reply

Who is online

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