• 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 Change The Level Points To Frag Point Script

Bloody-War

New Member
Joined
Feb 9, 2016
Messages
88
Reaction score
1
Hello.

- I waana convert this script to frag point script.. For tfs 0.3.6.

-Please Help Us To convery this script to frag point script
Code:
local t, storage = {
-- level -- amount points (delete this line)..
{250, 5},
{300, 10},
{400, 10},
{500, 15},
{600, 25}
}, 259
function onAdvance(cid, skill, oldLevel, newLevel)
if skill ~= SKILL__LEVEL then
return true
end
for i = 1, #t do
local v = t[i]
if newLevel >= v[1] and getCreatureStorage(cid, storage) < i then
db.executeQuery('UPDATE accounts SET premium_points=premium_points+'.. v[2] ..' WHERE id=' .. getPlayerAccountId(cid))
doCreatureSetStorage(cid, storage, i)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, 'Congratulations! You have advanced to level ' .. v[1] .. ' and you have earned '.. v[2] ..' Premium Points!')
end
end
return true
end
 
Last edited by a moderator:
Back
Top