View Single Post
Author Message
llamasking
Junior Member
Join Date: Jul 2020
Old 11-03-2020 , 13:11   [ANY] Private Analytics (v1.0.2, 2021-12-29)
Reply With Quote #1

Description
An alternative to Dr. McKay's Player Analytics that logs much less identifiable information.

The following data is logged on initial connection, very simiilarly to Player Analytics (even uses the same table and column names)
- Server's IP
- Time
- Player Count (inclusive)
- Map
- Player's Country
- HTML motd status

The player's name, ID, IP, flags, duration in the server, city, premium status, and OS are not logged.

The plugin also creates a new table called player_count which logs the player count whenever a connection/disconnection occurs. It's meant to be used for graphing player counts, such as in Grafana.

Conversion
A table of connections logged with Player Analytics can be easily converted for use with this plugin. Simply delete all but the following columns:
- id
- server_ip
- connect_time
- numplayers
- map
- country
- country_code
- country_code3
- html_motd_disabled

ConVars
  • sm_analytics_html - Whether or not to record if HTML motds are on or off. (Default: Off)
  • sm_analytics_version - Plugin version.

Dependencies
  • [Optional] Updater - Automatic updates.

Changelog
Quote:
v1.0.2 (2022-12-29)
- Fix a 'Client X is not connected' exception.

v1.0.1 (2021-05-30)
- Fixed player counts only the first digit
- Increase max length of a country name to 63 characters
- Better string sanitization (See note above)
- General optimization

v1.0.0 (2020-11-03)
- Initial release
Credits
  • Dr. McKay / Bara / sneaK - Created / Updated the original Player Analytics, the original inspiration for this plugin. I also reused a little bit of code in the server ip detection.

Note: Due to the Updater requirement, "Get Plugin" doesn't work. Please use the attached .smx file.
Attached Files
File Type: sp Get Plugin or Get Source (private_analytics.sp - 38 views - 7.0 KB)
File Type: smx private_analytics.smx (5.7 KB, 46 views)
__________________

Last edited by llamasking; 12-29-2022 at 04:53.
llamasking is offline