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

Koshei Amulet quest + Blue legs 100% RL.

kito2

www.masteria.net
Joined
Mar 9, 2009
Messages
3,764
Solutions
1
Reaction score
227
Location
Chile, Santiago
Ok I made and found the first part, to obtain de broken piece of amulets with this scripts:

LUA:
function onUse(cid, item, frompos, item2, topos)
        if getPlayerStorageValue(cid, item.uid) == -1 then
                 doPlayerAddItem(cid,item.uid,1)
 doCreatureSay(cid, "You have found a piece of a broken amulet!", TALKTYPE_ORANGE_1)
 setPlayerStorageValue(cid, 3400, 1)
else
doCreatureSay(cid, "There is nothing here.", TALKTYPE_ORANGE_1)
end
    return true
end

And the part of the door and when using the koshei amulet over the death lich boss:

LUA:
  function onUse(cid, item, fromPosition, itemEx, toPosition)
        if itemEx.itemid == 3025 then
        if item.itemid == 8266 then
                getPlayerStorageValue(cid, 36205)
                doSendAnimatedText(getPlayerPosition(cid), "At least!", TEXTCOLOR_RED)
                setPlayerStorageValue(cid, 36205,1)
                doRemoveItem(cid, item.uid, 1)
            end
        end
end

And the door to pass:

LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
        if item.uid == 36205 then
                if {getPlayerStorageValue(cid, 36205) and getPlayerStorageValue(cid, 8262) and getPlayerStorageValue(cid, 8263) and getPlayerStorageValue(cid, 8264) and getPlayerStorageValue(cid, 8265) == -1 then
                        doPlayerSendTextMessage(cid, 22, "You may not pass!")
                else
                        doPlayerSendTextMessage(cid, 22, "You may pass.")
                        doTransformItem(item.uid, item.itemid + 1)
                        doTeleportThing(cid, toPosition, 1)
                end
                return 1
        end
        return 0
end

But I need this scripts:

The two statues have their torches lighted (pos x and pos y), and use the middle clock (aid z), you would hear a "CLICK" on n tile:

Light off itemid: 3697
Light on itemid: 3698

Koshei_Quest_Entrance.jpg


And it will transform this m tile to the itemid 7519, if you use the clock again, it will close, or if you turn off the light of the statues (both or one) it will close too.

dibujoqx.jpg
 
Last edited:
I made this, but I dont know what is wrong, it doesnt work:

LUA:
function onUse(cid, item, frompos, item2, topos)
statue1 = {x=33281, y=32442, z=8, stackpos=1}
statue2 = {x=33286, y=32444, z=8, stackpos=1}
stair = {x=33273, y=32458, z=8, stackpos=1}
voice = {x=33277, y=32451, z=8, stackpos=1}
getstatue1 = getThingfromPos(statue1)
getstatue2 = getThingfromPos(statue2)
getstair = getThingfromPos(stair)
getvoice = getThingfromPos(voice)


if getstatue1.itemid == 3698 and getstatue2.itemid == 3698 and getstair.itemid == 7520 then
			doTransformItem(getstair.uid,7525)
			doSendAnimatedText(getvoice, "CLICK!",TEXTCOLOR_ORANGE)
		elseif getstatue1.itemid == 3698 and getstatue2.itemid == 3698 and getstair.itemid == 7525 then
			doTransformItem(getstair.uid,7520)
		else
			doCreatureSay(cid, "Maybe there are missing torchs?", TALKTYPE_ORANGE_1)
		end
	return true
end

Help please?
 
Last edited:
Code:
local function reset()
	doTransformItem(getThingfromPos({x=33281, y=32442, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getThingfromPos({x=33286, y=32444, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getThingfromPos({x=33284, y=32450, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getThingfromPos({x=33278, y=32450, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getThingfromPos({x=33276, y=32444, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getThingfromPos({x=33276, y=32444, z=8, stackpos=1}).uid, 3698)
	doTransformItem(getTileItemById({x=33273, y=32458, z=8}, 7525).uid, 7520)
end
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getTileItemById({x=33281, y=32442, z=8}, 3698).uid > 0 and getTileItemById({x=33286, y=32444, z=8}, 3698).uid > 0 and getTileItemById({x=33284, y=32450, z=8}, 3697).uid > 0 and getTileItemById({x=33278, y=32450, z=8}, 3697).uid > 0 and getTileItemById({x=33276, y=32444, z=8}, 3697).uid > 0 and getTileItemById({x=33273, y=32458, z=8}, 7520).uid > 0 then
		doCreatureSay(cid, "CLICK", TALKTYPE_ORANGE_1, nil, nil, {x=33273, y=32459, z=8})
		doTransformItem(getTileItemById({x=33273, y=32458, z=8}, 7520).uid, 7525)
		addEvent(reset, 5 * 60 * 1000)
	else
		doCreatureSay(cid, "Nothing happens", TALKTYPE_ORANGE_1, false, nil, toPosition)
	end
	return true
end
It has to check all statues!
And it will transform this m tile to the itemid 7519, if you use the clock again, it will close, or if you turn off the light of the statues (both or one) it will close too.
That's not how it works in Cipbia, you can't use the sundial again -- you have to wait for statues to reset (5 minutes). Also, turning off any light will not change anything.
 
Last edited:
Cyko, check it, I modified it with a little help from Nahruto...

But this line:

doSendAnimatedText(getvoice, "CLICK!",TEXTCOLOR_ORANGE) replaced with this one doCreatureSay(cid, "CLICK", TALKTYPE_ORANGE_1, nil, nil, {x=33273, y=32459, z=8}) // yours // doesnt work :S
 
Then your OT is bugged :p
Does it send the message at all? If you can't see it, then change TALKTYPE_ORANGE_1 to TALKTYPE_ORANGE_2 (yell)

Okay guys I'm out of this thread.
 
Last edited:
Finally made it works:

LUA:
function onUse(cid, item, frompos, item2, topos)
statue1 = {x=33281, y=32442, z=8, stackpos=1}
statue2 = {x=33286, y=32444, z=8, stackpos=1}
stair = {x=33273, y=32458, z=8, stackpos=1}
voice = {x=33277, y=32451, z=8, stackpos=1}
getstatue1 = getThingfromPos(statue1)
getstatue2 = getThingfromPos(statue2)
getstair = getThingfromPos(stair)
getvoice = getThingfromPos(voice)


if getstatue1.itemid == 3698 and getstatue2.itemid == 3698 and getstair.itemid == 7520 then
			doTransformItem(getstair.uid,7525)
			doSendAnimatedText(voice, "CLICK!",TEXTCOLOR_ORANGE)
		elseif getstatue1.itemid == 3698 and getstatue2.itemid == 3698 and getstair.itemid == 7525 then
			doTransformItem(getstair.uid,7520)
			doSendAnimatedText(voice, "CRUMP!",TEXTCOLOR_ORANGE)
		else
			doCreatureSay(cid, "Maybe there are missing torchs?", TALKTYPE_ORANGE_1)
		end
	return true
end
 
data/action/script/quest/
create
blue_legs.lua
PHP:
function onUse(cid, item, frompos, item2, topos)


	if item.uid == 50013 then
		if getPlayerStorageValue(cid,50013) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a Blue Legs.")
			doPlayerAddItem(cid,7730,1)
			setPlayerStorageValue(cid,50013,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end

	elseif item.uid == 50014 then
		if getPlayerStorageValue(cid,50014) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a 50 Platinum Coins.")
			doPlayerAddItem(cid,2152,50)
			setPlayerStorageValue(cid,50014,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end

	elseif item.uid == 50019 then
		if getPlayerStorageValue(cid,50019) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a piece of broken amulet.")
			doPlayerAddItem(cid,8262,1)
			setPlayerStorageValue(cid,50019,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end

	elseif item.uid == 50020 then
		if getPlayerStorageValue(cid,50020) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a piece of broken amulet.")
			doPlayerAddItem(cid,8263,1)
			setPlayerStorageValue(cid,50020,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end	

	elseif item.uid == 50021 then
		if getPlayerStorageValue(cid,50021) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a piece of broken amulet.")
			doPlayerAddItem(cid,8264,1)
			setPlayerStorageValue(cid,50021,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end

	elseif item.uid == 50022 then
		if getPlayerStorageValue(cid,50022) == -1 then
			doPlayerSendTextMessage(cid,25,"You have found a piece of broken amulet.")
			doPlayerAddItem(cid,8265,1)
			setPlayerStorageValue(cid,50022,1)
		else
			doPlayerSendTextMessage(cid,25,"The is empty.")
		end

	end
	return TRUE
end

data/action/script
create
Kosheiamulet.lua
PHP:
  function onUse(cid, item, fromPosition, itemEx, toPosition)
local newPos = {x=33261, y=32446, z=12}
    if itemEx.itemid == 6028 then
        if getPlayerStorageValue(cid, 36203) == -1 then
            doTeleportThing(cid, newPos, TRUE)
           doCreatureSay(cid, 'At least I have it back, my precious amulet. I am glad you didn\'t use it! I allow you to ...ahh....enter door.... ahh')
            doRemoveItem(cid, item.uid, 1)
           setPlayerStorageValue(cid, 36203, 1)
        end
    end
end
now other archie lua
name:
door.lua

PHP:
  -- Blue Legs door

function onUse(cid, item, fromPosition, itemEx, toPosition)
        if item.uid == 5787 then
                if(isInArray({getPlayerStorageValue(cid, 5112), getPlayerStorageValue(cid, 5212), getPlayerStorageValue(cid, 36205), getPlayerStorageValue(cid, 5612), getPlayerStorageValue(cid, 5512), getPlayerStorageValue(cid, 36205)}, -1) == 1) then
                        doPlayerSendTextMessage(cid, 22, "Fuck Off Gay!")
                else
                        doPlayerSendTextMessage(cid, 22, "You may pass.")
                        doTransformItem(item.uid, item.itemid + 1)
                        doTeleportThing(cid, toPosition, 1)
                end
                return 1
        end
        return 0
end

Actions.xml
PHP:
<!-- Blue Legs Quest -->
       <action uniqueid="50013" event="script" value="quests/blue_legs.lua" /> 
       <action uniqueid="50014" event="script" value="quests/blue_legs.lua" /> 
	<action uniqueid="50019" event="script" value="quests/blue_legs.lua" /> 
       <action uniqueid="50020" event="script" value="quests/blue_legs.lua" /> 
       <action uniqueid="50021" event="script" value="quests/blue_legs.lua" /> 
       <action uniqueid="50022" event="script" value="quests/blue_legs.lua" />
       <action itemid="8266" script="kosheiamulet.lua"/>
       <action uniqueid="5787" script="door.lua" />
 
Back
Top