Jump to content

Spawngate not working


Tonnzza

Recommended Posts

Another marker does not open a port for what could be wrong?

--gate-- 
gate1 = createObject(980, -1980.5789794922, 283.62588500977, 37, 0,0,90) 
gate2 = createObject(980, -1980.5789794922, 293.22588500977, 37, 0,0,90) 
  
-- Markers -- 
hitMarker1 = createMarker(-1985.8018798828, 288.45, 33.54, 'cylinder', 3, 255, 0, 0, 150) 
hitMarker2 = createMarker(-1976.7435302734, 288.45, 33.54, 'cylinder', 3, 255, 0, 0, 150) 
  
function moveGateUpA( hitElement, matchingDimension ) 
    local x1, y1 = getElementPosition( gate1 ) 
    local x, y = getElementPosition( gate2 ) 
    moveObject( gate1, 5000, x1, y1, 43) 
    moveObject( gate2, 5000, x, y, 43) 
end 
addEventHandler( "onMarkerHit", hitMarker1, moveGateUpA ) 
  
  
function timerReady(s) 
    local x, y = getElementPosition( gate1 ) 
    local x2, y2 = getElementPosition ( gate2 ) 
    moveObject(gate1, 5000, x, y, 37 ) 
    moveObject(gate2, 5000, x2, y2, 37 ) 
end 
  
function moveGateDownA( leaveElement, matchingDimension ) 
    setTimer ( timerReady, 10000, 1, source ) 
end 
addEventHandler( "onMarkerLeave", hitMarker2, moveGateDownA ) 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...