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

How do I change the Limit of the ActionID? // Level doors

chyssler

Member
Joined
May 8, 2012
Messages
41
Reaction score
7
Hello, Does anybody knows how you can Exceed the limit of 65535 in the ActionId?

Atm when Using RME, and adding for example ActionID 85000, it automatically goes to 65535 (which i assume is the limit), But is their a way to increase the limit of it? or is their a easier way to fix it?

I'm having thoose doors "Gate of Expertise" And I have a variety of doors which has its own req Level to enter. the ones below 65000 is no problem. however beyond 65000 there is problems as the limit is 65535 :D

Do I have to change Lua scripts / or something else?

please let me know. ty

8.6 Server
 
Check doors.lua and modify the script, probably the easiest way would be to lose some resolution and simply multiply the result of the level check by 10 so what used to check for level 65,000 would instead check for 650,000.
 
Check doors.lua and modify the script, probably the easiest way would be to lose some resolution and simply multiply the result of the level check by 10 so what used to check for level 65,000 would instead check for 650,000.
hm, do you know a way to do that?
 
if you need more attributes with opening the door you can use an acction script which gives some effects or more cancel message. it will provide any level and anything you need with Action Script
 
Which TFS? 0.4? 1.2? There are many 8.6 servers with different doors.lua scripts.
tfs 1.3
Post automatically merged:

if you need more attributes with opening the door you can use an acction script which gives some effects or more cancel message. it will provide any level and anything you need with Action Script
yea. im just not sure what will work. i tried adding a action script within the action/script folder. a lua script. but it wouldnt load it, within the actions.xml
 
as they mention upthere the action id has a limit and works automaticlly
but for more modifies its better to make a custom action script for all doors
and im sorry i dont know anything with 1.3
 
hm, do you know a way to do that?
in data/actions/scripts/other/doors.lua

Lua:
    elseif table.contains(levelDoors, itemId) then
        if item.actionid > 0 and player:getLevel() >= item.actionid - actionIds.levelDoor then  -- this is the line that checks the level, if the door has an action id and the players level is bigger than or equal to the action id minus 1000 then let him through.
            item:transform(itemId + 1)
            player:teleportTo(toPosition, true)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Only the worthy may pass.")
        end
        return true
change to
Lua:
    elseif table.contains(levelDoors, itemId) then
        if item.actionid > 0 and player:getLevel() >= (item.actionid - actionIds.levelDoor) * 10 then
            item:transform(itemId + 1)
            player:teleportTo(toPosition, true)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Only the worthy may pass.")
        end
        return true

All i did was multiply the check by 10 so now the minimum level for a door is 10 and any level you choose will now have a hard limit of being a multiple of 10.
It also means you would have to change every actionid of every quest door on your map since now they all require 10x the level.

Example action id = 1008, the required level to enter would be 80 instead of 8.

This is not an ideal 'fix', you should really try to make or request a script that can do this better for you without interfering with the current default script. But it works in a pinch I guess.
 
Last edited:
in data/actions/scripts/other/doors.lua

Lua:
    elseif table.contains(levelDoors, itemId) then
        if item.actionid > 0 and player:getLevel() >= item.actionid - actionIds.levelDoor then  -- this is the line that checks the level, if the door has an action id and the players level is bigger than or equal to the action id minus 1000 then let him through.
            item:transform(itemId + 1)
            player:teleportTo(toPosition, true)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Only the worthy may pass.")
        end
        return true
change to
Lua:
    elseif table.contains(levelDoors, itemId) then
        if item.actionid > 0 and player:getLevel() >= (item.actionid - actionIds.levelDoor) * 10 then
            item:transform(itemId + 1)
            player:teleportTo(toPosition, true)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Only the worthy may pass.")
        end
        return true

All i did was multiply the check by 10 so now the minimum level for a door is 10 and any level you choose will now have a hard limit of being a multiple of 10.
It also means you would have to change every actionid of every quest door on your map since now they all require 10x the level.

Example action id = 1008, the required level to enter would be 80 instead of 8.

This is not an ideal 'fix', you should really try to make or request a script that can do this better for you without interfering with the current default script.

nice idea, it would work even better if the x10 part worked only for level 999 and above, and it would retain backward compatibility :D
 
nice idea, it would work even better if the x10 part worked only for level 999 and above, and it would retain backward compatibility :D
this is how my doors.lua is:
elseif table.contains(levelDoors, itemId) then
if item.actionid > 0 and player:getLevel() >= item.actionid - 1000 then
item:transform(itemId + 1)
player:teleportTo(toPosition, true)
else
player:sendTextMessage(MESSAGE_INFO_DESCR, "Only the worthy may pass.")
end
return true
Post automatically merged:

and is their a easy way to make a custom action script for each door? (i dont know coding in ot) The door level req is above 65k (limit in actionid is 65535)
 
Back
Top