If false add to hudmessage
Hey guys
I have an array, that fills every cell with each player that connects, gives him his timeleft and sets that he is not ready (false). Now, I did a code that before a pug starts it shows who's not ready in a hudmessage column, that updates every 1 seconds. The problem is that it shows in the Not Ready list the server's name only and nobody else. could someone please tell me why is that? I'll post the public of client_connect so people would see that when client connects he gets a false in the boolean if he's ready or not, only when he types .ready it sets it to true but thats not relevant to the topic. So here's the code: PHP Code:
|
Re: If false add to hudmessage
PHP Code:
While i'm at it, as you're probably going to forget, you need to check if the user is connected or alive depending on the situation before you try to get his name. |
Re: If false add to hudmessage
g_bIsReady( hint #2 ).
EDIT: Code:
|
Re: If false add to hudmessage
Didn't see this before but
PHP Code:
PHP Code:
|
Re: If false add to hudmessage
Quote:
|
Re: If false add to hudmessage
Oh shit, didn't see that he was adding to notrdy later in the code. I thought he made another string to hold the HUD message.
Sorry. |
Re: If false add to hudmessage
5 Posts and I didn't get ANYTHING about what I should do to make it work. lol
Ingame it DOES send the hudmessage, but for some wierd reason it gives the server is name, so if the server was named "AlliedModders Pug", then you'd see: "Not Ready: AlliedModders Pug" And that's it, nothing more, and it doesnt get players names who are not ready, just the server name in there. I tried doing what Kreation said and use in the 'for' a variable that has get_maxplayers(), but didnt help still.... |
Re: If false add to hudmessage
Nvm I fixed it by my own, I just used the function get_players instead, and it worked, for some wierd reason.
|
Re: If false add to hudmessage
Quote:
get_user_name(g_bIsReady[i], playername, 31) -> get_user_name( i, playername, 31 ) Otherwise you were putting in a boolean for the first parameter, and I'm not sure why you didn't get a tag mismatch error. |
| All times are GMT -4. The time now is 01:05. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.