Printing out server_cmd to client console
Hi everyone
public status1(id) { server_cmd(id,"status") console_print(id,arg) => like that it prints rcon say , but not stats or status return PLUGIN_HANDLED; } So how it should look to print out status to users console , who requests it. P.S. i dont need cmdWho code , just need to print out sent command to server console to the user who requested it. |
Re: Printing out server_cmd to client console
client_print(id, print_cmd, "rcon amxx plugins")
? |
Re: Printing out server_cmd to client console
Didn't understand what you meant , the string you gave me is written wrong.
As for client_print , how should i make to print him out information given on "rcon amxx plugins" for example. |
Re: Printing out server_cmd to client console
Oh now I understand you. I do not know how to do it in my head, but I think you just need to get the information and then store it in an array, and then print that array into the console of the client.
I just think that it would be a bit messy, since it might now store the tabs and stuff, so it would be like one long line. I am sure someone in here can tell you how to get the information and store it somewhere. |
Re: Printing out server_cmd to client console
I don't get what you mean, perhaps Jelly could explain it a little better in clear English, but maybe this will be of use to you.
Code:
|
Re: Printing out server_cmd to client console
Im not good with arrays and that reformatting stuff at all , i have been checking cmdwho and cmdplugins. But didn't manage to somehow imitate that code for myself , since i didnt' understand half of it.
I need status from the server console or for example "stats". |
Re: Printing out server_cmd to client console
You need to force a client to type status, or you're trying to catch the output?
|
Re: Printing out server_cmd to client console
Output , i want to show the output of the status in server console , in user console.
|
Re: Printing out server_cmd to client console
I think that what he wants, is a plugin where a guy writes /plugins (as an example), and then get the rcon output of amxx plugins in his own console, as if his console were the server console, without them being an admin.
I just think he wants to let people use rcon commands, which is read-only, without being admins, or have access to rcon commands. Can you confirm this ngEAr? |
Re: Printing out server_cmd to client console
Not really , im just making small plugin with rcon command inside it. So i wont need to give everyone rcon , that's why i need to make i cmd for outputting status.
Here is an idea how i made it now public status1(id) { server_cmd("rcon_password elda",id) client_cmd(id,"rcon_password elda") client_cmd(id,"rcon status") } What should i add after 3rd string in order to remove rcon from the server , since for removing it uses arg "" and the cmd is inside of those "". As i understood set_cvar_string doesnt work for it , i wanted to make Set Task for it , so it removes it after ~10seconds. |
| All times are GMT -4. The time now is 03:39. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.