Raised This Month: $ Target: $400
 0% 

How to create simple speclist


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
keygens
Senior Member
Join Date: Mar 2010
Location: Somewhere
Old 12-29-2014 , 15:29   How to create simple speclist
Reply With Quote #1

Hello to all. How i can create simple spectlist like: Spectators:1 or 2 and etc (in hud)? Thanks in advance

Last edited by keygens; 12-29-2014 at 15:31.
keygens is offline
11530
Veteran Member
Join Date: Sep 2011
Location: Underworld
Old 12-29-2014 , 15:36   Re: How to create simple speclist
Reply With Quote #2

Just a count of the players?

PHP Code:
ReplyToCommand("Spectators: %d"GetTeamClientCount(1)); //Using 1 since game not specified. 
Or the names of the players?
PHP Code:
ReplyToCommand("Spectators:");
for (new 
1<= MaxClientsi++)
{
  if (
IsClientInGame(i) && IsClientObserver(i))
  {
    
ReplyToCommand("%N"i);
  }

__________________
11530 is offline
keygens
Senior Member
Join Date: Mar 2010
Location: Somewhere
Old 12-29-2014 , 15:56   Re: How to create simple speclist
Reply With Quote #3

Quote:
Originally Posted by 11530 View Post
Just a count of the players?

PHP Code:
ReplyToCommand("Spectators: %d"GetTeamClientCount(1)); //Using 1 since game not specified. 
Or the names of the players?
PHP Code:
ReplyToCommand("Spectators:");
for (new 
1<= MaxClientsi++)
{
  if (
IsClientInGame(i) && IsClientObserver(i))
  {
    
ReplyToCommand("%N"i);
  }


Only count of players. I want to put it into hud at center.
keygens is offline
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 05:56.


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