UHS Build 9758 – February 11 2016
Happy birthday, Owen! This is a massive build… it’s so massive that it’s actually the largest build we’ve ever released since we did UHS Dark. It’s the first build of the new year and it took 2.5 months. We actually needed to shut down UHS for hours in order to properly deploy the build and convert all league’s existing savepoints.
The All-Star / World Cup functionality was originally supposed to be the high-light of the build and that did take the majority of the work. All-Star stuff has been overhauled from top to bottom. But that wasn’t all we had in store. We also implemented the AG skill change and introduced the new FI skill. It took a lot less time than we originally thought, so might as well push it through.
The AutoGM got a new piece of code to get them out of financial trouble and the Three-Star determination / selection received a much-needed overhaul. Just when we thought we were good to go, I got ambitious and decided to rewrite the personnel management code to make sure the AutoGM properly manages it’s players.
We also have a new WIKI page if any UHS experts feel like contributing.
New Support Method – Discord
I’m happy to be able to offer another method of getting in touch with us for support or even just general chatting: DISCORD! If you haven’t heard of Discord, it’s a fairly robust chat program that also offers voice capabilities to folks that want it. All you need to do is click this link: https://discord.gg/0mQXA3o55cioiFhW and install the Discord program.
On Discord I’m known as Stone (don’t ask… that’s just my online “persona”). While I do keep the program running, I don’t necessarily keep it open, however, you can get my attention by typing @Stone. If I still don’t respond, I might not be at my computer or have access to my phone, so the best bet then would be to send in a support ticket. I typically won’t be available by VOICE (for reasons), but I will most certainly try to respond in chat.
On the usage of the chat, since this is a fairly public forum we can lay out a bunch of rules but they can best be summarized by saying we follow Wheaton’s Law: Don’t be a jerk! No racism, prejudice, uttering threats and general douchebaggery. We can and will ban folks for abuse.
AG Skill Change
The Aggression skill was a fairly wonky skill. The higher it was, the more of a chance your player was going to get involved in a fight and not be on the ice. So for a highly skilled player, a high AG was bad as it meant he would likely be off the ice more than he’d be on. I feel a skill should be valuable if it’s higher than lower. So it’s time for a change.
Skaters: The AG skill no longer affects fights. Instead, the AG skill gives each skater a chance to change a successful check into a Big Hit. A Big Hit will now provide the team with a little momentum and will also result in the checked player losing extra energy. Big Hits are tracked under the BH statistic and will directly affect how the AG skill rerates for a skater.
Goalies: For goaltenders, the AG skill was pretty much useless since Goalies are not permitted to fight. The AG skill now gives the goaltender a chance to reduce the Scoring Chance by 1%. Saves made with a successful AG skill check will be tracked in the new AgrSv (Aggressive Saves) statistic and will directly affect how the AG skill rerates for the goaltender.
New Fighting Skill
Since the Aggression skill is now going to be focused on Big Hits and giving goalies a better chance at making saves, we needed a new stat that tells us whether a player is prone to fighting. The Fighting skill (abbreviation FI) does that. For existing players, the FI skill will match that of the AG skill. For new players the FI skill be a random 1-9 skill that does NOT count towards the player’s overall skill.
The Fighting skill is simply a measure of how likely a player will engage in a fight, so we made the decision to leave it out of the Player’s Total skill calculation… plus… we like that the total overall skill for a player is 99… adding Fighting to that would have increased that to 108 which feels a bit weird.
The Fighting skill is also not handled by rerates in the same way as the other skills. Fights engaged in at the pro, farm or junior levels all carry the same weight. The skater’s Fighting skill will rerate accordingly… if they have fewer fights last season over the previous season and the ratio meets the threshold, the FI skill will rerate down… it doesn’t matter if the skater is in the Junior, Farm or Pro league: A fight is a fight. Additionally, while other skills are impacted by the amount of time on the ice, the Fighting skill ignores Ice Time for rerate purposes.
All-Stars / World Cup functionality
The All-Star Game link is now gone and changed slightly. There is a new link that only shows up during the Regular Season under League > All-Star / International. This will take you to the new page to manage everything you need for the new All-Star / World Cup functionality.
An additional change you’ll notice is that we’ve pulled out the Add Team code for All-Star teams and placed it into the Manage All-Star screen. You are still able to create / manage your all-star teams, however, you won’t do that with the Add Team section like you would previously. In fact, once you are out of the Off-Season the Add Team functionality will be hidden / disabled since you weren’t able to add Pro, Farm or Junior teams anyway.
When your league has all-star / international games played for a given day, a link will appear on the front page alongside the Pro, Farm, Junior game results link. In fact, the All-Star scores will be the default scores loaded as it is possible to sim international games on the same game day as the other levels in your league.
When creating an all-star team that has the same name as a Country, a logo will automatically be selected for the team using the 44 country flags we have on file. If you want to use your own logo, you can upload a 250×125 sized flag/logo for your all-star team. If no flag can be found the default All-Star flag will be used.
Penalties / Scoring
If you are running a single all-star game for the season, the base scoring chance will be bumped up to 25%. If you are running a tournament, the scoring chance will remain the same as a regular game. Penalty chances for a single all-star game will be 0% (no penalties) and 1% for tournaments (minimal number of penalties).
In a single All-Star game, goalies will switch like they have in the past. The starting goalie will play the 1st and 3rd periods. The backup will play the 2nd period. In Tournaments, the Starting goalie will play all periods but will switch with the backup if the team is down by 3 goals.
All-Star Skills Competition
For single All-Star Games (as opposed to tournament / international level games), we’ve added the results of the All-Star Skills competition. All players participate in each of the competitions, however, only the top 4 for each team are shown.
Fastest Skater Competition: This uses the skater’s QK, SK and FA skills. Thanks to Jon Lau for supplying the base code that was slightly modified to fit UHS’s needs.
Accuracy Competition: This uses the SH, PC and PS skills to determine how many attempts a player needs to hit 4 targets.
Hardest Shot Competition: This uses the player’s SH and PW skills. Thanks to Jon Lau for supplying the base code that was slightly modified to fit UHS’s needs.
Breakaway Competition: This pits all 18 shooters against both goalies using the SH, PC, QK and SK skills.
AutoGM – Personnel Management Re-Write & Code Review
Yes, here we are again, messing around with the AutoGM. We’re going to keep at it until it feels just right. I’ve re-written the Free Agency Poaching, Waiver Poaching and overall player code into one Personnel Management section that will run before we get to set rosters. Once the Draft is over (or PreSeason and beyond), the AutoGM will begin to manage its players. If there are empty spots, it’ll attempt to fill them with existing players first and then hit up Free Agency and Waivers.
The AutoGM will still look at Free Agency and Waivers to see if there are any guys out there that will be good for their team, however, they’ll only do that one at a time.
The Pro Roster and Farm Roster setting code was pretty much gutted to eliminate the extraneous Free Agency and Waivers code. Makeweights WILL be created if the AutoGM lacks enough players to ice a team (less than 20 players) and there are actually still games remaining for the AutoGM to play in during the current Season Stage (PreSeason, Regular Season, Playoffs).
Overall I reviewed the entire AutoGM script with the goal of making it more efficient (less database queries and more optimized code) and smarter by pulling in projected expenses and revenue data. We are also calculating Player Salary Cap hits.
By no means, I don’t think it’s perfect and there will always be room for improvement, so if you notice anything wonky, please report it.
AutoGM – Get Out of Trouble code
I’ve added code to allow the AutoGM to sell off players to get under the Salary Cap or get out of debt (negative bank account value). The AutoGM will select a random player from their Pro Team and make a trade offer to all pro teams for cash. The value of the player is based on the player’s Total Skill + a random factor. Offers will be valid for up to three days. If the offer is not taken the AutoGM will void ALL offers and make a new one with a new random player if they’re still in debt or over the cap. Offers will not be less than $1 million.
This code will NOT run during the Off-Season. During that period the AutoGM needs to be able to move players around without freaking out about being over the cap and trying to sell off players. This code should only execute during PreSeason, Regular Season and Playoffs.
Three-Star Determination Overhaul
As most of you might know the old Three-Star determination method was to collect all the candidates, those who scored a goal, a game-winner or game-tying, a shut-out, save pct and so on and select the top three from those randomly. This method also tended to heavily favour the goaltenders. We’ve changed this to assign Star Pts based on the player’s performance in that game. The players with the three highest Star Pts will now be your Three Stars.
Players: Goal – 1pt, Assist – 0.75pt, Game-Winning Goal – 0.5pt, Game-Tying Goal – 0.5, Overtime Goal – 0.5pt, Plus-Minus – used for tiebreaking only.
Goalies: Shutout – 1pt, Goal – 1pt, Assist – 0.75pt, Saves (if Shutout) – 1pt / 14 saves, Saves (if no Shutout) – 1pt / 28 saves.
Goalies will be able to get a three-star appearance if they make lots of saves even in games where there are lots of goals… as long as two or more players don’t have multiple goals/assists. I’ve compared the point-weights to some recent NHL games and have seen that the three-star selections were fairly close to what actually were selected or could have been.
Waiver Clear Days (HOURS!)
We’ve changed the Waiver Clear Days field to now be Waiver Clear Hours to give COMs the ability to fine-tune when players can clear waivers. This field lines up with Free Agency and Contract offer fields which are also in hours. The change will be applied to any new players placed on waivers as we record the clearing time at the moment the player enters waivers.
Junior Goalie Fatigue Injuries
Junior teams will now better manage their goalies so they no longer get fatigue injuries. This doesn’t mean fatigue injuries can’t happen, in fact, goalies can play over their fatigue if they’re the backup and get subbed in because the starting goalie is getting lit up. It’s still possible, just not as likely as it happened in the past.
The wiki site is now up and running. We’ve moved our help pages and guides to the wiki and will continue to add more with time.
– Player Characteristics was moved from the UHS site to the Wiki.
– Idle Leagues / Deletion page was moved from the UHS site to the Wiki.
– Inaugural Season Walk-through page was moved from the UHS site to the Wiki.
– added new page for All-Star Games & International Tournaments.
– Updated Player Characteristics with new information for Aggression (AG) and Fighting (FI) skills.
– Added an article on Player Rerates and a step-by-step walk-through of the rerate formula.
Bug Fixes & Miscellaneous Changes
– Links to the Guides & Walkthroughs have been replaced with links to the UHS Wiki: http://wiki.hockeysim.ca.
– Fixed an issue that was causing Debug Output files to be incorrectly formatted.
– Fixed an issue that caused an error to be displayed when deleted All-Star teams.
– Fixed an issue where newly added Status Messages were appearing as -196 seconds ago.
– Fixed an issue where Draft Picks could not be found in Entry Drafts for Season 2 and beyond when using the Make All Picks function.
– Fixed an issue where the Home player’s name would be used in the Live Game Penalty Summary when an Away player received a penalty due to injuring a player.
– Fixed an issue where unplayed games were not appearing on the Schedule page for Public Websites.
– RFA players owned by Teams becoming defunct will now correctly become UFAs.
– 172 Last Names and 41 First Names were added to the player pool from the 2016 World Junior Championships. UHS now has 1260 first names and 5929 last name-country combinations for a total of 7,470,540 name combinations.
– Fixed an issue where the rerate code was a little bit off from the intended calculations / formula.
– The AutoGM will now only send offers to players with expired contracts if their skill is 80% of the team’s highest skilled player. Previously this was set to 75%.
– Fixed an issue where selecting Make All Picks would incorrectly use the serpentine method for entry drafts.
– The Build History is now located under About UHS.
– Made some css tweaks to make the profile of buttons smaller.
– Made some css tweaks to decrease the height of the UHS navigation bar.
– Replaced the UHS Build link in the login panel with the league’s Database Name.
– Fixed an issue where it was possible to make free agent offers to players that were retired.
– The Last Wage column has been removed from the COM view of the Team roster.
– Fixed an issue where the player options were not appearing for Farm or Junior teams in the COM view of the Team Roster.
– Removed the Farm Team: ## text from appearing on the COM view of the Team Roster. This was being used for debugging.
– Added a TOT column to the COM Team Roster to show the total number of players on the team.
– Fixed an issue where the AutoGM wouldn’t pull back correct TeamStandings data when performing Player Release functions. Released on November 16 2015.
– Fixed an issue (I think) where the AutoGM was releasing all players. Not sure why this was happening, however, I did see the AutoGM job hanging for one league. I added in some extra code to ensure player/team arrays are fresh for each Release check. Released on November 17 2015.
– Fixed an issue where the AutoGM was not making contract offers to players with expiring contracts. This relates directly to the problem “fixed” on November 17… players were not being offered new contracts so they were all released once free agency began. Released on November 20 2015.
– Fixed an issue where the AutoGM would hang in a very specific set of circumstances (affected only one league) when setting the team’s game roster. This would result in players being bought out incorrectly and also caused game roster errors within the sim engine. Released on November 20 2015.
– Added an additional check for roster positions where the PlayerID is 0. This results in errors when the game is about to be simmed. Released on November 21 2015.
– Fixed an issue where Trades involving other teams were not being voided if the players/picks were being offered to the AutoGM. Released on November 24 2015.
– Fixed an issue where creating unassigned players in a relegation league would result in the players not appearing in Free Agency. Released on November 25 2015.
– Fixed an issue where the AutoGM was not making Entry Draft selections. Released on November 26 2015.
– Fixed an issue where the AutoGM was signing Free Agents and then immediately buy them out. AutoGMs will no longer buy-out players that are on the first year of their contract with the team. Released on November 29 2015.
– Fixed an issue where GMs making a Coach Free Agent offer would receive a message saying they already made an offer in X number of hours even though an offer had not been made. Released on December 3 2015.
– Released code to prevent the AutoGM from running for teams (and their applicable farm teams) if there are games queued. Released on December 14 2015.
– Fixed an issue where Incoming trades could potentially put AutoGMs over the Salary Cap or under the Salary Minimum. Released on December 15 2015.
– Released code to allow AutoGMs from Relegation leagues to make more than 5 Free Agent offers during the Off-Season so that they can fill their rosters. Released on December 31 2015.
– Fixed an issue where clicking the UHS Wiki link would make the Wiki page show in a super short frame. Released on January 14 1016.
– Released code to clean up issues where the AutoGM could crash the Free Agency tables… this resulted in some Free Agents not being able to be signed. Released on January 21 2016.
– Added further checks on SavePoint names to ensure illegal characters can’t be used. Released on January 23 2016.
– Released a change to limit AutoGMs to only look at the top 5 free agent coaches instead of everyone that is better than their current coach. Released on January 26 2016.
– Fixed an issue where the AutoGM could ignore player and pick ownership for incoming trades. Released on January 31 2016.
– Added further limits on the AutoGM and free agency: if the AutoGM’s team salary cannot support even one player at the minimum Salary, the AutoGM won’t bother looking at free agency at all. Released on January 31 2016.
– When the AutoGM is looking at Free Agency to fill out their team, they will pull back only the top 50 free agents instead of ALL free agents. Released on January 31 2016.
– Fixed an issue where players could remain on their team with a 0-contract if they had ever been an RFA. Released on February 8 2016.
– Fixed an issue where a team claiming a player on waivers resulted in all teams incorrectly paying the waiver fee with no ledger entry. Released on February 9 2016.