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

[onDeath] HELP PLX. Remove and Create

Evangelion

New Member
Joined
May 8, 2008
Messages
13
Reaction score
0
Sorry my bad inglish ...

i need waht this script, make the next ..

1.- Remove Item, when you kill a monster.
2.- Create Item after a 1 min.
3..- ID to CREATE is 7825.

this Script Remove the item but dont create the item in 1 min. plys i need help..

IF YOU MAKE THE SCRIPT ( +1 R )

function onDeath(cid, corpse, killer)
local time = 60
gatepos = (x=580, y=1612, z=10, stackpos=1)
getgate = getThingfromPos(gatepos)
local creaturename == 'infernalist' and isPlayer(cid) == FALSE then
doRemoveItem(getgate.uid,1)
addEvent(createwall, (1000*time))
end
end

function createwall()
if getThingfromPos((x=580, y=1612, z=10, stackpos=2)).item == 8428 then ---- 8428 i dont know for waht is this ID
doCreateItem(getThingfromPos((x=580, y=1612, z=10, stackpos=2)).uid,1)
doSendMagicEffect((x=580, y=1612, z=10, stackpos=1), CONST_ME_POFF)
return TRUE
end
end
 
Last edited:
Something like this:

Lua:
function onDeath(cid, corpse, killer)
local time = 60
gatepos = (x=580, y=1612, z=10, stackpos=1)
getgate = getThingfromPos(gatepos)
	if getCreatureName(cid) == 'infernalist' and isPlayer(cid) == FALSE then
		doRemoveItem(getgate.uid,1)
		addEvent(createwall, (1000*time))
	end
	return TRUE
end

function createwall()
	if ((getThingfromPos((x=580, y=1612, z=10, stackpos=2)).itemid == 8428) == FALSE) then
		doCreateItem(8428, 1, (x=580, y=1612, z=10, stackpos=2))
		doSendMagicEffect((x=580, y=1612, z=10, stackpos=1), CONST_ME_POFF)
	end
	return TRUE
end
 
Change
Lua:
if ((getThingfromPos((x=580, y=1612, z=10, stackpos=2)).itemid == 8428) == FALSE) then
Lua:
doCreateItem(8428, 1, (x=580, y=1612, z=10, stackpos=2))
To
Lua:
doCreateItem(7825, 1, (x=580, y=1612, z=10, stackpos=2))
Lua:
if ((getThingfromPos((x=580, y=1612, z=10, stackpos=2)).itemid == 7825) == FALSE) then
 
Dont works ...

no create the item 7825 ..... why ??


function onDeath(cid, corpse, killer)
local time = 60 -- in seconds
gatepos = {x=580, y=1612, z=10, stackpos=1}
getgate = getThingfromPos(gatepos)
local creaturename = getCreatureName(cid)
if creaturename == 'Infernalist' and isPlayer(cid) == FALSE then
doRemoveItem(getgate.uid,1)
addEvent(createwall, (1000*time))
end
end

function createwall()
if getThingfromPos({x=580, y=1612, z=10, stackpos=2}).itemid == 7825 then
doCreateItem(7825, 1, ({x=580, y=1612, z=10, stackpos=2}))
doSendMagicEffect({x=580, y=1612, z=10, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end
 
Last edited:
Back
Top