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

Action script

Erexo

Kage
Premium User
Joined
Mar 27, 2010
Messages
743
Solutions
5
Reaction score
200
Location
Pr0land
GitHub
Erexo
Hello,
i need a script...

When you click on id (use), then you are teleported to XXX,XXX,XX. add you a stroage walute (5555,3), and add 25cc.

Someone can help me with this script? ^^


Thanks,
Erexo.
 
Too easy, but if I make it, other people like JDB and Cykotitan would come in and shorten my script and make me look like shit.
Sorry
 
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	doTeleportThing(cid, {x=100, y=100, z=7})
	doCreatureSetStorage(cid, 5555, 3)
	doPlayerAddItem(cid, 2160, 25)
	return true
end
 
@up
hehe, thanks it work ^^


But now i have other problem...

here is script:

LUA:
function onUse(cid, item, frompos, item2, topos)
	if item.uid == 5550 and getPlayerStorageValue(cid,1111) == 2 then
		doTransformItem(item.uid,item.itemid+1)
		doTeleportThing(cid,frompos)
	else
		doPlayerSendTextMessage(cid,22,'You cant do this saga.')
	end
	return 1
end

Everything its works, but when i click on the doors, they change ID (transform to random item xD).

My english i so bad, sorry ^^
 
Code:
function onUse(cid, item, frompos, item2, topos)
	if item.itemid == [B][COLOR="red"]ITEMID_OF_CLOSED_DOOR[/COLOR][/B] then
		if getPlayerStorageValue(cid, 1111) == 2 then
			doTransformItem(item.uid, item.itemid+1)
			doTeleportThing(cid, frompos)
		else
			doPlayerSendTextMessage(cid, 22, 'You cant do this saga.')
		end
		return 1
	end
end
 
Back
Top