Page 1 of 1

Level Up Skills on Level up.

Posted: Wed Jul 20, 2011 3:41 pm
by Bojer
Ok first I would like to say hello. Just found this site a few days ago and started using this. I think so far I have most of it down though I am having a heck of a time getting my skills to level up automatically. Read all the links I could find on it and thought I had it but keep getting an error. This is what I have so far .....

in the 1-10 profile ....

<onLevelup>

-- single skill would be: sendMacro("SetSpellPoint(4,2);"); <<<<<<<<<<-------------------------Not sure what this does though
-- or levelupSkill(_skillname, _times)
levelupSkills1To10();

</onLevelup>

In my profile as I wish to upgrade several at a time....

<onLevelup>
levelupSkill(_PRIEST_RISING_TIDE , _1)
levelupSkill(_PRIEST_REGENERATE , _1)
levelupSkill(_PRIEST_GRACE_OF_LIFE , _1)
levelupSkill(_PRIEST_WAVE_ARMOR , _1)
levelupSkill(_PRIEST_HEAL , _1] )
</onLevelup>

Also trying to fine tune my Farm / Repair / Sell waypoint setup.......

<?xml version="1.0" encoding="utf-8"?><waypoints>
<!-- # 1 --><waypoint x="-586" z="-407" y="145"> </waypoint>
<!-- # 2 --><waypoint x="-192" z="-227" y="132">
if 2 > inventory:itemTotalCount(0) then
loadPaths("Repair")
end
</waypoint>
<!-- # 3 --><waypoint x="-37" z="-193" y="136"> </waypoint>
<!-- # 4 --><waypoint x="344" z="-401" y="143">
if 2 > inventory:itemTotalCount(0) then
loadPaths("Repair")
end
</waypoint>
<!-- # 5 --><waypoint x="697" z="-161" y="144"> </waypoint>
<!-- # 6 --><waypoint x="841" z="-233" y="151">
if 2 > inventory:itemTotalCount(0) then
loadPaths("Repair")
end
</waypoint>
<!-- # 7 --><waypoint x="561" z="-798" y="141"> </waypoint>
<!-- # 8 --><waypoint x="-125" z="-795" y="137">
if 2 > inventory:itemTotalCount(0) then
loadPaths("Repair")
end
</waypoint>
<!-- # 9 --><waypoint x="-527" z="-518" y="153"> </waypoint>
</waypoints>

Is my current Farm set up. Couple questions with it....is the "if 2 > inventory:itemTotalCount(0) then loadPaths("Repair") end" correct if I want to go sell when I have less than 2 slots open in my bags? Also can I put it after each waypoint? And finally can i make it so it checks to see if I am out of Mana Pots at the same time it checks my bags?

Here is each of the 3 files .....
Bojer.xml
(9.09 KiB) Downloaded 112 times
Farm.xml
(930 Bytes) Downloaded 114 times
Repair.xml
(2.96 KiB) Downloaded 110 times

Re: Level Up Skills on Level up.

Posted: Wed Jul 20, 2011 9:51 pm
by rock5
I broke levelupSkill and levelupSkills1To10 and haven't fixed them yet. "SetSpellPoint" should work as long as you know how to use it.
http://www.theromwiki.com/API:SetSpellPoint

If you want to check when to go for repairs at every waypoint then you could create a little functiuon in the onload section of the waypoint and just use the function name at the waypoints.

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
	<onLoad>
		function CheckRepar()
			if 2 > inventory:itemTotalCount(0) or
				inventory:bestAvailableConsumable("healing") == false then
				loadPaths("Repair")
			end
		end
	</onLoad>
				
	<!-- #  1 --><waypoint x="-586" z="-407" y="145">CheckRepar()	</waypoint>
	<!-- #  2 --><waypoint x="-192" z="-227" y="132">CheckRepar()	</waypoint>
	<!-- #  3 --><waypoint x="-37" z="-193" y="136">CheckRepar()	</waypoint>
	<!-- #  4 --><waypoint x="344" z="-401" y="143">CheckRepar()	</waypoint>
	<!-- #  5 --><waypoint x="697" z="-161" y="144">CheckRepar()	</waypoint>
	<!-- #  6 --><waypoint x="841" z="-233" y="151">CheckRepar()	</waypoint>
	<!-- #  7 --><waypoint x="561" z="-798" y="141">CheckRepar()	</waypoint>
	<!-- #  8 --><waypoint x="-125" z="-795" y="137">CheckRepar()	</waypoint>
	<!-- #  9 --><waypoint x="-527" z="-518" y="153">CheckRepar()	</waypoint>
</waypoints>

Re: Level Up Skills on Level up.

Posted: Wed Jul 20, 2011 10:21 pm
by Bojer
Thanks a ton!!!

