Raised This Month: $51 Target: $400
 12% 

get server print


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
MacL
Member
Join Date: May 2021
Old 05-17-2021 , 02:58   get server print
Reply With Quote #1

I need to get the server prints and show the output to the player. Like when a command is for a server console and cannot be used in-game. like:
PHP Code:
register_svcmd("Acc_put""function"); 
output in serverconsole:
PHP Code:
sv_print("Hello World"); 
and showing to player:
PHP Code:
// get sv_print
client_print(idprint_console"%s"sv_print); 
How can i do this?

Last edited by MacL; 05-17-2021 at 02:59.
MacL is offline
OrangePeel
Junior Member
Join Date: Aug 2019
Old 05-17-2021 , 05:07   Re: get server print
Reply With Quote #2

try this.

PHP Code:
public function() {
    static 
args[194];
    
read_args(argscharsmax(args));

    
client_print(0print_console"%s"args); 

OrangePeel is offline
Natsheh
Veteran Member
Join Date: Sep 2012
Old 05-17-2021 , 09:17   Re: get server print
Reply With Quote #3

What ?

It will be easier to explain what are you trying to achieve rather than code talk.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !


Last edited by Natsheh; 05-17-2021 at 09:18.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 05-17-2021 , 11:45   Re: get server print
Reply With Quote #4

Quote:
Originally Posted by Natsheh View Post
What ?

It will be easier to explain what are you trying to achieve rather than code talk.
I think he's trying to sort of "activate" commands which are used in the server console, or by using rcon pass, to make them also work as a player command. This is just a simple example of a text message being displayed in the server console, i doubt if this could work for more advanced commands. I'd rather just create a new command in the original plugin that works for players aswell.
__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
MacL
Member
Join Date: May 2021
Old 05-18-2021 , 14:29   Re: get server print
Reply With Quote #5

Quote:
Originally Posted by OrangePeel View Post
try this.

PHP Code:
public function() {
    static 
args[194];
    
read_args(argscharsmax(args));

    
client_print(0print_console"%s"args); 

it cant be like that.
MacL is offline
MacL
Member
Join Date: May 2021
Old 05-18-2021 , 14:33   Re: get server print
Reply With Quote #6

Quote:
Originally Posted by Natsheh View Post
What ?

It will be easier to explain what are you trying to achieve rather than code talk.
there is command it can be used only in svConsole. its from a module. it pirnt a text in svConsole. i want to get that text and use it in plugin.
MacL is offline
Old 05-18-2021, 21:56
fysiks
This message has been deleted by fysiks. Reason: nvm
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 15:36.


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