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

Admin logging


Post New Thread Reply   
 
Thread Tools Display Modes
MFS
AlliedModders Donor
Join Date: Dec 2010
Old 08-04-2012 , 05:28   Re: Admin logging
Reply With Quote #51

Does it work for TF2?
MFS is offline
Horsedick
AlliedModders Donor
Join Date: Sep 2011
Old 08-04-2012 , 11:22   Re: Admin logging
Reply With Quote #52

Quote:
Originally Posted by MFS View Post
Does it work for TF2?
yeah it does but as I said it needs to have a way to restrict targeting certain steamid's or flag users vs everyone under any use of SM commands
Horsedick is offline
daleGEND
AlliedModders Donor
Join Date: Feb 2005
Location: USA
Old 08-12-2012 , 19:38   Re: Admin logging
Reply With Quote #53

Has anyone looked into these errors?
Quote:
L 08/12/2012 - 190:12: [SM] Native "GetUserAdmin" reported: Client index -1 is invalid
L 08/12/2012 - 190:12: [SM] Displaying call stack trace for plugin "admin_logging_custom.smx":
L 08/12/2012 - 190:12: [SM] [0] Line 25, /home/groups/alliedmodders/forums/files/3/0/8/7/6/28025.attach::OnLogAction()
L 08/12/2012 - 1908: [SM] Native "GetUserAdmin" reported: Client index -1 is invalid
L 08/12/2012 - 1908: [SM] Displaying call stack trace for plugin "admin_logging_custom.smx":
L 08/12/2012 - 1908: [SM] [0] Line 25, /home/groups/alliedmodders/forums/files/3/0/8/7/6/28025.attach::OnLogAction()
L 08/12/2012 - 190:58: [SM] Native "GetUserAdmin" reported: Client index -1 is invalid
L 08/12/2012 - 190:58: [SM] Displaying call stack trace for plugin "admin_logging_custom.smx":
L 08/12/2012 - 190:58: [SM] [0] Line 25, /home/groups/alliedmodders/forums/files/3/0/8/7/6/28025.attach::OnLogAction()
__________________
Bor3d Gaming - A Mature Online Gaming Community

Feel free to add me on STEAM as well: https://steamcommunity.com/id/b0r3d
daleGEND is offline
Pixeli
Member
Join Date: Aug 2012
Old 08-28-2012 , 11:22   Re: Admin logging
Reply With Quote #54

Hello, its possible to get logs from THC RPG Plugin? can someone make it? like see who admin giving levels,credits,xp and etc
Pixeli is offline
TheHardstyleBro
Senior Member
Join Date: Jun 2012
Location: Netherlands
Old 08-28-2012 , 12:47   Re: Admin logging
Reply With Quote #55

Quote:
Originally Posted by daleGEND View Post
Has anyone looked into these errors?
Well -1 is an unconnected client. Could be rcon or console.
__________________
TheHardstyleBro is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 08-28-2012 , 13:33   Re: Admin logging
Reply With Quote #56

Quote:
Originally Posted by Horsedick View Post
yeah it does but as I said it needs to have a way to restrict targeting certain steamid's or flag users vs everyone under any use of SM commands
The problem here is that CheckCommandAccess/CheckAccess only check users that have all the flags you specify. It's a bit trickier to add support to log commands of admins who have any of a specific list of flags.

Quote:
Originally Posted by daleGEND View Post
Has anyone looked into these errors?
admin_logging_custom doesn't check if the client is -1 or 0 before attempting to get the user's admin ID. -1 and 0 are both documented client values of OnLogAction when the admin is either not applicable (-1) or the server console (0), but aren't valid client IDs.

This is apparently a bug introduced into the custom version, as the version in the first post doesn't have this bug.

The fix is to split the two checks up, as attached.
Attached Files
File Type: sp Get Plugin or Get Source (admin_logging_custom.sp - 232 views - 1.9 KB)
__________________
Not currently working on SourceMod plugin development.

Last edited by Powerlord; 08-28-2012 at 13:43.
Powerlord is offline
daleGEND
AlliedModders Donor
Join Date: Feb 2005
Location: USA
Old 08-28-2012 , 15:02   Re: Admin logging
Reply With Quote #57

Quote:
Originally Posted by Powerlord View Post
The problem here is that CheckCommandAccess/CheckAccess only check users that have all the flags you specify. It's a bit trickier to add support to log commands of admins who have any of a specific list of flags.



admin_logging_custom doesn't check if the client is -1 or 0 before attempting to get the user's admin ID. -1 and 0 are both documented client values of OnLogAction when the admin is either not applicable (-1) or the server console (0), but aren't valid client IDs.

This is apparently a bug introduced into the custom version, as the version in the first post doesn't have this bug.

The fix is to split the two checks up, as attached.
Thank you!
__________________
Bor3d Gaming - A Mature Online Gaming Community

Feel free to add me on STEAM as well: https://steamcommunity.com/id/b0r3d
daleGEND is offline
daleGEND
AlliedModders Donor
Join Date: Feb 2005
Location: USA
Old 08-28-2012 , 19:16   Re: Admin logging
Reply With Quote #58

Odd, it doesn't seem to be logging anything lol.
__________________
Bor3d Gaming - A Mature Online Gaming Community

Feel free to add me on STEAM as well: https://steamcommunity.com/id/b0r3d
daleGEND is offline
NameUser
Senior Member
Join Date: Apr 2012
Location: Bay Area, California
Old 08-28-2012 , 19:31   Re: Admin logging
Reply With Quote #59

Quote:
Originally Posted by daleGEND View Post
Odd, it doesn't seem to be logging anything lol.
Yeah, it's not working for me either...
__________________
NameUser is offline
Send a message via Skype™ to NameUser
gH0sTy
SourceMod Donor
Join Date: Jul 2008
Location: DE
Old 08-29-2012 , 04:25   Re: Admin logging
Reply With Quote #60

Quote:
Originally Posted by daleGEND View Post
Has anyone looked into these errors?
You're probably using an outdated version as line 25 checks if the client is > 0 before attempting to get the admin ID.

Quote:
Originally Posted by Powerlord View Post
admin_logging_custom doesn't check if the client is -1 or 0 before attempting to get the user's admin ID...
Incorrect, read above.

Quote:
Originally Posted by Horsedick View Post
yeah it does but as I said it needs to have a way to restrict targeting certain steamid's or flag users vs everyone under any use of SM commands
Try the attached version, it will create a sm_admin_logging.cfg file where you can set the flag(s) you want to log.
Attached Files
File Type: sp Get Plugin or Get Source (admin_logging_custom.sp - 905 views - 2.6 KB)
gH0sTy is offline
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 05:50.


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