Jump to content

Showing dx only to one person?


Lukkaz

Recommended Posts

  
function iceBreaker() 
addEventHandler("onClientClick", getRootElement(), convoReply) 
addEventHandler("onClientRender", getRootElement(), convoDX) 
end 
  
addEvent("breakIce", true) 
addEventHandler("breakIce", getRootElement(), iceBreaker) 
  
  
function convoEnd() 
removeEventHandler("onClientClick", getRootElement(), convoReply) 
removeEventHandler("onClientRender", getRootElement(), convoDX) 
setCameraTarget(getLocalPlayer()) 
showCursor(false) 
cLevel = 1 
cOption = 1 
end 
  
addEvent("endConvo", true) 
addEventHandler("endConvo", getRootElement(), convoEnd) 
  
  

Link to comment

how could your way even work?

So every client ADDS an EVENT for each remote player???

This isn't possible..

His problem is most likely when he triggers breakIce and endConvo

the triggerClientEvent should look like this:

triggerClientEvent(, 'breakIce', getRootElement())

You're most likely missing the first argument in the triggerClientEvent() function. You should read about it in the wiki to understand it fully

Link to comment
Jaysds1 that's wrong. If you want to trigger a client event from the server side for only the source player use this.
triggerClientEvent(source,"event name",source) 

It wont really work, unless the source is the actual player, otherwise he would have to get the player element from an argument.

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