Jump to content

gates


mint3d

Recommended Posts

Posted

could i use this

    gate1= createObject ( 980, 134.39999389648, 1941.5, 21.10000038147, 0, 0, 0 ) 
    gatecol = createColCircle ( 134.39999389648, 1941.5, 21.10000038147, 8 ) 
  
function opengates(thePlayer) 
if ( getTeamName(getPlayerTeam(thePlayer)) == "ArmedForces" ) then 
       moveObject (gate1, 5000, 145.89999389648, 1941.5, 21.10000038147 ) 
end 
end 
addEventHandler( "onColShapeHit", gatecol, opengates ) 
  
function closegates(thePlayer) 
if ( getTeamName(getPlayerTeam(thePlayer)) == "ArmedForces" ) then 
       moveObject (gate1, 5000, 134.39999389648, 1941.5, 21.10000038147 ) 
end 
end 
addEventHandler( "onColShapeLeave", gatecol, closegates ) 

Skype: Jordan_Nymph

Posted

You can also use getElementByID if you want to have the gate object on a map file.

And yes, that should work.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

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...