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

isWalkable(cid, pos)

sn3ejk

This account is inactive.
Joined
Nov 16, 2011
Messages
2,121
Solutions
1
Reaction score
145
Lua:
function isWalkable(cid, pos)
    local closest = getClosestFreeTile(cid, pos)
    return type(closest) == "table" and doComparePositions(closest, pos)
end
 
Last edited:
small as penis but useful as pussy ^^ just trolling

Nice <3

Please dont.. and btw, if ur penis is small that doesnt mean every penis is small. Just saying.. ^^

Ye, could someone explain what it does? ;p
 
Last edited:
It checks if a tile is walkable.
 
Checking whether a tile is walkable.
 
For example use this function before summon monster, if tile wont be walkable it wont print console errors.
 
can someone teach me how to install this on my server?

Go to data\lib\032-position.lua, then search for isWalkable function and replace it with:
Lua:
function isWalkable(cid, pos)
    local closest = getClosestFreeTile(cid, pos)
    return type(closest) == "table" and doComparePositions(closest, pos)
end

If you can't find the function in your 032-position.lua file, then just paste it wherever you want. :)
 
okay. and what if I want to make custom functions like this? my data folder doesnt even have a lib folder in it.
 
okay. and what if I want to make custom functions like this? my data folder doesnt even have a lib folder in it.

Your rev seems to be weird :S

But you can always paste the function inside the file where you want to use it :)
 
Your rev seems to be weird :S

But you can always paste the function inside the file where you want to use it :)

what I meant was, i want to make a function that I can call wherever I want, on the talkactions,movements, actions, etc.. I put it on global.lua and it seems to work, but its not organized. I want to put it on the lib folder, but it doesnt work.
 
Back
Top