Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local teleportto = {x=1003,y=1000,z=7}
- local basin = {x=1001,y=999,z=7}
- local storage = 8987
- function countDown(number, pos, effect, msgonend, effectonend)
- local n = number
- for i = 1, number do
- addEvent(doSendAnimatedText,i* 1000, pos, n > 1 and n.."" or msgonend .."", n < 6 and TEXTCOLOR_WHITE or TEXTCOLOR_RED)
- addEvent(doSendMagicEffect,i* 1000, pos, n > 1 and 13 or 12 )
- n = n -1
- end
- n = number
- return true
- end
- function onUse(cid, item, fromPosition, itemEx, toPosition)
- if exhaustion.get(cid, storage) then
- return doPlayerSendCancel(cid,"You can't do this.")
- end
- if doPlayerRemoveItem(cid, 2160, 1) then
- local basinold = getTileItemById(basin, 1485)
- local freezetime = 5
- doTransformItem(item.uid, 1484)
- doCreatureSetNoMove(cid, 1)
- exhaustion.set(cid, storage, 900)
- addEvent(doTeleportThing, 5*1000, cid, teleportto)
- addEvent(doCreatureSetNoMove, 5*1000, cid, 0)
- addEvent(doCreatureSay, 4*1000, cid, "THE BOSS WANT TO MEET YOU RIGHT NOW!", TALKTYPE_ORANGE_1)
- addEvent(doTransformItem, 5*1000, item.uid, 1485)
- countDown(freezetime , toPosition, 0, "melted", 5)
- else
- doPlayerSendCancel(cid,"You need to step in the right position.")
- end
- return true
- end
Add Comment
Please, Sign In to add comment