Raised This Month: $ Target: $400
 0% 

get_user_name vs client_infochanged variable


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Craxor
Veteran Member
Join Date: Jan 2016
Location: Romania
Old 07-04-2017 , 12:17   Re: get_user_name vs client_infochanged variable
Reply With Quote #1

Because using get_user_name() in client_infochanged() it's retrieving the 'Old Name' you have to use get_user_info to retrieve the new name.

For the sake of doing good things i believe is better to use the second operation, taking the name in an variable ant connnect+/and at client_infochanged().
__________________
Project: Among Us

Last edited by Craxor; 07-04-2017 at 12:18.
Craxor is offline
Send a message via ICQ to Craxor
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-04-2017 , 13:11   Re: get_user_name vs client_infochanged variable
Reply With Quote #2

Quote:
Originally Posted by Craxor View Post
For the sake of doing good things i believe is better to use the second operation, taking the name in an variable ant connnect+/and at client_infochanged().
It is extremely unlikely that this method is better. 99% of use cases, simply getting the user name when you need the user name is the best method.
__________________
fysiks is online now
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 23:09.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode