- Fixed an issue where data files wouldn't save if StatTracker was loaded before or without Hostmod
- Thanks to Lighto for finding this issue
ALWAYS BACK UP YOUR DATA FILES BEFORE UPDATING
- Fixes various issues with Scorekeeper's scores not sticking in various situations.
- Thanks to Galactice, Freeman, and all of NVJR for code & testing
- Applies memory optimization to the player skin use table, all tables are now optimized.
- Adds some hard rounded percentages for various stats to st_playerdata
- Prevents time records from being saved when total time is 0 seconds
- Reported by AnimeSonic
- Fixed custom game mode pointers possibly throwing an error. (Reported by Galactice)
- Added Scorekeeper's sk_setscore function to manually set a player's score.
ALWAYS BACK UP YOUR DATA FILES BEFORE UPDATING
- Integrated Scorekeeper into StatTracker (Suggested by GC)
- This will read & write to scorekeeper.txt exactly like the original addon, so there is no need to load both StatTracker and Scorekeeper.
- Scorekeeper's record expiration feature was removed and will be re-implemented universally for all StatTracker data in a future update.
- Added admin command st_enablescorekeeper (On/Off) to toggle this feature.
- Expanded netvar usage to stop new desyncing issues
- Players who spectate before ragespec time window are now properly handled. (Reported by AnimeSonic)
- Renamed admin command "st_enablemaptracking" to "st_enablemapcounttracking" to prevent an ID conflict with Juggy's tools
ALWAYS BACK UP YOUR DATA FILES IN THE LUAFILES FOLDER BEFORE UPDATING
v2 is a major data handling rewrite as 5 months since release, data files on servers are getting larger and larger. A lot of these updates are aimed at reducing memory consumption on servers.
Load StatTracker after you load game mode mods now, see updates below for details.
Memory use reduction
Additional notes
- Loaded data is now stored as a single string instead of a nested table
- This change seems to reduce server memory use by 30-40% with larger datasets
- Placeholder data values that StatTracker detects are unused will now be removed. StatTracker will search for other gametypes that it tracks on load, and if it doesn't find some or all of them, it will remove placeholder values from data to reduce memory load.
- For servers that only run vanilla, this is a filesize reduction of 50% for time record files, and 30% for the player file.
- If you only occasionally load game modes on to your server, keep them loaded at all times, load them before StatTracker in your load order, and disable them via their respective console commands instead. StatTracker will lose/overwrite data if it does not see the game mode loaded.
- Added additional admin vars to disable individual components of StatTracker so they are not loaded and consume memory. Remember to delete the associated file from the server's luafiles folder to get the full benefit from this. All these vars are on by default.
- st_enableskintracking ON\OFF (Skincounter.txt & pSkinUse.txt)
- st_enablemaptracking ON\OFF (Mapdata.txt, not the time records.)
- st_enabletimerecordtracking ON\OFF (EasyRecords.txt & NormalRecords.txt & HardRecords.txt)
- st_enableplayertracking ON\OFF (Playerdata.txt)
- Data loading has been rewritten as loading large data sets was hanging up the client for a significant period of time. This loading time has now been almost completely removed.
- Slightly rewrote saving functions to improve their speeds.
- Added a converter for inputs from "MAPXX" format to it's numeric version for console commands.
- st_mapdata now accepts "MAPXX" as a valid command
- Added admin command st_clearmaprecord [MAPXX] to delete time records of the specified map.
- This is so you can wipe out records that have become out of date due to map updates.
- There is some validation on your input, but if you type the wrong map it's record WILL be wiped permanently, so be careful.
- Added client command st_recordsound [ON/OFF] to mute character gloat sounds on getting a new record
- Also added st_recordsound to autogenerated stattracker.cfg file
- Fixed an issue with data maintenance flag not being synced and possibly causing a one time syncfail per player.
- MapChange hook has been removed due to possible sync issues, moved to Thinkframe hook instead.
- Personal win count will now not be incremented if there's only one person playing.
- Fixes an issue where a player's local time record file was being loaded and displayed instead of the server's
- No data loss on the server occurred as a result of this bug
- Fixes an issue where a losing player below the minimum KS transfer threshold was being awarded +1 point instead of -1