Jump to content

Marker question


FWCentral

Recommended Posts

How can i create a marker(checkpoint) only visible to the player that started the function?

I've already tried this:

  
firstmarker = createMarker(1372.04126, -1600.24585, 13.24007,"checkpoint", 1.5, 0, 255, 0, false)--Also tried source and getRootElement as  the last argument this didn't work  
-- other stuff like marker blip ( This works only visible to the player )  
  
for id, player in ipairs(getElementsByType("player")) do -- added this to see if i can hide it from all players  
setElementVisibleTo ( firstmarker, player, false ) 
end 
setElementVisibleTo(firstmarker, source, true) -- then show it to the source 
  
-- this is inside a function that is triggerd from client that works fine. 
  

So far ive had no luck with this, I tried adding it client side but onMarkerHit is Server Sided so i don't know whats going on with this.

Link to comment
firstmarker = createMarker(1372.04126, -1600.24585, 13.24007,"checkpoint", 1.5, 0, 255, 0, false) 
setElementVisibleTo( firstmarker, getRootElement(), false ) 
  
setElementVisibleTo(firstmarker, source, true) -- then show it to the source 
  
-- this is inside a function that is triggerd from client that works fine. 
  

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