• 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!

Kill people get 1 cc help

Velory

New Member
Joined
Jul 7, 2011
Messages
44
Reaction score
0
Hi I need a script to map rl when you kill someone you get 1 cc.


Waiting for help using REPP + +:)
 
function onkill(cid,target,corpse)
doaddplayeritem(cid, crystalcoinid, 1)
end

something like that in the creature script would do the trick :)
 
@up
that wont works -.-

Lua:
function onKill(cid,target,corpse)
if isPlayer(target) then
doPlayerAddItem(cid, 2160, 1)
end
return true
end
 
this works perfect
Lua:
function onKill(cid, target, lastHit)
	if cid ~= target and isPlayer(target) then
		if getPlayerIp(cid) == getPlayerIp(target) then
			doCreatureAddHealth(cid, -200)
			doCreatureAddMana(cid, -200)
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You have been punished for killing a player of the same IP.')
		else
			doPlayerAddItem(cid, 2160, 1)
		end
	end
	return true
end
 
this works perfect
Lua:
function onKill(cid, target, lastHit)
	if cid ~= target and isPlayer(target) then
		if getPlayerIp(cid) == getPlayerIp(target) then
			doCreatureAddHealth(cid, -200)
			doCreatureAddMana(cid, -200)
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You have been punished for killing a player of the same IP.')
		else
			doPlayerAddItem(cid, 2160, 1)
		end
	end
	return true
end

is possible add certain % of exp for the killer?
 
Yes.

Lua:
function onKill(cid, target, lastHit)
	if cid ~= target and isPlayer(target) then
		if getPlayerIp(cid) == getPlayerIp(target) then
			doCreatureAddHealth(cid, -200)
			doCreatureAddMana(cid, -200)
		else
		        doPlayerAddExp(cid, (getPlayerExperience(target)/95))
			doPlayerAddItem(cid, 2160, 1)
		end
	end
	return true
end
 
Back
Top