• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

TalkAction Max mana and hp

Andy Man

Advanced OT User
Joined
Jun 15, 2011
Messages
1,689
Reaction score
194
Location
México
This will show you, your max mana and hp


Lua:
function onSay(cid, words, param)
doPlayerSendTextMessage(cid,20,"Your Maximum Health is "..getCreatureMaxHealth(cid)..", And Your Maximum Mana is "..getCreatureMaxMana(cid)..".")
return 1
end
 
i get an error
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:eek:nSay
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:2: attempt to call global 'getCreatureMaxMana' (a nil value)
[01/11/2012 20:28:10] stack traceback:
[01/11/2012 20:28:10] [C]: in function 'getCreatureMaxMana'
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:2: in function <data/talkactions/scripts/hpmana.lua:1>
 
i get an error
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:eek:nSay
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:2: attempt to call global 'getCreatureMaxMana' (a nil value)
[01/11/2012 20:28:10] stack traceback:
[01/11/2012 20:28:10] [C]: in function 'getCreatureMaxMana'
[01/11/2012 20:28:10] data/talkactions/scripts/hpmana.lua:2: in function <data/talkactions/scripts/hpmana.lua:1>

You're using TFS 0.2, which means you must change "getCreatureMaxMana(cid)" to "getPlayerMaxMana(cid)".

Good choice on the server by the way. 0.2 is very stable and great to build on.

Edit @ down: Yeah, unfortunately 0.2 is a lot more difficult and tedious to work with.
 
Last edited:
I don't think that this is useful enough to make a thread for it ;p.
 
thanks but nothing works for .2 that's on this forum, its really hard to find help for scripts too lol

Request scripts or ask someone to convert script so it's compatible with 0.2? :p
 
Back
Top