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

Promotion Bug.. All TFS Versions

babalow

Nobody o/
Joined
Nov 7, 2007
Messages
393
Reaction score
1
Location
Brazil
when you get premium + promotion .. ok

but if you back your premium acc to free acc
u need to re-buy the promotion :confused:
 
I am using revision 420 and when u turn into free acc, u loose prom, but when u buy pacc again, u have ur promo back.
 
I am using revision 420 and when u turn into free acc, u loose prom, but when u buy pacc again, u have ur promo back.

i using rev 420 too .. but for me it don't work
if i go to free .. i loose promotion and need re-buy the promotion. u can show your promotion script plx? :rolleyes:
 
im using basic promotion script
 
I think its about the prem npc script.
 
You lose promotion when you lose premium, when you buy premium again, simply relog and your promotion is back!
 
You lose promotion when you lose premium, when you buy premium again, simply relog and your promotion is back!

oh.. it's true =/

srry for this thread then..

:thumbup:

changing the promotion npc for can't buy it two times :) .. done.
if you guys want..
in modules.lua u can modif the promot funcion
Code:
	function StdModule.promotePlayer(cid, message, keywords, parameters, node)
		local npcHandler = parameters.npcHandler
		if(npcHandler == nil) then
			error('StdModule.promotePlayer called without any npcHandler instance.')
		end
		if(cid ~= npcHandler.focus) then
			return false
		end
		local promotedVoc = getPromotedVocation(getPlayerVocation(cid))
		promotedStorage = getPlayerStorageValue(cid,19191)
		if(promotedVoc == getPlayerVocation(cid) or promotedVoc == 0) then
			selfSay('You are already promoted!')
		elseif promotedStorage == 1 then
			selfSay('You already bought promotion! Check your premium account days and relog.')
		elseif(getPlayerLevel(cid) < parameters.level) then
			selfSay('I am sorry, but I can only promote you once you have reached level ' .. parameters.level .. '.')
		elseif(doPlayerRemoveMoney(cid, parameters.cost) ~= TRUE) then
			selfSay('You do not have enough money!')
		else
			doPlayerSetVocation(cid, promotedVoc)
			setPlayerStorageValue(cid,19191,1)
			selfSay(parameters.text)
		end
		npcHandler:resetNpc()
		return true
	end
ps: this script isn't mine.. only added storage for player can't re-buy promotion. =]

ty Talaturen :wub:
 
Last edited:
FYI: Promotion storage is 30018, and you don't need to set it, the LUA function does it itself, only make sure it isn't already there (will be in rev 423).
 
@up
oh .. ok ..
u are fast o.o
i will wait you update then.. =]
ty again ;*
 
Back
Top