So we all know the function player.GetByID(), right?
Well i am needing to send a player over the network, and using their ID seems the best way. I have hit a total mind block with the whole thing, i have a huge nagging feeling that there is a better way, and i cannot remember how to get a players id for the life of me.
Forgive my idiot moment, but either the function that gets a players id, or a 'better' way to do this would be much appreciated :)
-snip-
[code]
lua_run_cl print( player.GetByID( 1 ):EntIndex() )
[/code]
Ignore me too. *hides in corner*
[url=http://wiki.garrysmod.com/?title=Player.UserID]Player.UserID[/url] is most likely what you're looking for. How do you want to send the player?
[QUOTE=Nevec;20447754][url=http://wiki.garrysmod.com/?title=Player.UserID]Player.UserID[/url] is most likely what you're looking for. How do you want to send the player?[/QUOTE]
Or that. Thanks.
And it doesn't really matter, as long as im not trying to send an entire player (as i were) to the client and back. I'm really tired and not so onto it at the moment. D:
Sorry, you need to Log In to post a reply to this thread.