I've heard that there is a way to track a players stats (number of games played, wins / losses etc.) to a file saved on their computer which the map reads and can then use that information to setup teams or whatever else the map maker wants to do.
Can someone direct me to a tutorial or help me get this going for my map?
The functionality you are looking for is called "banks". You can save and load persistent data from them.
Be aware that banks are tied to a player's computer and not their Blizzard account and so can be subjected to tampering, reversion, deletion or corruption either unintentionally or intentionally. For this reason all stats you load from them might not reflect reality and all states have to be constrained to be at least within the map's mechanics.
At map initialization load the wins, losses and games played stats from the player bank. Increment games played by 1 and save it to the player bank. When a player either wins or loses you increment the appropriate stat and sae it to the player bank before ending the game. It really is that simple however what I said above still applies. People with negative games played you might want to clamp to 0. People with a win/loss sum greater than games played should either have all stats reset, or at least games played increased to the sum value.
I've heard that there is a way to track a players stats (number of games played, wins / losses etc.) to a file saved on their computer which the map reads and can then use that information to setup teams or whatever else the map maker wants to do.
Can someone direct me to a tutorial or help me get this going for my map?
Thanks!
The functionality you are looking for is called "banks". You can save and load persistent data from them.
Be aware that banks are tied to a player's computer and not their Blizzard account and so can be subjected to tampering, reversion, deletion or corruption either unintentionally or intentionally. For this reason all stats you load from them might not reflect reality and all states have to be constrained to be at least within the map's mechanics.
At map initialization load the wins, losses and games played stats from the player bank. Increment games played by 1 and save it to the player bank. When a player either wins or loses you increment the appropriate stat and sae it to the player bank before ending the game. It really is that simple however what I said above still applies. People with negative games played you might want to clamp to 0. People with a win/loss sum greater than games played should either have all stats reset, or at least games played increased to the sum value.
Thank you for the help!