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

Steal eggs from nest.

breadmaker

New Member
Joined
Jul 16, 2010
Messages
160
Reaction score
3
Hello.
Anyone can make for me one simple script:
- If you click on egg nest (ID: 3455 [custom items]), you got 1 egg (id: 3456).
- After that if you trying to get another the msg appear:
"You already got egg from this nest. You must wait some time to get another one."
( Player must wait 4-5 minutes, to get next egg from nest. )

Of course i want put around 5 nest in map editor
, so i know this script is hard to do.

Rep++
 
LUA:
local s = 48912 -- storage for exhaustion.
local t = 60*5 -- how many seconds exhaustion.
function onUse(cid,item,frompos,itemEx,topos)
local v = getThingPos(cid)
	if exhaustion.get(cid,s) then
		doPlayerSendCancel(cid,'You have to wait '..exhaustion.get(cid,s)..' seconds to get another egg!.')
		doSendMagicEffect(v,CONST_ME_POFF)
	else
		doPlayerGiveItem(cid,3456,1)
		doPlayerSendTextMessage(cid,MESSAGE_LAST,'You found an egg!')
		doSendMagicEffect(v,CONST_ME_MAGIC_GEEN)
		exhaustion.set(cid,s,t)
	end
	return true
end
 
Back
Top