
Originally Posted by
eldera
Would be nice if you can add those functions to XenoLuaLib:
- Self.ManaPercent()
- Self.HealthPercent()
- Self.LevelPercent()
- Self.ExperienceLeft()
- Self.SKILLPercent() where SKILL is Sword, Axe, Club, Mlvl itp...
And meaby Self.Vocation() - I know it's impossible to read them from client unless you "Look" on character ingame but it can be guessed by amount of health/mana at x level, also it's possible to track it by gear specified for each vocation like glaciar rod for ed, underworld robe for ms etc...
+ something that is currently impossible to do with xenobot - inviting players to party and accepting it. It's hard to make teamscripts without it.
lua code:
function getExperienceForLevel(level)
local level = level or Self.Level()
return ((50.0 / 3.0) * math.pow(level, 3)) - (100.0 * math.pow(level, 2)) + ((850.0 / 3.0) * level) - 200
end
function getExperienceLeft(level)
local level = level or Self.Level() + 1
return getExperienceForLevel(level) - Self.Experience()
end