[FilterScript] [FS] Fallout's Improved Player Info. (console command)
#1

Fallout's Improved Player Info



Hi everyone!
I made a new 'playerinfo' command because the old 'player' command (in console) was a little.. crappy (sorry developers but you can't say that it is beautifully arranged)

the old one looks like this:


and the new one looks like this :


(notice the little difference xD)

The '/' that you see under 'State:' means that the player is joining.

I also added some new stuff ^^
I hope you think it's useful
It may be used for watching your server when you aren't playing on it. Than you can see if there is a player online that you don't want to be there or maybe a player is in a vehicle that is forbidden... or he can have a to high ping; that's why it could be useful

Download:



How to use:
- Put this filterscript in this folder: server\filterscripts\<here>
- Add F_IPInfo to your filterscripts line in server.cfg
- Type "playerinfo" (without " ") in the console.
- Enjoy!

Updates:
- Script is shorter now - same result. (thx Yom)



pls comment
Reply
#2

hm good, very usefully , good work
Reply
#3

thx chytrak
Reply
#4

Nice script. I thought the developers have done the players-command smart and quick. In the original format you can get the data into an array. (by stripping "\t")
Reply
#5

Quote:
Originally Posted by [1337
MaVe ]
Nice script. I thought the developers have done the players-command smart and quick. In the original format you can get the data into an array. (by stripping "\t")
thx,
yes they made it quick :P they used tabs for every new column and when a name is shorter than an other name, the tab goes one tab further :P that's why it looks a little crappy
Reply
#6

Very nice, it's awesome.
Reply
#7

Quote:

if(PlayerName_Length == 3) { Tab_PlayerName_Length = " "; }
if(PlayerName_Length == 4) { Tab_PlayerName_Length = " "; }
if(PlayerName_Length == 5) { Tab_PlayerName_Length = " "; }
if(PlayerName_Length == 6) { Tab_PlayerName_Length = " "; }
etc etc..



Why don't you just use %Xs (where X is a number..)

Ex:
pawn Code:
printf( "%10s test", "First" );
printf( "%10s test", "Second" );
==
Code:
First  test
Second  test
Another example here.

Edit: also why do you use printf, like here,
pawn Code:
printf("ID: Name:       IP:        Ping: RCON: Vehicle:    State:");
when it's unneeded as you format nothing
Reply
#8

OnRconCommand should also be possible with a gm , not only fs's
Reply
#9

while trying to make that, i noticed that it only works for strings, not for integers

string example:
Code:
%10s becomes "aaaaa  "
integer example:
Code:
%10i becomes "  00000"
so with integers he puts the spaces in front of the value

Quote:
Originally Posted by Rks_
OnRconCommand should also be possible with a gm , not only fs's
hmm i read somewhere that it only works for fs's and than i didn't try it in gm

edit:
Quote:
Originally Posted by yom
Edit: also why do you use printf, like here,
pawn Code:
printf("ID: Name:      IP:       Ping: RCON: Vehicle:    State:");
when it's unneeded as you format nothing
i probably copy pasted from an other line xD



I'll work it out tomorrow :P g2g now
Reply
#10

Quote:
Originally Posted by °ғαιιοцт°
with integers he puts the spaces in front of the value
I think it's the way it should be, for me:
Code:
  12 players
 324 vehicles
 7890 objects
is easier to read than
Code:
12  players
324  vehicles
7890 objects

Quote:
Originally Posted by °ғαιιοцт°
Quote:
Originally Posted by Rks_
OnRconCommand should also be possible with a gm , not only fs's
hmm i read somewhere that it only works for fs's and than i didn't try it in gm
It works in both but need to be used in a FS before it works in the GM.

This is enough to get it working in the GM (copy/paste in a blank file, compile and run as a FS):
pawn Code:
#forward OnRconCommand(cmd[]);
public OnRconCommand(cmd[])
  return false;
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)