Hi guys,
Can anyone add a line so that when player has vocation base 2, message is sent that he cannot enter and isn't allowed through.
Tried to edit this myself in multiple ways but I couldn't get it working -_-"...smh.
Lua:
local exitPosition = Position(32308, 32267, 7)
function onStepIn(creature, item, position, fromPosition)
local player = creature:getPlayer()
if not player then
return true
end
if player:getVocation():getBase():getId() == 1 then
return true
end
player:teleportTo(exitPosition)
player:getPosition():sendMagicEffect(CONST_ME_MAGIC_BLUE)
return true
end
Tried to edit this myself in multiple ways but I couldn't get it working -_-"...smh.