• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

vocation door

jlskelin

New Member
Joined
Mar 28, 2009
Messages
198
Reaction score
1
how to make a vocation door if you have more vocation not only druid and elder druid and priest i have on my server how to make ia vocation door ?
 
Apply a script to the door, check for specific vocations and only allow those vocations to pass through, as @silveralol stated you need to tell us the tfs version your using so someone can write up a script.
 
oh sorry version 0.3.6 i mean like if the voc door is for druid does it matter if your elder druid can you go through i have more then one voc on may server like druid then elder then priest
 
In doors.lua you can look what is already added for doors.
For vocation doors it has this.
Code:
local vocation = item.actionid - 100
if(vocation >= 0 and vocation < 50) then
     local playerVocationInfo = getVocationInfo(getPlayerVocation(cid))
     if(playerVocationInfo.id ~= vocation and playerVocationInfo.fromVocation ~= vocation) then
         doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Only the worthy may pass.")
         return true
     end

     doorEnter(cid, item, toPosition)
     return true
end
So you can add actionid 100 + vocationid to a gate of expertise door, which will be actionid 101 for sorcerer, 102 for druid etc.
 

Similar threads

  • Question Question
Replies
2
Views
574
Back
Top