• 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!

Lua Starting equipment chest - space in vocation name how to fix?

  • Thread starter Thread starter Xikini
  • Start date Start date
X

Xikini

Guest
I have a starting vocations chest from otland somewhere - I edited it and the only error popping up is near my 'battle mage' class. It is also the only class that has two words in it's name.

Is there something I should be putting instead of a space? as with promotions a pace is added and there is clearly needs to be a way to solve this problem.

here is the code near the battle mage.

lua cannot load script blah blah - 'then' expected near 'Mage'



Code:
		if isBattle Mage(cid) then
doPlayerSendTextMessage(cid,22,"Good Luck.")
doSendMagicEffect(topos,12)

and this is something from farther up that has no problems whatsoever,

Code:
		if isGuardian(cid) then
doPlayerSendTextMessage(cid,22,"Good Luck.")
doSendMagicEffect(topos,12)

how do I fix this? :P

thanks in advance everyone!
 
offcourse...

you may not let the blank space between the function "isBattle Mage"

put your function like this

PHP:
function isBattleMage(cid)
	return getPlayerVocationId(cid) == 4 and true or false
end

result:

PHP:
if isBattleMage(cid) then
	doPlayerSendTextMessage(cid, 22, "Good Luck.")
	doSendMagicEffect(topos, 12)
end

:)
 
Back
Top