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

MoveEvent SOme crazy 395 line movement script!

Status
Not open for further replies.

kinglewey

New Member
Joined
Feb 18, 2008
Messages
128
Reaction score
0
Well heres some crazy movment script i made!
http://youtube.com/watch?v=iGDhJuE5mhI


ONLY TESTED ON TFS



This is how u add it!


1st off make put this in and save it as data/movments/scripts/pyramid teleport.lua


Code:
--Room teleport function by Kinglewey--

function onStepIn(cid, item, frompos, item2, topos)

playerpos = getPlayerPosition(cid) 
novapos = {x=1022, y=1022, z=7} 
storagething = 7000 --storage value
phrases = {"How dare you enter my pyramid", "You are very stupid coming here", "Not a good idea", "Leave Now!", "Just leave me alone"} --phrases That Are randmly Used!
colour = {18,19,22}
damage = {20,25}

if item.uid == 7001 then

doPlayerSendTextMessage(cid,colour[math.random(1, #colour)], phrases[math.random(1, #phrases)])
 getThingfromPos(playerpos) 
doSendMagicEffect(playerpos,2) 
setPlayerStorageValue(cid,storagething,damage[math.random(1, #damage)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(novapos,10) 

end


end

Now make another file in data/movments/scripts and save it as stuck.lua

Code:
-- the Stuck script Created 100%  by KINGLEWEY!!!!... 
-- Tazserver.no-ip.org.... 
--visit www.tazserver.mapletemple.nl
--thx 2 sam for for nothing. Used In Poor Noob 4 and poor noob 4.11-
--recent edits!   , made script more user friendly by making a config!, made random msge at end, made random wrds each time, made walls Also Made a config!
--Don't Forget to Rep me (Kinglewey) 
function onStepIn(cid, item, pos)

--Config--
playerpos = getPlayerPosition(cid) --No Need to edit!
	player1pos = getPlayerPosition(cid) --made a mistake and this fixes it (no need to edit)
	player1 = getThingfromPos(player1pos) --made a mistake and this fixes it (no need to edit)
novapos = {x=1022, y=1022, z=7} --position player gets teleported to
storagething = 7000 --storage value change if you need to. But you shouldn't have to edit!  (only change if you have already 
phrases = {"Damn", "Help!", "Frick", "Huff!", "Errm...", "O dear", "Deary me", "Im a nab", "Spazm"} --phrases That Are randmly Used!
colour = {TEXTCOLOR_RED, TEXTCOLOR_BLUE, TEXTCOLOR_YELLOW, TEXTCOLOR_ORANGE, TEXTCOLOR_LIGHTGREEN, TEXTCOLOR_TEAL, TEXTCOLOR_LIGHTGREY, TEXTCOLOR_LIGHTBLUE, TEXTCOLOR_WHITE_EXP, TEXTCOLOR_DARKRED} --colours of txt used randomly. These are all colours of The forgotten server!
magicffects = {1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54} --magic effects/ I didnt use draggy cos i didnt like him! (draggy is magic effect 33) these are all the 8.10 effects!
wall1 = {x=1022, y=1021, z=7, stackpos=1}--Position Of Wall 1!
wall2 = {x=1023, y=1022, z=7, stackpos=1}--Position Of Wall 2!
wall3 = {x=1023, y=1023, z=7, stackpos=1}--Position Of Wall 3!
wall4 = {x=1022, y=1023, z=7, stackpos=1}--Position Of Wall 4!
wall5 = {x=1021, y=1023, z=7, stackpos=1}--Position Of Wall 5!
wall6 = {x=1021, y=1022, z=7, stackpos=1}--Position Of Wall 6!
wall7 = {x=1021, y=1021, z=7, stackpos=1}--Position Of Wall 7!
wall8 = {x=1023, y=1021, z=7, stackpos=1}--Position Of Wall 8!
transformation = {2728, 2729, 3007, 3062, 6497, 6512, 6528, 7902, 8261, 2644, 5016} --what u get turned into. Item ids only!
delay = 55*10*10 -- Time That walls are holding you in one square. (i do this to stop people from just walking over the effect square very fast and causing debug! (or for some reason cloning yourself :S)
msge = {"You just got owned by a pyramid", "You are dead!                              Only Joking", "Disorientated?", "Bizzar said dougal realising he was a dog!", "And Stay Out", "Hunted by druid Roddy -- lv 24 druid -- Julera. in real tibia!", "Stuck Script created 100% By Kinglewey!"} --random messages that are said at the end of the script!
message_effect = {18,19,22} --colour of the words that are said when the walls appear around you!
trans_time = 200000 --time you stay looking like an object!
damage = math.random(10,40)	--Change Damage Here.
txt_msge = {"Mwahahahahahahahahaha", "O dear are you stuck?", "Sucks Doesnt it!", "This is what happeneds when you enter my pyramid", "Hmm does something smell?.. o wait thats me", "bored?", "Are You Hungry?"} -- words that ar said when the walls appear around you!
----------------------------------------------------------------------------------------------------
--End Of Config! by kinglewey. DONT EDIT THE REST Unless you are editing the storage values or What walls look like. (sorry I didnt put this into the config. I just couldn't be bothered)
getwall1 = getThingfromPos(wall1)
	getwall2 = getThingfromPos(wall2)
		getwall3 = getThingfromPos(wall3)
			getwall4 = getThingfromPos(wall4)
				getwall5 = getThingfromPos(wall5)
					getwall6 = getThingfromPos(wall6)
						getwall7 = getThingfromPos(wall7)
							getwall8 = getThingfromPos(wall7)


if item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 25 then

getThingfromPos(playerpos) 
doPlayerSendTextMessage(cid, 18, 'I told you not to come back. Now I shall hurt you!')
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doCreatureAddHealth(player1.uid, -damage)
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 24)




elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 24 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doCreatureAddHealth(player1.uid, -damage)
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 23)


elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 23 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doCreatureAddHealth(player1.uid, -damage)
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 22)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 22 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doCreatureAddHealth(player1.uid, -damage)
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 21)


elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 21 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doCreatureAddHealth(player1.uid, -damage)
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 20)
							
							
							
							
elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 20 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 19)


elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 19 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 18)


elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 18 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 17)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 17 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 16)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 16 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 15)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 15 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
addEvent(onTime,delay,a) 
doCreateItem(1536,1,wall1)
doCreateItem(1534,1,wall2)
doCreateItem(1535,1,wall3)
doCreateItem(1536,1,wall4)
doCreateItem(1534,1,wall5)
doCreateItem(1534,1,wall6)
doCreateItem(1533,1,wall7)
doCreateItem(1536,1,wall8)
doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
setPlayerStorageValue(cid,storagething, 14)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 14 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 13)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 13 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 12)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 12 then

