Issue with registerRegion
Posted: Thu Nov 10, 2016 7:16 pm
Hello,
I am trying to setup Salvage on my server and I am coding Bhaflau Remnants at the moment. I am trying to get the teleporter to work on the first floor to take players up to the second floor. I already have the event ID that causes the warp to the proper floor, however, I am trying to get registerRegion to work. Below is my code that I have
When I get to the teleporter at 339, -1, -420, nothing happens. I have even tried inputing a print to player so it prints something to the console so I know it is working, but nothing happens. Any help would be greatly appreciated. Thanks.
I am trying to setup Salvage on my server and I am coding Bhaflau Remnants at the moment. I am trying to get the teleporter to work on the first floor to take players up to the second floor. I already have the event ID that causes the warp to the proper floor, however, I am trying to get registerRegion to work. Below is my code that I have
Code: Select all
-----------------------------------
-- onInitialize
-----------------------------------
function onInitialize(zone)
zone:registerRegion(1,336.711,-1,-416.384,343.571,-1,-423.319); -- First Floor Teleporter
end;
-----------------------------------
-- onRegionEnter
-----------------------------------
function onRegionEnter(player,region)
if(region:GetRegionID() == 1) then
player:startEvent(0x00d1);
end
end;