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

[Movements]Beginner Quest

Kudzu

Active Member
Joined
Apr 9, 2008
Messages
512
Reaction score
38
Location
localhost
Have somebody some scripts from beginner quest? Like in pic.I need this and I can't find.
Rookgaard_beginners.jpg
 
data/movements/scripts/tutorial.lua

Code:
function onStepIn(cid, item, fromPosition, toPosition)
    if item.uid == 6000 then
        if getPlayerLevel(cid) < 10 then
            doPlayerSendTutorial(cid, 1)
        end
        return true
    end
end
 
Last edited:
Here you have version which can be used for all tutorials, with saving like in global tibia.

data/movements/scripts/tutorials.lua
Code:
local config = {
	storage = 5000, -- for saving done tutorials in storage
}

function onStepIn(cid, item, fromPosition, toPosition)
	if getPlayerStorageValue(cid, item.actionid) == -1 then
		doPlayerSendTutorial(cid, item.actionid - config.storage)
		setPlayerStorageValue(cid, item.actionid, 1)
	end
end

movements.xml
Code:
<movevent type="StepIn" fromaid="5000" toaid="5050" event="script" value="tutorials.lua"/>

Now just set a tile actionid = 5000 + tutorial_id. fe. 5001 for tutorial with id = 1, and 5025 for tutorial with id 25, etc!
 
Lua:
local config = {
	storage = 5000 -- for saving done tutorials in storage
}

function onStepIn(cid, item, fromPosition, toPosition)
	if getPlayerStorageValue(cid, item.actionid) == -1 then
		doPlayerSendTutorial(cid, item.actionid - config.storage)
		setPlayerStorageValue(cid, item.actionid, 1)
	end
end

lolfixd
 
# effects
Code:
CONST_ME_TUTORIALARROW = 55
CONST_ME_TUTORIALSQUARE = 56
# tutorial
just try all tutorial ids until you find the right one
 
Back
Top