findnearestnameorid, issue I can't work out

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

findnearestnameorid, issue I can't work out

#1 Post by lisa »

Ok Since playing with old revision some things have been bugging me.

I did some testing
in player.lua I added in a print inside function CPlayer:findNearestNameOrId(_objnameorid, ignore)

Code: Select all

		if( obj ~= nil ) then
		printf("Name "..obj.Name.." \n")
small snippet when there was 2 cavy close by.

Code: Select all

Name Willow Wood
Name Elemental Cavy
Name
Name Willow Wood
Name Elemental Cavy
Name
Name Bandit
Name To Maidge's Farm
Name To Forsaken Academy
Name Bandit
Quite obviously the names are there for the cavy "Elemental Cavy"
i had already adjusted catchcavy to suit and also added in some print statements.

Code: Select all

_cavy = {"Golden Elemental Cavy","Elemental Cavy"}

Code: Select all

if not cavy then return else printf("found a cavy\n") end
So it should have printed that it had found a cavy but it didn't.

Reason I posted here and not in cavy topic is because I only used the cavy as an example I can control, they pop out regularly lol

So it makes no sence to me =(
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: findnearestnameorid, issue I can't work out

#2 Post by rock5 »

If you are talking about 477, CPlayer:findNearestNameOrId doesn't accept tables in that version, as I've stated before.
  • 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: findnearestnameorid, issue I can't work out

#3 Post by lisa »

Well that would explain it lol

k thanks I'll work on it some more =)
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
Post Reply