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

Solved Scripts Water

darksta

New Member
Joined
Feb 10, 2010
Messages
39
Reaction score
0
something is wrong with the script, Fix it

Code:
    <movevent event="StepIn" itemid="4820" script="nadar.lua" /> --nadar
    <movevent event="StepOut" itemid="4820" script="nadar.lua" /> --nadar

Code:
function onStepIn(cid, item, pos)
    if isPlayer(cid) ~= TRUE then
        return 1
    end
al = getPlayerAccess(cid)
if al < 1 then

diveroutfit = { lookType = 267, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookAddons = 0 }

doSetCreatureOutfit(cid, diveroutfit, -1)

end
    return 1
end

function onStepOut(cid, item, pos)
    if isPlayer(cid) ~= TRUE then
        return 1
    end
if item.itemid == 4820 then
al = getPlayerAccess(cid)
if al < 1 then
doRemoveCondition(cid, CONDITION_OUTFIT)
end
end
return 1
end


This one, does not work and I put the action ID to Sqm and nothing

Code:
<movevent event="StepIn" itemid="1284" script="saltoagua.lua" />
Code:
function onStepIn(cid, item, pos)
    if isPlayer(cid) ~= TRUE then
        return 1
    end
npos = {x=724, y=759, z=8}
newpos = {x=709, y=788, z=7}

              if item.actionid == 50100 then
        itemhelmet = getPlayerSlotItem(cid, 1)
        if itemhelmet.itemid == 5461 then --helmet of the deep

                doTeleportThing(cid,npos)
                doPlayerSay(cid,"Glup! Glup! Glup!",16)
                doSendMagicEffect(npos,1)
                doSendMagicEffect(newpos,1)
            return 1
        end
        doPlayerSendCancel(cid, "Sorry you need a helmet of the deep to go under water.")
                --doMoveCreature(cid, 0)
    else
        return 0
    end
    return 1
end

helpme :c
 
Last edited:
Stop starting threads without providing any information, also the scripts are not tabbed and horrible to read.
My post was to answer the only question you had in your post, because "does not work" never was and also never will be a valid description.
 
Stop starting threads without providing any information, also the scripts are not tabbed and horrible to read.
My post was to answer the only question you had in your post, because "does not work" never was and also never will be a valid description.

mmm .. okay, sorry to ask for help: s
 
People are unable to help you without any information.
1. Which server do you use
2. How did you added it in the map
3. What is it supposed to do
4. What happens exactly (like console errors, ingame textmessages or anything else)
5. What should be different

And this
Also the scripts are not tabbed and horrible to read.
 
People are unable to help you without any information.
1. Which server do you use
2. How did you added it in the map
3. What is it supposed to do
4. What happens exactly (like console errors, ingame textmessages or anything else)
5. What should be different

And this

-Use tfs 8.60
-The two scripts that are above are movements
Code:
-<movevent event="StepOut" itemid="4820" script="nadar.lua" /> - nadar
" This script allows you, use the function "swim" only in one type of flooring that your id is 4820, and marks the scripts, the paracerse above the floor (id: 4820), will automatically pass to swim on, oviamente changing your looktype"


Code:
-
<movevent event="StepIn" itemid="1284" script="saltoagua.lua" />
"
-This script is basically their function when you stand in a "floor" that I put the ActionID, if you're wearing the diver cazco will transport you back to your position "npos = {x = 724, y = 759, z = 8}" to position "NewPos = {x = 709, y = 788, z = 7}"
Asher would come down to the water.
long as you use the diving helmet (id: 5461)
but wearing a helmet diver, simply by pressing the "flat" with the action Id, this will not send to any place

If I forgot to mention something tell me
 
8.60 is a client version, not a server version.
If you start your server, you can see the server version at the top.

You forgot to mention 2, 4 and 5 aswell.
 
-
8.60 is a client version, not a server version.
If you start your server, you can see the server version at the top.

You forgot to mention 2, 4 and 5 aswell.

-The Forgotten Server, version 0.4.0 (Crying Damson)
-The console does not boot any errors,
in the game does not come out any error message
-The first script, only the part where nothing has put the Id mentioned the scripts (id: 4820)
the second script, was added to the floor the action id marking the scripts
using the rme
-the two scripts are different, do not work together or anything there are separate
 
<movevent type="StepIn" itemid="4820" event="script" value="nadar.lua"/>
<movevent type="StepOut" itemid="4820" event="script" value="nadar.lua"/>

It worked perfectly! : D
thanks
Can you help me with the other scripts?
First script solved.
About the second script, already tried it the same way in movements.xml?
Code:
<movevent type="StepIn" itemid="1284" event="script" value="saltoagua.lua"/>
And if it doesn't work, add the information again, so 2, 4 and 5.
 
First script solved.
About the second script, already tried it the same way in movements.xml?
Code:
<movevent type="StepIn" itemid="1284" event="script" value="saltoagua.lua"/>
And if it doesn't work, add the information again, so 2, 4 and 5.
already tried it and gave me bug D:
 
Back
Top