hello i need a script or somthing.. when a player kill a player wich is higher lvl thay should get like 1kk exp not much exp like 30% of a lvl depends on what lvl the one thay kill is.. you know like icechaw>D thankz for now i will give rep!>D
registerCreatureEvent(cid, "expKill")
<event type="kill" name="expKill" value="script.lua"/>
local EXP_AMOUNT = 5000
function onKill(cid, target, lastHit)
if isPlayer(cid) == TRUE then
if getPlayerLevel(target) > getPlayerLevel(cid) then
doPlayerAddExperience(cid, EXP_AMOUNT)
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have killed ".. getCreatureName(target) .." who was level ".. getPlayerLevel(target) .." and have been rewarded with ".. EXP_AMOUNT .." experience points.")
end
end
return TRUE
end
local EXP_AMOUNT = 5000
function onKill(cid, target, lastHit)
if isPlayer(killer) == TRUE then
if getPlayerLevel(target) > getPlayerLevel(cid) then
doPlayerAddExperience(cid, EXP_AMOUNT)
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have killed ".. getCreatureName(target) .." who was level ".. getPlayerLevel(target) .." and have been rewarded with ".. EXP_AMOUNT .." experience points.")
end
end
return TRUE
end
local EXP_AMOUNT = 5000
function onKill(cid, target, lastHit)
if isPlayer(cid) == TRUE and isPlayer(target) == TRUE then
if getPlayerLevel(target) > getPlayerLevel(cid) then
doPlayerAddExperience(cid, EXP_AMOUNT)
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have killed ".. getCreatureName(target) .." who was level ".. getPlayerLevel(target) .." and have been rewarded with ".. EXP_AMOUNT .." experience points.")
end
end
return TRUE
end