getThingfromPos(playerpos) 
doTeleportThing(cid,novapos) 
addEvent(onTime,delay,b) 
doCreateItem(1112,1,wall1)
doCreateItem(1111,1,wall2)
doCreateItem(1115,1,wall3)
doCreateItem(1112,1,wall4)
doCreateItem(1111,1,wall5)
doCreateItem(1111,1,wall6)
doCreateItem(1113,1,wall7)
doCreateItem(1112,1,wall8)
doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 11)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 11 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 10)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 10 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 9)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 9 then

getThingfromPos(playerpos)
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
addEvent(onTime,delay,c) 
doCreateItem(1063,1,wall1)
doCreateItem(1065,1,wall2)
doCreateItem(1064,1,wall3)
doCreateItem(1063,1,wall4)
doCreateItem(1065,1,wall5)
doCreateItem(1065,1,wall6)
doCreateItem(1062,1,wall7)
doCreateItem(1063,1,wall8)
doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
setPlayerStorageValue(cid,storagething, 8)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 8 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 7)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 7 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 6)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 6 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 5)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 5 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 4)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 4 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 3)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 3 then

getThingfromPos(playerpos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doTeleportThing(cid,novapos) 
doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doSendAnimatedText(getPlayerPosition(cid), '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
setPlayerStorageValue(cid,storagething, 2)

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 2 then

doSendMagicEffect(getPlayerPosition(cid), magicffects[math.random(1, #magicffects)])
doPlayerSendTextMessage(cid, 18, 'Ok you can leave!')
doSetItemOutfit(cid, transformation[math.random(1, #transformation)], trans_time)
setPlayerStorageValue(cid,storagething,1)
doPlayerPopupFYI(cid, '' .. msge[math.random(1, #msge)])

elseif item.actionid == 7000 and getPlayerStorageValue(cid,storagething) == 1 then
doPlayerSendTextMessage(cid, 23, 'Back again?')




end
end


function onTime(a)
--config for timer
wall1 = {x=1022, y=1021, z=7, stackpos=1}
wall2 = {x=1023, y=1022, z=7, stackpos=1}
wall3 = {x=1023, y=1023, z=7, stackpos=1}
wall4 = {x=1022, y=1023, z=7, stackpos=1}
wall5 = {x=1021, y=1023, z=7, stackpos=1}
wall6 = {x=1021, y=1022, z=7, stackpos=1}
wall7 = {x=1021, y=1021, z=7, stackpos=1}
wall8 = {x=1023, y=1021, z=7, stackpos=1}
--End Of Config! by kinglewey
getwall1 = getThingfromPos(wall1)
	getwall2 = getThingfromPos(wall2)
		getwall3 = getThingfromPos(wall3)
			getwall4 = getThingfromPos(wall4)
				getwall5 = getThingfromPos(wall5)
					getwall6 = getThingfromPos(wall6)
						getwall7 = getThingfromPos(wall7)
							getwall8 = getThingfromPos(wall8)
doRemoveItem(getwall1.uid,1)
	doRemoveItem(getwall2.uid,1)
		doRemoveItem(getwall3.uid,1)
			doRemoveItem(getwall4.uid,1)
				doRemoveItem(getwall5.uid,1)
					doRemoveItem(getwall6.uid,1)
					doRemoveItem(getwall7.uid,1)
						doRemoveItem(getwall8.uid,1)
end 



function onTime(b)
--config for timer
wall1 = {x=1022, y=1021, z=7, stackpos=1}
wall2 = {x=1023, y=1022, z=7, stackpos=1}
wall3 = {x=1023, y=1023, z=7, stackpos=1}
wall4 = {x=1022, y=1023, z=7, stackpos=1}
wall5 = {x=1021, y=1023, z=7, stackpos=1}
wall6 = {x=1021, y=1022, z=7, stackpos=1}
wall7 = {x=1021, y=1021, z=7, stackpos=1}
wall8 = {x=1023, y=1021, z=7, stackpos=1}
--End Of Config! by kinglewey
getwall1 = getThingfromPos(wall1)
	getwall2 = getThingfromPos(wall2)
		getwall3 = getThingfromPos(wall3)
			getwall4 = getThingfromPos(wall4)
				getwall5 = getThingfromPos(wall5)
					getwall6 = getThingfromPos(wall6)
						getwall7 = getThingfromPos(wall7)
							getwall8 = getThingfromPos(wall8)
doRemoveItem(getwall1.uid,1)
	doRemoveItem(getwall2.uid,1)
		doRemoveItem(getwall3.uid,1)
			doRemoveItem(getwall4.uid,1)
				doRemoveItem(getwall5.uid,1)
					doRemoveItem(getwall6.uid,1)
					doRemoveItem(getwall7.uid,1)
						doRemoveItem(getwall8.uid,1)
end 


function onTime(c)
--config for timer
wall1 = {x=1022, y=1021, z=7, stackpos=1}
wall2 = {x=1023, y=1022, z=7, stackpos=1}
wall3 = {x=1023, y=1023, z=7, stackpos=1}
wall4 = {x=1022, y=1023, z=7, stackpos=1}
wall5 = {x=1021, y=1023, z=7, stackpos=1}
wall6 = {x=1021, y=1022, z=7, stackpos=1}
wall7 = {x=1021, y=1021, z=7, stackpos=1}
wall8 = {x=1023, y=1021, z=7, stackpos=1}
--End Of Config! by kinglewey
getwall1 = getThingfromPos(wall1)
	getwall2 = getThingfromPos(wall2)
		getwall3 = getThingfromPos(wall3)
			getwall4 = getThingfromPos(wall4)
				getwall5 = getThingfromPos(wall5)
					getwall6 = getThingfromPos(wall6)
						getwall7 = getThingfromPos(wall7)
							getwall8 = getThingfromPos(wall8)
doRemoveItem(getwall1.uid,1)
	doRemoveItem(getwall2.uid,1)
		doRemoveItem(getwall3.uid,1)
			doRemoveItem(getwall4.uid,1)
				doRemoveItem(getwall5.uid,1)
					doRemoveItem(getwall6.uid,1)
					doRemoveItem(getwall7.uid,1)
						doRemoveItem(getwall8.uid,1)
end 
--End Of Stuck script By Kinglewey!!!


Now just put in the coordinates u need to do. I made a config so its easy to use.


Now in movments.xml put in

Code:
 <movevent event="StepIn" uniqueid="7001" script="pyramid teleport.lua" />
<movevent event="StepIn" actionid="7000" script="Stuck 2.lua" />

Now all u have 2 do is open ur map editor and make the square which tp's u to the place you get stuck action id 7001



And then make the squares that dont let u pass actionid 7000


Then you are done...

Enjoy!
 
OMG real nice I always wanted this :)
 
Shorten
PHP:
-- the Stuck script Created 100%  by KINGLEWEY!!!!... 
-- Tazserver.no-ip.org.... 
--visit www.tazserver.mapletemple.nl
--thx 2 sam for for nothing. Used In Poor Noob 4 and poor noob 4.11-
--recent edits!   , made script more user friendly by making a config!, made random popupMessages at end, made random wrds each time, made walls Also Made a config!
--Don't Forget to Rep me (Kinglewey) 

--Config--
local wall = {
	{x=1022, y=1021, z=7},
	{x=1023, y=1022, z=7},
	{x=1023, y=1023, z=7},
	{x=1022, y=1023, z=7},
	{x=1021, y=1023, z=7},
	{x=1021, y=1022, z=7},
	{x=1021, y=1021, z=7},
	{x=1023, y=1021, z=7}
}

local newPos = {x=1022, y=1022, z=7} --position player gets teleported to
local storageValue = 7000 --storage value change if you need to. But you shouldn't have to edit!  (only change if you have already 
local phrases = {"Damn", "Help!", "Frick", "Huff!", "Errm...", "O dear", "Deary me", "Im a nab", "Spazm"} --phrases That Are randmly Used!
local textColor = {TEXTCOLOR_RED, TEXTCOLOR_BLUE, TEXTCOLOR_YELLOW, TEXTCOLOR_ORANGE, TEXTCOLOR_LIGHTGREEN, TEXTCOLOR_TEAL, TEXTCOLOR_LIGHTGREY, TEXTCOLOR_LIGHTBLUE, TEXTCOLOR_WHITE_EXP, TEXTCOLOR_DARKRED} -- color of txt used randomly. These are all color of The forgotten server!
local avoidEffects = {33} -- Magic effects that should not be shown (this is "draggy from water" effect)
local outfits = {2728, 2729, 3007, 3062, 6497, 6512, 6528, 7902, 8261, 2644, 5016} --what u get turned into. Item ids only!
local delay = 5.5 * 1000 -- Time That walls are holding you in one square. (i do this to stop people from just walking over the effect square very fast and causing debug! (or for some reason cloning yourself :S)
local popupMessages = { --random messages that are said at the end of the script!
	"You just got owned by a pyramid",
	"You are dead!|space:30|Only Joking",
	"Disorientated?",
	"Bizzar said dougal realising he was a dog!",
	"And Stay Out",
	"Hunted by druid Roddy -- lv 24 druid -- Julera. in real tibia!",
	"Stuck Script created 100% By Kinglewey!"
}

local messageColors = {18,19,22} --color of the words that are said when the walls appear around you!
local outfitDuration = 200 * 1000 --time you stay looking like an object!
local damage = { --Change Damage Here.
	from = 10,
	to = 40
}

local stuckMessages = {  -- words that ar said when the walls appear around you!
	"Mwahahahahahahahahaha",
	"O dear are you stuck?",
	"Sucks Doesnt it!",
	"This is what happeneds when you enter my pyramid",
	"Hmm does something smell?.. o wait thats me",
	"bored?",
	"Are You Hungry?"
}
--End Of Config! by kinglewey. DONT EDIT THE REST Unless you are editing the storage values or What walls look like. (sorry I didnt put this into the config. I just couldn't be bothered)

function onStepIn(cid, item, pos)
	
	local health = math.random(10,40)	
	local magicEffects = rand(1, 54, avoidEffects)
	local storage = getPlayerStorageValue(cid,storageValue)

	if item.actionid == 7000 then
		if storage == 1 then
			doPlayerSendTextMessage(cid, 23, 'Back again?')
		else
			if storage == 2 then
				local popupMessage = randValue(popupMessages):gsub("|space:(%d+)|", function(a)
					return string.rep(" ", tonumber(a))
				end)
				doPlayerPopupFYI(cid, popupMessage)
				doSetItemOutfit(cid, randValue(outfits), outfitDuration)
			elseif isInArray({9, 12, 15}, storage) == TRUE then
				local itemids = {
					[9] = {1063, 1065, 1064, 1063, 1065, 1065, 1062, 1063},
					[12] = {1112, 1111, 1115, 1112, 1111, 1111, 1113, 1112},
					[15] = {1536, 1534, 1535, 1536, 1534, 1534, 1533, 1535}
				}
				for k, itemid in ipairs(itemids[storage]) do
					doCreateItem(itemid, 1, wall[k])
				end
				addEvent(onTime, delay) 
				doPlayerSendTextMessage(cid, randValue(messageColors), randValue(stuckMessages))
			elseif storage >= 21 and storage <= 25 then
				if storage == 25 then
					doPlayerSendTextMessage(cid, 18, 'I told you not to come back. Now I shall hurt you!')
				end
				doCreatureAddHealth(cid, -health)
			end
			doTeleportThing(cid, newPos)
			doSendMagicEffect(getPlayerPosition(cid), randValue(magicEffects))
			setPlayerStorageValue(cid, storageValue, storage - 1)
			if storage ~= 9 and storage ~= 15 then
				doSendAnimatedText(getPlayerPosition(cid), randValue(phrases) .. '!', randValue(textColor))
			end
		end
	end
	return TRUE
end

function randValue(t)
	return t[math.random(1, #t)]
end

function rand(s, e, a)
	local n = math.random(s, e)
	while isInArray(a, n) == TRUE do
		n = math.random(s, e)
	end
	return n
end

function onTime()
	for _, pos in ipairs(wall) do
		pos.stackpos = 1
		doRemoveItem(getThingfromPos(pos).uid, 1)
	end
end 
--End Of Stuck script By Kinglewey!!!

I could give ya some ideas of more newbie films ^^
 
Last edited:
Plx close the PHP tag with a PHP tag instead of a code tag. ;)
 
lol colandus i guess its not 395 lines anymore xD
 
what about.

PHP:
local storagething = 7000
local phrases = {"Damn", "Help!", "Frick", "Huff!", "Errm...", "O dear", "Deary me", "Im a nab", "Spazm"}
local colour = {180, 5, 210, 198, 30, 65, 129, 35, 215, 144}
local damage = {min=10, max=40}
local notAllowedEffects = {8, 33}
local transformation = {2728, 2729, 3007, 3062, 6497, 6512, 6528, 7902, 8261, 2644, 5016}
local delay = 55*100
local msge = {
    "You just got owned by a pyramid", 
    "You are dead!                              Only Joking", 
    "Disorientated?", 
    "Bizzar said dougal realising he was a dog!", 
    "And Stay Out", 
    "Hunted by druid Roddy -- lv 24 druid -- Julera. in real tibia!", 
    "Stuck Script created 100% By Kinglewey!"}
local message_effect = {18,19,22}
local trans_time = 200 * 1000
local txt_msge = {
    "Mwahahahahahahahahaha", 
    "O dear are you stuck?", 
    "Sucks Doesnt it!", 
    "This is what happeneds when you enter my pyramid", 
    "Hmm does something smell?.. o wait thats me", 
    "bored?", 
    "Are You Hungry?"}
local novapos = {x=94, y=126, z=7} 
local colour1 = {18,19,22}
local phrases1 = {
    "How dare you enter my pyramid", 
    "You are very stupid coming here", 
    "Not a good idea", "Leave Now!", 
    "Just leave me alone"}
    
local function randomEffect(t)
    e = math.random(1, 54)
    if isInArray(t, e) == TRUE then    e = e + 1 end return e
end

function onStepIn(cid, item, pos)
local storage = getPlayerStorageValue(cid,storagething)
local dmg = math.random(damage.min, damage.max)
local pPos = getPlayerPosition(cid)
local Walls1 = {1536, 1534, 1535, 1536, 1534, 1534, 1533, 1536}
local Walls2 = {1112, 1111, 1115, 1112, 1111, 1111, 1113, 1112}
local Walls3 = {1063, 1065, 1064, 1063, 1065, 1065, 1062, 1063}
local wallPos = {
    {x=pPos.x, y=pPos.y-1}, {x=pPos.x+1, y=pPos.y}, {x=pPos.x+1, y=pPos.y+1}, {x=pPos.x, y=pPos.y+1}, 
    {x=pPos.x-1, y=pPos.y+1}, {x=pPos.x-1, y=pPos.y}, {x=pPos.x-1, y=pPos.y-1}, {x=pPos.x+1, y=pPos.y-1}}    
 
if item.actionid == 7000 then
    if storage == 25 then
        doPlayerSendTextMessage(cid, 18, 'I told you not to come back. Now I shall hurt you!')
        doTeleportThing(cid,novapos) 
        doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        doCreatureAddHealth(cid, -dmg)
        doSendAnimatedText(pPos, phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
        setPlayerStorageValue(cid,storagething, 24)
    elseif storage == 15 then
         doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        doTeleportThing(cid,novapos) 
        addEvent(onTime,delay, {wallPos=wallPos, Z=pPos.z}) 
        setPlayerStorageValue(cid,storagething, 14)
        for i = 1, 8 do
            wallPos[i].z = pPos.z
            doCreateItem(Walls1[i],1,wallPos[i])
        end
        doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
    elseif storage == 12 then
        doTeleportThing(cid,novapos) 
        addEvent(onTime,delay, {wallPos=wallPos, Z=pPos.z}) 
        for q = 1, 8 do
            wallPos[q].z = pPos.z
            doCreateItem(Walls2[q],1,wallPos[q])
        end
        doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
        doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        doSendAnimatedText(pPos, '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
        setPlayerStorageValue(cid,storagething, 11)
    elseif storage == 9 then 
        doTeleportThing(cid,novapos) 
        doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        addEvent(onTime,delay, {wallPos=wallPos, Z=pPos.z}) 
        for w = 1, 8 do
            wallPos[w].z = pPos.z
            doCreateItem(Walls3[w],1,wallPos[w])
        end
        doPlayerSendTextMessage(cid,message_effect[math.random(1, #message_effect)], txt_msge[math.random(1, #txt_msge)])
        setPlayerStorageValue(cid,storagething, 8)
    elseif storage > 2 and storage <= 24 then
        doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        doTeleportThing(cid,novapos) 
        if storage >= 21 and storage <= 24 then
            doCreatureAddHealth(cid, -dmg)
        end
        doSendMagicEffect(pPos, randomEffect(notAllowedEffects))
        doSendAnimatedText(pPos, '' .. phrases[math.random(1, #phrases)] .. '!', colour[math.random(1, #colour)])
        setPlayerStorageValue(cid, storagething, storage - 1)
    elseif storage == 2 then
        doSendMagicEffect(getPlayerPosition(cid), randomEffect(notAllowedEffects))
        doPlayerSendTextMessage(cid, 18, 'Ok you can leave!')
        doPlayerPopupFYI(cid, '' .. msge[math.random(1, #msge)])
        doSetItemOutfit(cid, transformation[math.random(1, #transformation)], trans_time)
        setPlayerStorageValue(cid,storagething,1)
    elseif storage == 1 then
        doPlayerSendTextMessage(cid, 23, 'Back again?')
    end
elseif item.uid == 7001 then
    local R = {20,25}
    doPlayerSendTextMessage(cid,colour1[math.random(1, #colour1)], phrases1[math.random(1, #phrases1)])
    doTeleportThing(cid,novapos) 
    doSendMagicEffect(pos,2) 
    doSendMagicEffect(novapos,10)
    setPlayerStorageValue(cid,storagething,R[math.random(1, #R)])
end
end
 
function onTime(a)
    for p = 1, #a.wallPos do
        a.wallPos[p].stackpos = 1
        a.wallPos.z = a.Z
        doRemoveItem(getThingfromPos(a.wallPos[p]).uid, 1)
    end
end
 
nice Nahruto XD I knew u would made it real short as u said :)
 
lol, its the same shit over and over again in the code :p

Not exactly same shit... And sometimes there is different functions used :p

Colandus r0x:D I didn't knew you could use
PHP:
text|space:30|text
:O
PHP:
local popupMessage = randValue(popupMessages):gsub("|space:(%d+)|", function(a)
    return string.rep(" ", tonumber(a))
end)

It's very simple huehhue xD
 
my version includes both script ^.-
and i dint knew the 30 spaces thing its ok ^.-

my way to create and remove the walls is better, because you dont need to change 8 pos to configure it.
 
Last edited:
:eek: well Its just a fun little script anyways.
Glad most of ya liked it!
 
Status
Not open for further replies.
Back
Top