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

Remove stair PVP tibia 0.4

zabuzo

Well-Known Member
Joined
Jun 10, 2016
Messages
238
Reaction score
54
Remove stair PVP tibia 0.4

I really love tibia PVP...
But there is only one thing i HATE and so much other people rates...

Stair PVP... A noob stay up and down stairs to dont die...
It is detestable...


I was thinking to how block it and get free to this plage.

That's my ideias:

1- to rope need use only upside rope hole
Like is on tibianic, like was on old tibia...
If have only one thing upside the rope hole, u cant get up...

2- When you move upside a stair like
latest

latest

latest


You lose 50% your speed or get a paralyze

How to do it guys? It's so good to all servers!



========================================

Thats my actions/scripts/tools/rope.lua
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
   if(toPosition.x == CONTAINER_POSITION) then
     doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
     return true
   end

   toPosition.stackpos = STACKPOS_GROUND
   local itemGround = getThingFromPos(toPosition)
   if(isInArray(SPOTS, itemGround.itemid)) then
     doTeleportThing(cid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z - 1}, false)
     return true
   elseif(isInArray(ROPABLE, itemEx.itemid)) then
     local hole = getThingFromPos({x = toPosition.x, y = toPosition.y, z = toPosition.z + 1, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE})
     if(hole.itemid > 0) then
       doTeleportThing(hole.uid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z}, false)
     else
       doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
     end

     return true
   end

   return false
end

That's is my player.cpp
http://hastebin.com/dukisoyayi.cpp
 
Last edited:
Why not made a map with just one floor? Solved!

And... Yeah. The most honest think that exists are a 1 vs 7 PVP (also knowed as 7 guys trying to trap another one), if the player go up and down on stairs it's a noob one. Why not be a real man and face them?

Or even a guild trying to get kills on low level players. Why don't just die and give the guild another frag?

Ah, don't forget about the strong monsters. Anyone can tank them, nobody never go up and down spamming spells/runes to kill them. I'm pretty sure you never did it.

kek
 
LOL, it's really possible just edting rope.lua?
yes, example: tfs1.2
Code:
if isInArray(ropeSpots, tile:getGround():getId()) or tile:getItemById(14435) then
to
Code:
if isInArray(ropeSpots, tile:getTopVisibleThing():getId()) or tile:getTopVisibleThing():getId() == Player(player):getId() or tile:getItemById(14435) then
 
yes, example: tfs1.2
Code:
if isInArray(ropeSpots, tile:getGround():getId()) or tile:getItemById(14435) then
to
Code:
if isInArray(ropeSpots, tile:getTopVisibleThing():getId()) or tile:getTopVisibleThing():getId() == Player(player):getId() or tile:getItemById(14435) then

Do you have any ideia how to make it in my rope.lua 0.40?
 
What i need to change in my rope.lua?
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
if(toPosition.x == CONTAINER_POSITION) then
doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
return true
end

toPosition.stackpos = STACKPOS_GROUND
local itemGround = getThingFromPos(toPosition)
if(isInArray(SPOTS, itemGround.itemid)) then
doTeleportThing(cid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z - 1}, false)
return true
elseif(isInArray(ROPABLE, itemEx.itemid)) then
local hole = getThingFromPos({x = toPosition.x, y = toPosition.y, z = toPosition.z + 1, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE})
if(hole.itemid > 0) then
doTeleportThing(hole.uid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z}, false)
else
doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
end

return true
end

return false
end


There is a way to make the question 2
In movemments?

When move upside itemids 1396, 1394 get paralyze per 2 secs?
Or is better try something on sources?
 
What i need to change in my rope.lua?
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
if(toPosition.x == CONTAINER_POSITION) then
doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
return true
end

toPosition.stackpos = STACKPOS_GROUND
local itemGround = getThingFromPos(toPosition)
if(isInArray(SPOTS, itemGround.itemid)) then
doTeleportThing(cid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z - 1}, false)
return true
elseif(isInArray(ROPABLE, itemEx.itemid)) then
local hole = getThingFromPos({x = toPosition.x, y = toPosition.y, z = toPosition.z + 1, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE})
if(hole.itemid > 0) then
doTeleportThing(hole.uid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z}, false)
else
doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
end

return true
end

return false
end


There is a way to make the question 2
In movemments?

When move upside itemids 1396, 1394 get paralyze per 2 secs?
Or is better try something on sources?
in that rope.lua try to change STACKPOS_GROUND to 1 then test
 
can you give a picture example of what you mean with the rope? i didnt play old clients so i have a hard time understanding what you mean

as for the stairs, as streamside said, onCreatureMove in player.cpp is probably the best solution, but you can also do it with onStepIn script on stairs for example (e.g setting same action id to all stairs, then in script giving player paralyze when they walk on it if in pvp etc)
 
can you give a picture example of what you mean with the rope? i didnt play old clients so i have a hard time understanding what you mean

as for the stairs, as streamside said, onCreatureMove in player.cpp is probably the best solution, but you can also do it with onStepIn script on stairs for example (e.g setting same action id to all stairs, then in script giving player paralyze when they walk on it if in pvp etc)

It's simple
carlin-hole-under-sewer.gif


If have 1gp or anyother item on this hole, u cant use rope and get up if u not remove that trashs....

Do you have any idea how make this thing on player.cpp?

player.cpp:
http://hastebin.com/mewoxegaca.cpp
 
if you add to ur rope.lua
Code:
print(getTileThingByPos(toPosition))
and tell me what it says when you use rope on a tile with coin or w/e on it

and no sorry, i dont code c++, only lua
 
if you add to ur rope.lua
Code:
print(getTileThingByPos(toPosition))
and tell me what it says when you use rope on a tile with coin or w/e on it

and no sorry, i dont code c++, only lua

:(

Just a break line on console
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
   if(toPosition.x == CONTAINER_POSITION) then
     doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
     return true
   end

   toPosition.stackpos = STACKPOS_GROUND
   local itemGround = getThingFromPos(toPosition)
   if(isInArray(SPOTS, itemGround.itemid)) then
     print(getTileThingByPos(toPosition))
     doTeleportThing(cid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z - 1}, false)
     return true
   elseif(isInArray(ROPABLE, itemEx.itemid)) then
     local hole = getThingFromPos({x = toPosition.x, y = toPosition.y, z = toPosition.z + 1, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE})
     if(hole.itemid > 0) then
       print(getTileThingByPos(toPosition))
       doTeleportThing(hole.uid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z}, false)
     else
       doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
     end

     return true
   end

   return false
end
 
change
Code:
print(getTileThingByPos(toPosition))
to
Code:
print_r(getTileThingByPos(toPosition))
and add
Code:
function print_r ( t )
local print_r_cache={}
local function sub_print_r(t,indent)
if (print_r_cache[tostring(t)]) then
print(indent.."*"..tostring(t))
else
print_r_cache[tostring(t)]=true
if (type(t)=="table") then
for pos,val in pairs(t) do
if (type(val)=="table") then
print(indent.."["..pos.."] => "..tostring(t).." {")
sub_print_r(val,indent..string.rep(" ",string.len(pos)+8))
print(indent..string.rep(" ",string.len(pos)+6).."}")
else
print(indent.."["..pos.."] => "..tostring(val))
end
end
else
print(indent..tostring(t))
end
end
end
sub_print_r(t," ")
end
above function onUse and show me picture of all if prints
 
Back
Top