Hi,
I'm trying to make a small mod that allows the admin to check what bindings the users are using to look for sketchiness.
Anyhow -- my problem is that the server doesn't seem to be getting the results of the consolecommand. What happens when I run the stuff below is that the client gets logged correctly, but the server just has blanks where is should have keynames and aliases. Is there any way to force this to get transferred??
Thnx
----------
replication
{
reliable if (Role<ROLE_Authority)
ServerLog;
reliable if (Role == ROLE_Authority)
getKeyBinding;
}
function ServerLog(String s)
{
log(s);
}
event PostLogin( playerpawn NewPlayer )
{
local Player P;
Local String s;
Local int i;
super.postLogin(NewPlayer);
NewPlayer.clientMessage("Hello & welcome");
serverLog( "################ Logging keybindings for "$ NewPlayer.PlayerReplicationInfo.PlayerName);
for ( i = 0; i < 255; i++ )
{
s = getKeyBinding(NewPlayer,i);
ServerLog(s);
}
serverLog( "################ Finnished Logging");
}
function String getKeyBinding(playerpawn NewPlayer, int i)
{
Local String keyName, Alias;
keyName = NewPlayer.ConsoleCommand ( "KEYNAME "$i );
Alias = NewPlayer.ConsoleCommand( "KEYBINDING "$keyName );
return NewPlayer.PlayerReplicationInfo.PlayerName$ ">> "$ keyname $ " : "$ Alias;
}
I'm trying to make a small mod that allows the admin to check what bindings the users are using to look for sketchiness.
Anyhow -- my problem is that the server doesn't seem to be getting the results of the consolecommand. What happens when I run the stuff below is that the client gets logged correctly, but the server just has blanks where is should have keynames and aliases. Is there any way to force this to get transferred??
Thnx
----------
replication
{
reliable if (Role<ROLE_Authority)
ServerLog;
reliable if (Role == ROLE_Authority)
getKeyBinding;
}
function ServerLog(String s)
{
log(s);
}
event PostLogin( playerpawn NewPlayer )
{
local Player P;
Local String s;
Local int i;
super.postLogin(NewPlayer);
NewPlayer.clientMessage("Hello & welcome");
serverLog( "################ Logging keybindings for "$ NewPlayer.PlayerReplicationInfo.PlayerName);
for ( i = 0; i < 255; i++ )
{
s = getKeyBinding(NewPlayer,i);
ServerLog(s);
}
serverLog( "################ Finnished Logging");
}
function String getKeyBinding(playerpawn NewPlayer, int i)
{
Local String keyName, Alias;
keyName = NewPlayer.ConsoleCommand ( "KEYNAME "$i );
Alias = NewPlayer.ConsoleCommand( "KEYBINDING "$keyName );
return NewPlayer.PlayerReplicationInfo.PlayerName$ ">> "$ keyname $ " : "$ Alias;
}