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

[Request] Put returns in this script

Obsdark

Member
Joined
Sep 25, 2011
Messages
213
Reaction score
9
Can you put the returns in this 3 levers?, like they are 3, i don't know where i must write it



LUA:
function onUse(cid, item, frompos, itemEx, topos)
Castle1Tower3 = 0
Castle1Tower4 = 0
	if item.itemid == 1945 and item.uid == 3213 and Castle1Tower3 == 0 then
		Castle1Tower3 = 1
		doPlayerSendTextMessage(cid,21,"Con Exito y Funcionando, la Tercera torre ha sido activada!")
		doTransformItem(item.uid, item.itemid + 1)
	elseif item.itemid == 1946 and item.uid == 3213 and Castle1Tower3 == 1 then
		Castle1Tower3 = 0
		doPlayerSendTextMessage(cid,21,"La Vuelves a su Posición Original !")
		doTransformItem(item.uid, item.itemid - 1)
	else
		doPlayerSendCancel(cid,"Error 3!")
	end 
	if item.itemid == 1945 and item.uid == 3214 and Castle1Tower3 == 1 and Castle1Tower4 == 0 then
		Castle1Tower4 = 1
		doPlayerSendTextMessage(cid,21,"Con Exito y Funcionando, la Cuarta torre ha sido activada !")
		doTransformItem(item.uid, item.itemid + 1)
	elseif item.itemid == 1946 and item.uid == 3214 and Castle1Tower4 == 1 then
		Castle1Tower4 = 0
		doPlayerSendTextMessage(cid,21,"La Vuelves a su Posición Original !")
		doTransformItem(item.uid, item.itemid - 1)
	else
		doPlayerSendCancel(cid,"Error4 !")
	end
	if Castle1Tower3 == 1 and Castle1Tower4 == 1 then
		castletake1 = 1
		CastleMain1Tower1 = getPlayerStorageValue(cid, 3215)
	end
	if item.itemid == 1945 and item.uid == 3215 and castletake1 == 1 and CastleMain1tower1 ~= 1 then
		CastleMain1Tower1 = 1
		setPlayerStorageValue(cid, 3218, 1)
		doPlayerSendTextMessage(cid,21,"Felicitaciones, ahora ya te puedes convertir en rey !")
		doTransformItem(item.uid, item.itemid + 1)
	elseif item.itemid == 1946 and item.uid == 3215 and CastleMain1Tower1 == 1 then
		doPlayerSendTextMessage(cid,21,"Ya eres rey, no puedes volver a ser coronado sin antes perder la corona...")
		doTransformItem(item.uid, item.itemid - 1)
	elseif item.itemid == 1946 and item.uid == 3215 and castletake1 == 0 then
		doPlayerSendTextMessage(cid,21,"No puedes realizar esta acción, pues no estamos en tiempo de ASEDIO !")
		doTransformItem(item.uid, item.itemid - 1)
	else
		doPlayerSendCancel(cid,"Error, tú hermana!")
	end
end


is easy, the first lever is requeired to activate the second, and both (first and second) are necesary to activate the thirth


Can you help me, or guide me a little plz?
 
Last edited:
Back
Top