Jump to content

quetion


darhal

Recommended Posts

  
for i, v in ipairs( getElementsByType( "player" ) ) do 
local marker = createMarker( ... ) 
end 
  

nerver tried, maybe works.

But if this doesn't work you could trigger for all players from serverside and then create marker clientside.

Link to post
  
for i, v in ipairs( getElementsByType( "player" ) ) do 
local marker = createMarker( ... ) 
end 
  

nerver tried, maybe works.

But if this doesn't work you could trigger for all players from serverside and then create marker clientside.

lol ??? why he need to use this

Man use createMarker and it will be visible for all players

createMarker() 

Edited by Guest
Link to post

Lad his question was:

How to make a marker made client sided visible to all ? :D thx
--serverside-- 
addEventHandler( "onResourceStart", resourceRoot, 
function() 
for i, v in ipairs( getElementsByType( "player" ) ) do 
triggerClientEvent( "onPlayerCreateMarker", v ); 
end 
end ) 
  
--clientside-- 
addEvent( "onPlayerCreateMarker", true ); 
addEventHandler( "onPlayerCreateMarker", getLocalPlayer(), 
local marker = createMarker( x, y, z, "cylinder", 1, 255, 255, 0, 255 ); 
-- now you can add the rest of functions to marker here 
end ) 

This will do the work!

Link to post
any way the problem solved I triggerd the event to server side and then create the marker thx all

bro creating a marker server side , or client side it's the same it will be visible for all .

just it's depending on you how to create it.

Link to post

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