Page 1 of 1

player:findNearestNameOrId seems not to work?

Posted: Thu May 09, 2013 3:03 am
by gloover
Hey Rock, greetz lisa.

Long time since I've used the bot, but now I wants to farm some boss skins and tried my old script:

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints type="RUN">
<onLoad>
	changeProfileOption("MAX_TARGET_DIST", 400);
	
	local BOSSName = "100625"			-- 100625= Locface 
	
	
	while (true) do
		yrest (5000)
		player:update()
		player:checkSkills(true)
		useMaidItems()
			local BOSS = player:findNearestNameOrId(BOSSName)
			if BOSS then
				cprintf(cli.red,"BOSS Detection! \n")
				printf("\a\a\a");
			end
	end

</onLoad>
</waypoints>
So there are 2 Problems:

1. the boss alarm goes on whole the time, even if locface is not respawned.
2. player:checkSkills(true) does not rebuff. Have also tried using this in Commandline - nothing happens.

Last but not least: how can I find the Spell-ID - not the buff-ID, which is not listed on runesdatabase? i.e. Champion has a spell called "forge" (german: Schmiede) - its also listed in your skills.xml, but after level 22 or round about them, it will be changed/renamed (german: Esse) also the buff id is another. The new buff has the ID 622184, but how to find the Spell-ID. Is there a macro, similar to the one finding buff-ID's?

thx in advance!

Re: player:findNearestNameOrId seems not to work?

Posted: Thu May 09, 2013 4:17 am
by rock5
Start the commandline and enter the following command

Code: Select all

table.print(FindSkillBookSkill("skill name"))
It should print something like this.

Code: Select all

Command> table.print(FindSkillBookSkill("Forge"))
table: 0546A800
skillnum:       1
Id:     498604
TPToLevel:      150
BaseItemAddress:        669804544
skilltab:       4
Address:        668642816
Level:  0
Name:   Forge
aslevel:        2

Re: player:findNearestNameOrId seems not to work?

Posted: Sat May 11, 2013 12:19 pm
by gloover
Thx rock. I seem to remember allready use this print function for a long time ;-)

The other thing (not updating the buff by using player:checkSkills(true)) is really crazy - find out, that specifying the type of waipont (here "RUN") it seems to ignore this function.

Have delete the waypoint type, now it works as it should.

Sorry for the delay of my response - sommething is wrong with the forum - I couldt log in for the last 2 days.

Re: player:findNearestNameOrId seems not to work?

Posted: Sat May 11, 2013 2:05 pm
by rock5
I had a look. I couldn't find any code that would cause player:checkSkills(true) not to run just because the waypoint was type "RUN". Maybe there is some other settings stopping it from working, eg. if you set your buffs inbattle=true then it wouldn't cast.

Re: player:findNearestNameOrId seems not to work?

Posted: Sun May 12, 2013 6:07 pm
by lisa
gloover wrote:The other thing (not updating the buff by using player:checkSkills(true)) is really crazy - find out, that specifying the type of waipont (here "RUN") it seems to ignore this function.
That is weird, if I get a chance I'll do some testing later, I know that if you are mounted it won't buff.

gloover wrote:Sorry for the delay of my response - sommething is wrong with the forum - I couldt log in for the last 2 days.
I had the same issue, I think it was because the forum was renewed and I had to delete the temp internet files before it would work again.