Ulysses
Ulysses Stuff => General Chat & Help and Support => Topic started by: Weapon317 on February 26, 2011, 12:55:47 PM
-
Hey guys, i have a question.
When a players connects it says "Player [name] had joined the game" but i want when they are in the game it says "Player [name] entered the game with steam id [id]" and when they leave it says "player [name] left the game with steam id [id]" A friend of mine told it was a ULX addon? But couldnt find it D:
I use the GUI made by Sticky man, great work there man btw :) The SVN Version
Thanks! :D
-
I'm pretty sure the message you're specifically talking about, the non steamid one, is created by the server itself, not any addon including ULX.
ULX has log files that track atll that, and can be set to display joins ip and steamid in the console, but not the chat area.
I see no reason to have that in the chat text, as it would duplicate the server's actual announcement, and be a bit annoying (imo).
Also, I see no efficient way to have the player's steamid listed when they leave.
The gmod lua command PlayerDisconnect doesn't keep track, it kicks off after the player is gone, after the steamid and ip are no longer known to the lua environment.
I'm not saying the code couldn't be written to track all of that, but, it seems a waste of memory.
-
I'm pretty sure the message you're specifically talking about, the non steamid one, is created by the server itself, not any addon including ULX.
ULX has log files that track atll that, and can be set to display joins ip and steamid in the console, but not the chat area.
I see no reason to have that in the chat text, as it would duplicate the server's actual announcement, and be a bit annoying (imo).
Also, I see no efficient way to have the player's steamid listed when they leave.
The gmod lua command PlayerDisconnect doesn't keep track, it kicks off after the player is gone, after the steamid and ip are no longer known to the lua environment.
I'm not saying the code couldn't be written to track all of that, but, it seems a waste of memory.
Hmm cuz i saw it in a server before and it was quite usefull when a player Joins you see in chat "Player [name] entered the game with steam id: [id]" Is there any way i could make that work in ULX or else?
-
There is a way, in addition to the common one the Source server says, but, why do you need it in the chat area?
Is the console not enough?
I'd leave a server if everytime someone joined I had to see two join messages, one from the server, one from a mod.
-
There is a way, in addition to the common one the Source server says, but, why do you need it in the chat area?
Is the console not enough?
I'd leave a server if everytime someone joined I had to see two join messages, one from the server, one from a mod.
Hmm i guess ur right, well then yeah in console might do, but how do i see/activate that, that i can see steamid's in console? (when a player joins u see his steam id in console with his name to) (Sorry im not really common with this kind of stuff >.>)
EDIT: I found this code on the website
local function playerFirstSpawn( ply )
if util.tobool( GetConVarNumber( "ulx_logEvents" ) ) then
ulx.logString( string.format( "%s [%s][%s] joined the server.", ply:Nick(), ply:SteamID(), ply:IPAddress() ) )
end
end
hook.Add( "PlayerInitialSpawn", "ULXLogConnect", playerFirstSpawn )
Where can i put this to test it in my serv? Cuz this is actolly exacly what i was looking for, In lua/autorun/server it doesnt work but i probebly have to put it into a ULX file, besides i founded out the log thing for console but it dont work :( it dont show up in my console and its enabled. I use SVN ULX Version 3.5 and ULib 2.4 (SVN 158)
-
That is logging it, not printing it into chat/console. Just change it accordingly via Player.ChatPrint (http://wiki.garrysmod.com/favicon.ico) (http://wiki.garrysmod.com/?title=Player.ChatPrint) or G.MsgAll (http://wiki.garrysmod.com/favicon.ico) (http://wiki.garrysmod.com/?title=G.MsgAll).
-
Added a cvar in newest ULX revision to print a player's steamid to admins' consoles when joining/leaving.
-
Added a cvar in newest ULX revision to print a player's steamid to admins' consoles when joining/leaving.
Thought logstring already did print to admins consoles, like entity spawning/etc.
Been a while, guess I was wrong.
-
Thought logstring already did print to admins consoles, like entity spawning/etc.
Been a while, guess I was wrong.
It does if they spawn something, but only if they spawn something. What if a player comes in and griefs without spawning anything? Anyways, I thought it was a good idea. :P
-
Oh, it was a good idea, but thats what I'm saying. I know the log files contain joins/leaves, but I thought console already did.
Either way, whether it ever did or didn't, I'm glad it's back!