reaper16
Active User
- Dołączył
- Styczeń 15, 2009
- Posty
- 64
- Liczba reakcji
- 5
script na cc
if (newlevel >= 50 -lvl za kt?ry dostajemy cc
doPlayerAddItem(cid, 2160, 5) -ilo?? cc
script na pp
levelReach = 500, -- level, za kt?ry dostajemy pkt
points = 100 -- ilo?? otrzymanych pkt
Kod:
function onAdvance(cid, type, oldlevel, newlevel)
if (oldlevel ~= newlevel and type == SKILL__LEVEL) then
if (newlevel >= 50 and getPlayerStorageValue(cid, 44562) == -1) then
doPlayerAddItem(cid, 2160, 5)
doPlayerSendTextMessage(cid,21,'Congratulations! You have reached level 50! As a special bonus Materia administrators, you have received 5 Cristal Coins.')
setPlayerStorageValue(cid, 44562, 1)
end
end
return true
end
doPlayerAddItem(cid, 2160, 5) -ilo?? cc
script na pp
Kod:
local config = {
levelReach = 500,
points = 100
}
function onAdvance(cid, skill, oldLevel, newLevel)
if(skill == SKILL__LEVEL and newLevel >= config.levelReach and getPlayerStorageValue(cid, 58558) == -1) then
setPlayerStorageValue(cid, 58558, 1)
db.executeQuery("UPDATE `accounts` SET `premium_points` = `premium_points`+"..config.points.." WHERE `id` = "..getPlayerAccountId(cid)..";")
doPlayerSendTextMessage(cid,21,'Congratulations! You have reached level 500! As a special bonus Materia administrators, you have received 100 premium points.')
end
return TRUE
end
levelReach = 500, -- level, za kt?ry dostajemy pkt
points = 100 -- ilo?? otrzymanych pkt