General > Developers Corner

Log ONLY to Console

(1/2) > >>

iViscosity:
Was wondering if there was a way to log something with ULX (or just in general) that will ONLY echo to the console. I'm writing a script that, for security reasons, should not be echoed to anyone except the parties involved. Would something like 'MsgN()' be useful, or is there a more convenient and safer way of doing this?


EDIT: Right now I'm using fancyLog( { calling_ply } and fancyLog( { target_ply } (different messages to each) so that it sends ONLY to them, is there a safer way of letting them know this?


EDIT2: Would ServerLog work?

MrPresident:
ServerLog would only log to the Dedicated Console and none of the connected clients.

iViscosity:
Yeah I guess it was kind of confusing what I was asking there. Pretty much, ServerLog is what I need to log to only the server, is there any safe way to notify players in the game about something that is sent ONLY to them and no one else? I'm thinking of using HUD_PRINTCONSOLE (with PrintMessage(), I think that's the one), but I need to know if there is any way that can be intercepted.

Bytewave:

--- Quote from: iViscosity on December 19, 2016, 07:34:18 AM ---I'm thinking of using HUD_PRINTCONSOLE (with PrintMessage(), I think that's the one), but I need to know if there is any way that can be intercepted.

--- End quote ---
Unless someone has network access, I doubt this data would be interceptable.

MrPresident:
Yeah, the server chooses who to send messages to, so if you only send a message to 1 client.. no other client can intercept it.

If you're worried about the server seeing messages sent between 2 clients... well... that's just how it goes..

Navigation

[0] Message Index

[#] Next page

Go to full version