sabodden
Member
- Joined
- Sep 27, 2019
- Messages
- 138
- Reaction score
- 18
It is annoying...
If someone gets hits on shovel role the blood blocks to open the hole...
If someone drops trashes on the hole, nobody can open...
It isn't possible to do like rope?
If someone gets hits on shovel role the blood blocks to open the hole...
If someone drops trashes on the hole, nobody can open...
It isn't possible to do like rope?
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
if itemEx.actionid == 45001 then
local storage = 51006
queststatus = getPlayerStorageValue(cid, storage)
if queststatus == -1 then
doPlayerSendTextMessage(cid, 22, "You have found an ancient amulet. Strange engravings cover it. Maybe Morris can make them out.")
-- give item????
setPlayerStorageValue(cid, storage, 1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
return true
end
if(isInArray(HOLES, itemEx.itemid)) then
if(itemEx.itemid ~= 8579) then
itemEx.itemid = itemEx.itemid + 1
else
itemEx.itemid = 8585
end
doTransformItem(itemEx.uid, itemEx.itemid)
doDecayItem(itemEx.uid)
return true
elseif(SAND_HOLES[itemEx.itemid] ~= nil) then
doSendMagicEffect(toPosition, CONST_ME_POFF)
doTransformItem(itemEx.uid, SAND_HOLES[itemEx.itemid])
doDecayItem(itemEx.uid)
return true
elseif(itemEx.itemid == SAND and not isRookie(cid)) then
local rand = math.random(1, 100)
if(rand >= 1 and rand <= 5) then
doCreateItem(ITEM_SCARAB_COIN, 1, toPosition)
elseif(rand > 85) then
doCreateMonster("Scarab", toPosition, false)
end
doSendMagicEffect(toPosition, CONST_ME_POFF)
return true
end
return false
end