Raised This Month: $ Target: $400
 0% 

Issue loading player names.


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Bad_Bud
Senior Member
Join Date: Oct 2006
Location: The internet
Old 05-13-2007 , 02:26   Issue loading player names.
Reply With Quote #1

Two things to note:
  1. The mod I'm running this plugin on is The Specialists.
  2. The database/loading of the information is 100% correct, so the problem isn't there.
As for the problem: I want my server to be set so that when a player joins the game it loads in his name from a set up database (their name will be the same every time they join) and changes his name to the loaded name.

I have problems with this, though. If I try to change the player's name from client_putinserver, it seems like it doesn't make a difference. I have a bool set up for each player stating whether or not their name is allowed to change at that moment (I have it check to see if the name is allowed to be changed in the infochanged function) so that they can change the style of their name through a menu, such as they have a first and last name, and they may want to change their name from "FIRST LAST" to "Mr. LAST", otherwise, it cannot be changed.

Anyway, enough confusing blab, the problem is that even though I have the name correctly loaded from the SQL database, it doesn't apply the name correctly to the player when they join if I call it from putinserver. The only way I've found to get it to work to set it when they join is by using a set_task for changing the name, but even then I have to set the timer on that to about 15 seconds, which is a long time, considering some may join in two seconds, then wait a weird amount of time before their name seems to randomely change.

I know there's already a plugin that does this, but I've looked at the source for that, and they change the name from putinserver, so I don't know what the problem could be. (Oh, and I change their model from the same spot and have never had any problems.)

If you don't understand what I'm saying, please ask questions.

P.S. Is there a way to call a function on the client's first spawn in the server? That would be a great place to change the name from.
__________________

Last edited by Bad_Bud; 05-13-2007 at 02:30.
Bad_Bud is offline
 


Thread Tools
Display Modes

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 10:30.


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