CMD to get Rcon
#1

hi man, i dont remember what is the params for the cmd /getrcon

This cmd could get the rcon and show it to the player... It's cooz coz i use hard rcon pass's and want this cmd there...
Can someone tell me?

Thanks!
Reply
#2

What's the point of a "hard" Rcon pass if you're gonna make a command to get it?
Just look in the server.cfg..
Reply
#3

I believe you can set the RCON password inside the script, just let it generate a new pass with the random() function and save it into a variable, then show it to the player to have a little more safe RCON passes.
Reply
#4

Not this guys.... I know my pass and how to set it!
I want a command, so ingame i type: /getrcon and it tell me the rcon password of server(it check it) this is a way to prevent hacks too!
Reply
#5

It is insecure to do so, and how in the hell does it prevent hacks?
Reply
#6

Код:
//Inside of cmd
SendClientMessage(playerid,0xFFFFFFFF,"RCON Pass: '1234'");
//end
Edit the red.
Reply
#7

Just a simple command then?
Код:
	if (strcmp("/getrcon", cmdtext, true, 10) == 0)
	{
		SendClientMessage(playerid, 0xFFFFFFFF, "Type The Rcon Password Here");
		return 1;
	}
Reply
#8

Noooooooooo..... The command should check the Rcon alone, if i change it in cfg, it will check it!
Don't tell me this don't exist coz i has got it, but losted the code lol....

This command, will check rcon password from server files!
Reply
#9

You want to be able to display the online RCON admins?
Reply
#10

People, I thought that he asked a answer... please don't reply if you don't know how to help!

ricardo178:
You're able to easily get the value of variables (everything on /rcon varlist) using GetServerVarAsString (at all you can get int or variables too with another functions but it's not relevant right now).
Example:
pawn Код:
if(!strcmp(cmdtext,"/getrcon",true))
{
    new str[64];
    GetServerVarAsString("rcon_password",str,sizeof(str));
    format(str,sizeof(str),"RCON Password: \"%s\"",str);
    SendClientMessage(playerid,0xffffffaa,str);
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)