Jump to content

Hello there


S3M

Recommended Posts

createBlip ( 2480.8781738281,-1536.7038574219,24.189489364624, 60 ) 
  
local MarkerTaxi2 = createMarker( 2478.3999023438, -1513.6999511719, 23.10000038147, "cylinder", 4, 255, 255, 255, 15) 
local Taxigate1 = createObject(994, 2475.3000488281, -1514.4000244141, 23) 
  
function MarkerHit1(hitElement, matchingDimension) 
 if getElementType(hitElement) == "player" then 
local vehicle = getPedOccupiedVehicle ( player ) 
if vehicle or not vehicle then 
local skin = getElementModel ( player ) 
if skin == 255 then 
  
moveObject(Taxigate1, 3000, 2475.3000488281, -1514.4000244141, 22.1 ) 
end 
end 
end 
end 
addEventHandler ( "onMarkerHit", MarkerTaxi2, MarkerHit1 ) 
  
function MarkerLeave1(leaveElement, matchingDimension) 
if getElementType(hitElement) == "player" then 
local vehicle = getPedOccupiedVehicle ( player ) 
if vehicle or not vehicle then 
local skin = getElementModel ( player ) 
if skin == 255 then 
  
moveObject(Taxigate1, 3000, 2475.3000488281, -1514.4000244141, 23) 
end 
end 
end 
end 
addEventHandler ( "onMarkerLeave",  MarkerTaxi2, MarkerLeave1 ) 

What i do wrong?

The gates want go down iff player have driver skin 255

Link to comment

Also when showing MTA:SA Scripting Code ( Lua Scripting ) please us the Lua Tags.

and when you do you will get something like this

  
function testCommand( thePlayer ) 
      outputChatBox("Hello there Player", thePlayer, 214, 283, 135) 
end 
addCommandHandler("testCommand", testCommand) 
  

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