Re: Level Up Skills on Level up.

Posted: Wed Jul 20, 2011 11:14 pm
by rock5
I just fixed the levelup functions. Update to the latest revision 618.

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 12:13 am
by Bojer
HA!!! And here I think I figured out how to do it the other way though i was trying to figure out how to do all the classes without editing the file each time I swapped over.

So ....

<onLevelup><![CDATA[
levelupSkill(_PRIEST_RISING_TIDE, _1)
levelupSkill(_PRIEST_REGENERATE, _1)
levelupSkill(_PRIEST_GRACE_OF_LIFE, _1)
levelupSkill(_PRIEST_WAVE_ARMOR, _1)
levelupSkill(_PRIEST_HEAL, _1)
levelupSkill(_MAGE_FIREBALL, _1)
levelupSkill(_MAGE_FLAME, _1)
levelupSkill(_MAGE_ESSENCE_OF_MAGIC, _1)
]]></onLevelup>

Should level each skill up 1 level if they are active correct?

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 12:50 am
by lisa
Well it wouldn't have worked unless all the skillnum and tabs were added back into the skills database. As that function uses the in game function SetSpellPoint, like they said.

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 12:55 am
by Bojer
Ok one more question about auto level skills. I cant seem to find the Mage skill Wisdom in the Skills.xml area. Is there a way for me to find that info inside the game to put it in the Skills.xml so I can auto level it too?

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 2:12 am
by rock5
lisa wrote:Well it wouldn't have worked unless all the skillnum and tabs were added back into the skills database. As that function uses the in game function SetSpellPoint, like they said.
Didn't I just say I fixed it? skillnum and skilltab are added in the settings.updateSkillsAvailability() function. So now they can be counted on to be accurate and they are available for all skills.
Bojer wrote:Ok one more question about auto level skills. I cant seem to find the Mage skill Wisdom in the Skills.xml area. Is there a way for me to find that info inside the game to put it in the Skills.xml so I can auto level it too?
Unfortunately, passive skills aren't added to the skills database. Situations like this make a good case to add them but, really, the database is intented for skills that are "used". Seems overkill to maintain details of passive skills that are not used. Maybe an easier way would be just to make it so the "levelupSkill" function can level skills regardless of whether they are in the database or not.

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 3:31 am
by lisa
rock5 wrote:Maybe an easier way would be just to make it so the "levelupSkill" function can level skills regardless of whether they are in the database or not.
Yeah I don't think it should be limited to only lvl skills that are in a profile.
If people want to level other skills, such as passives, then they should be able to.
Actually I don't think anything should be limited to only use the skills in the profile. The way I understand it used to work is it would only check if we have the info for skills that were profile. Since we can now get info for any skill from memory then there is no need to check the skills are in profile anymore.

Like if people want to use Holyaura from <onskillcast> on their mage side but forgot to add it to their mageskills in profile. I don't see why they can't.

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 3:38 am
by rock5
This is all good but I think it will have to wait until I do the "big" skill update I've been talking about. In the mean time passives can still be upgraded using "SetSpellPoint".

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 11:43 am
by Bojer
Hmmm...so....

<onLevelup><![CDATA[
levelupSkill(_PRIEST_RISING_TIDE, _1)
levelupSkill(_PRIEST_REGENERATE, _1)
levelupSkill(_PRIEST_GRACE_OF_LIFE, _1)
levelupSkill(_PRIEST_WAVE_ARMOR, _1)
levelupSkill(_PRIEST_HEAL, _1)
levelupSkill(_MAGE_FIREBALL, _1)
levelupSkill(_MAGE_FLAME, _1)
levelupSkill(_MAGE_ESSENCE_OF_MAGIC, _1)
]]></onLevelup>

Still gives me errors. What am I doing wrong here?

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 7:04 pm
by lisa

Code: Select all

levelupSkill("MAGE_ESSENCE_OF_MAGIC", 1)

Re: Level Up Skills on Level up.

Posted: Thu Jul 21, 2011 7:06 pm
by Bojer
DOH!!! Of course it would be something so simple and right in front of my eyes!!!! Thanks again.

Re: Level Up Skills on Level up.

Posted: Sat Feb 04, 2012 8:11 pm
by lisa
resurecting an old topic, kind of.

There was a question if you can just lvl up skill # times without having to do it 1 at a time.

Well lately I have been doing some reading of the game .lua code and guess what, the game itself levels them up 1 at a time even when you do it manually in game and set it to lvl 40 times.

Code: Select all

	local count = SkillLevelUpFrame.number - SkillLevelUpFrame.mini + 1;

	for i = 1, count do

		SetSpellPoint( SkillLevelUpFrame.type, SkillLevelUpFrame.index ); 
	end
that is the actual code performed in game when you level up skills.