I found this in Sync theard.
Code:
function onKill(cid, target)
local config = {
item = 6500, -- Demonic Essence
store = getPlayerStorageValue(cid, 6000), -- storrage for Current frags
tstore = getPlayerStorageValue(cid, 7000), -- Total Storage value for kills
dstore = getPlayerStorageValue(cid, 8000), -- Total Storage value for deaths
rand = math.random(1,4),
pos = getPlayerPosition(cid)
}
local table = {
{"Smashed!", 189, 1},
{"Dead!", 190, 2},
{"Owned!", 18, 3},
{"Pwnt!", 215, 4}
}
if isPlayer(target) == true then
setPlayerStorageValue(cid, 6000, (config.store+1))
setPlayerStorageValue(cid, 7000, (config.tstore+1))
setPlayerStorageValue(target, 8000, (config.dstore+1))
doPlayerSetRedSkullTicks(cid, 0)
local rand = math.random(1, #table)
doSendAnimatedText(config.pos, table[rand][1], tablica[rand][2])
doPlayerAddItem(cid, config.item, table[rand][3])
if(getPlayerStorageValue(cid, 6000) == 5) then
broadcastMessage(getCreatureName(cid) .. " is on killing spree! He killed 5 players!")
elseif(getPlayerStorageValue(cid, 6000) == 10) then
broadcastMessage(getCreatureName(cid) .. " is dominating! He killed 10 players!")
elseif(getPlayerStorageValue(cid, 6000) == 25) then
broadcastMessage(getCreatureName(cid) .. " is CRAZY! He killed 25 players!")
elseif(getPlayerStorageValue(cid, 6000) == 50) then
broadcastMessage(getCreatureName(cid) .. " is UNSTOPPABLE!! He killed 50 players! DO SOMETHING!")
elseif(getPlayerStorageValue(cid, 6000) == 100) then
broadcastMessage("Bow down to your new god " ..getCreatureName(cid).. " has 100 frags!")
end
return TRUE
end
end