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

really easy action

Snow

New Member
Joined
Jan 16, 2008
Messages
381
Reaction score
0
really easy action (fast please)

You click on an item with unique x and then you'll get an orange msg and a storage. and you'll get teleported..to a place.

If you already have the storage you'll go to the same place and you'll get a different msg.
 
Last edited:
actins/script/item.lua
LUA:
function onUse(cid, item, frompos, item2, topos)
local area = {x=1000, y=1000, z=7}
	if item.itemid == 5785 then
		if getPlayerStorageValue(cid, 11551) == -1 then
		return 0
	end
	doCreatureSay(cid, "Text!. ", TALKTYPE_ORANGE_1)
	setPlayerStorageValue(cid, 11551, 1)
	doTeleportThing(cid, area, TRUE)
	elseif getPlayerStorageValue(cid, 11551) == 1 then
	doTeleportThing(cid, area, TRUE)
	doCreatureSay(cid, "Text2!. ", TALKTYPE_ORANGE_1)
	end
	return true
end

actions.xml
Code:
	<action itemid="5785" script="VIP Item.lua"/>
rep if I helped :)
 
I forgot to mention the item is supposed to be the fire barrier at inquisition...and it's not working, please someone make it fast :(
 
in action.xml
Code:
<action uniqueid="[COLOR="Red"]17564[/COLOR]" event="script" value="other/fire barrier.lua"/>

then go make new lua and paste this
LUA:
function onUse(cid, item, frompos, item2, topos)
local area = {x=1000, y=1000, z=7}
 already = "Go Awaya noob"    --message appear when he  already have storage
 notyet = ""         --message if he didnt get storage yet
        if getPlayerStorageValue(cid, 11551) == -1 then
           doPlayerSendCancel(cid,"You Cant pass yet")
		   return true
        end
		if getPlayerStorageValue(cid, 11551) == 1 then
		doTeleportThing(cid, area, TRUE)
        doCreatureSay(cid, already , TALKTYPE_ORANGE_1)
		return true 
		end
        doCreatureSay(cid, notyet, TALKTYPE_ORANGE_1)
        setPlayerStorageValue(cid, 11551, 1)
        doTeleportThing(cid, area, TRUE)

        return true
end
 
Back
Top