calum69
New Member
im currently using this script that works with "lasthit"
what i want it to do is give the reward to last say 10 people who deal damage to the target.
also currently when a player dies on my war serv they dont seem to loose blessings, can anyone help with removing them on death?
LUA:
function onKill(cid, target, lastHit)
local reward = {
item = 2152, --ITEM ID!
count = 1 -- How many?
}
if(isPlayer(cid) and isPlayer(target)) then
if getPlayerIp(cid) ~= getPlayerIp(target) then
doPlayerAddItem(cid, reward.item, reward.count)
else
doPlayerAddExperience(cid, -500000)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"You have been punished for killing a player of the same IP.")
end
end
return TRUE
end
what i want it to do is give the reward to last say 10 people who deal damage to the target.
also currently when a player dies on my war serv they dont seem to loose blessings, can anyone help with removing them on death?