Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed SimHockey.exe
Binary file not shown.
23 changes: 20 additions & 3 deletions _util/statsutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,36 @@ func GetCHLPlayerHeaderRows() []string {
}
}

func GetExpansionPHLPlayerHeaderRows() []string {
return []string{
"ID", "First Name", "Last Name", "Position",
"Archetype", "Year", "Team", "Division", "Height", "Weight", "City", "Region", "Country", "Age", "Overall",
"Agility", "Faceoffs", "Long Shot Accuracy", "Long Shot Power", "Close Shot Accuracy",
"Close Shot Power", "Passing", "Puck Handling", "Strength", "Body Checking", "Stick Checking",
"Shot Blocking", "Goalkeeping", "Goalie Vision", "Stamina", "Injury Rating",
"Goals", "Assists", "Points", "+/-",
"Penalty Minutes", "Even Strength Goals", "Even Strength Points", "Power Play Goals",
"Power Play Points", "Shorthanded Goals", "Shorthanded Points", "Overtime Goals",
"Game Winning Goals", "Shots", "Shooting Percentage", "Time One Ice",
"Faceoff Win Percentage", "Faceoffs Won", "Faceoffs", "Goalie Wins",
"Goalie Losses", "Goalie Ties", "OT Losses", "Shots Against",
"Saves", "Goals Against", "Save Percentage", "Shutouts",
"Shots Blocked", "Body Checks", "Stick Checks",
}
}

func GetPHLPlayerHeaderRows() []string {
return []string{
"ID", "First Name", "Last Name", "Position",
"Archetype", "Year", "Team", "Division", "Age", "Stars",
"Archetype", "Year", "Team", "Division", "Age", "Overall",
"Goals", "Assists", "Points", "+/-",
"Penalty Minutes", "Even Strength Goals", "Even Strength Points", "Power Play Goals",
"Power Play Points", "Shorthanded Goals", "Shorthanded Points", "Overtime Goals",
"Game Winning Goals", "Shots", "Shooting Percentage", "Time One Ice",
"Faceoff Win Percentage", "Faceoffs Won", "Faceoffs", "Goalie Wins",
"Goalie Losses", "Goalie Ties", "OT Losses", "Shots Against",
"Saves", "Goals Against", "Save Percentage", "Shutouts",
"Shots Blocked", "Body Checks", "Stick Checks", "Injured?",
"Injury", "Injury Severity", "Will play for the National Antarctic Team at the first chance when they join the hockey sim?",
"Shots Blocked", "Body Checks", "Stick Checks",
}
}

Expand Down
2 changes: 1 addition & 1 deletion controllers/CronController.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func SyncRecruitingViaCron() {
if !ts.RunCron {
return
}
if !ts.CrootsGenerated && !ts.IsDraftTime && (ts.IsOffSeason || ts.IsPreseason) {
if !ts.IsDraftTime && (ts.IsOffSeason || ts.IsPreseason) {
managers.RefillCHLRosters()
managers.ResetScoutingProfilesForRecruiting()
}
Expand Down
20 changes: 15 additions & 5 deletions controllers/MigrationController.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,35 @@ func FixSeasonStatTables(w http.ResponseWriter, r *http.Request) {

func FixStandingsTables(w http.ResponseWriter, r *http.Request) {
managers.FixStandingsTables()
json.NewEncoder(w).Encode("Recruiting Sync Complete")
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func ImportPHLDraftOrder(w http.ResponseWriter, r *http.Request) {
managers.ImportPhlDraftOrder()
json.NewEncoder(w).Encode("Recruiting Sync Complete")
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func FixDraftablePlayersTable(w http.ResponseWriter, r *http.Request) {
managers.FixDraftablePlayersTable()
json.NewEncoder(w).Encode("Recruiting Sync Complete")
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func FixAddingCroots(w http.ResponseWriter, r *http.Request) {
managers.FixAddingRecruitsToCollege()
json.NewEncoder(w).Encode("Recruiting Sync Complete")
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func FixAddingRookieContracts(w http.ResponseWriter, r *http.Request) {
managers.FixRookieContracts()
json.NewEncoder(w).Encode("Recruiting Sync Complete")
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func ExtendPHLPlayers(w http.ResponseWriter, r *http.Request) {
managers.ExtendPHLPlayers()
json.NewEncoder(w).Encode("Fix Sync Complete")
}

func FixSimPHLRetiredPlayers(w http.ResponseWriter, r *http.Request) {
managers.FixSimPHLRetiredPlayers()
json.NewEncoder(w).Encode("Fix Sync Complete")
}
19 changes: 19 additions & 0 deletions controllers/StatsController.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,25 @@ func GetProStatsPageContent(w http.ResponseWriter, r *http.Request) {
json.NewEncoder(w).Encode(response)
}

func ExportExpansionPlayerSheet(w http.ResponseWriter, r *http.Request) {
enableCors(&w)
vars := mux.Vars(r)
seasonID := vars["seasonID"]
viewType := vars["viewType"]
weekID := vars["weekID"]
gameType := vars["gameType"]

if len(viewType) == 0 {
panic("User did not provide view type")
}

if len(seasonID) == 0 {
panic("User did not provide TeamID")
}

managers.ExportSeasonalProStatsForExpansion(seasonID, weekID, viewType, gameType, w)
}

func ExportProStatsPageContent(w http.ResponseWriter, r *http.Request) {
enableCors(&w)
vars := mux.Vars(r)
Expand Down
6 changes: 6 additions & 0 deletions data/2027/gen/simchl_expansion_teams_acha.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Sim College Hockey Teams,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
id,Team Name,Mascot,Abbreviation,LeagueID,Conference ID,Conference,Coach (All schools are AI unless noted),City,State,Country,ArenaID,Arena,Arena Capacity,Record Attendance,First Played,Discord ID,Color One,Color Two,Color Three,Overall Grade,Offense Grade,Defense Grade,IsClub,IsActive,Players Progressed,Program,Prof. Development,Traditions,Facilities,Atmosphere,Coach Reputation,Academic Prestige
119,Maryville,Saints,MARY,1,7,Independent,AI,Chesterfield,MO,USA,175,Maryville Univercity Hockey Center,2000,0,2027,,#003263,#C9CBCC,#FFFFFF,,,,1,1,0,1,1,1,2,2,1,2
120,South Dakota State,Jackrabbits,SDST,1,7,Independent,AI,Brookings,SD,USA,176,Larson Ice Center,2600,0,2027,,#FFC425,#B0B7BC,#FFFFFF,,,,1,1,0,1,1,1,1,1,1,1
121,Florida Gulf Coast,Eagles,FGCU,1,7,Independent,AI,Fort Myers,FL,USA,177,Hertz Arena,7084,0,2027,,#002D72,#007749,#B9975B,,,,1,1,0,1,1,1,1,1,1,1
122,Oklahoma State,Cowboys,OKST,1,7,Independent,AI,Stillwater,OK,USA,178,WeStreet Ice Center,1000,0,2027,,#FF7300,#000000,#FFFFFF,,,,1,1,0,1,1,1,1,1,1,1
5 changes: 5 additions & 0 deletions data/gen/phl_teams_expansion_one.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
id,Team Name,Mascot,Abbreviation,Conference ID,Conference,Division ID,Division,Owner,GM,Coach,Scout,Marketing Officer (MO),City,State,Country,ArenaID,Arena,Arena Capacity,Record Attendance,First Played,Discord ID,Color One,Color Two,Color Three,Overall Grade,Offense Grade,Defense Grade,IsClub,IsActive,Players Progressed
25,Boston,Bruins,BOS,1,Eastern,1,Atlantic,,,,,,Boston,MA,USA,67,TD Garden,17850,0,2027,,#FFB81C,#000000,#FFFFFF,,,,,,
26,Buffalo,Sabres,BUF,1,Eastern,2,Metro,,,,,,Buffalo,NY,USA,68,KeyBank Center,19070,0,2027,,#003087,#FFB81C,#FFFFFF,,,,,,
27,Columbus,Blue Jackets,CBJ,1,Eastern,2,Metro,,,,,,Columbus,OH,USA,76,Nationwide Arena,18144,0,2027,,#002654,#ce1126,#A4A9AD,,,,,,
28,Edmonton,Oilers,EDM,2,Western,4,Pacific,,,,,,Edmonton,AB,Canada,93,Rogers Place,18347,0,2027,,#041E42,#FF4C00,#FFFFFF,,,,,,
20 changes: 20 additions & 0 deletions data/unique_male_names_by_country.json
Original file line number Diff line number Diff line change
Expand Up @@ -12609,6 +12609,10 @@
"Joe",
"Randy",
"Johnathan",
"Jean-Luc",
"John-Luke",
"Jean-Lucas",
"Jon-Luc",
"Gerald",
"Glenn",
"Drew",
Expand Down Expand Up @@ -13224,8 +13228,24 @@
"Mejia",
"Barber",
"Bradshaw",
"Ryan",
"Kallik",
"Kaliq",
"MacBeersen",
"Hicks",
"Berry",
"Vaughn",
"Sinclair",
"Fontaine",
"Phontayne",
"MacJohnson",
"MacLayne",
"Wayne",
"Waynderson",
"Cardinal",
"Laurier",
"Diefenbaker",
"Wurstenbaker",
"Warner",
"Hensley",
"Matthews",
Expand Down
19 changes: 16 additions & 3 deletions engine/gamestructs.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package engine

import (
util "github.com/CalebRose/SimHockey/_util"
"github.com/CalebRose/SimHockey/structs"
)

Expand Down Expand Up @@ -208,7 +209,7 @@ func (gs *GameState) SetPuckBearer(player *GamePlayer, isLongerPass bool) {
gs.ResetMomentum()
gs.AssistingPlayer = &GamePlayer{}
} else {
gs.Momentum += 0.175
gs.Momentum += gs.GetMomentumBonus()
if isLongerPass {
gs.Momentum += .05
}
Expand All @@ -221,12 +222,24 @@ func (gs *GameState) SetPuckBearer(player *GamePlayer, isLongerPass bool) {
}
}

func (gs *GameState) GetMomentumBonus() float64 {
floor := 0.2
ceiling := gs.PuckCarrier.PassMod / 5
if floor > ceiling {
temp := floor
floor = ceiling
ceiling = temp
}

return util.GenerateFloatFromRange(floor, ceiling)
}

func (gs *GameState) TriggerBreakaway() {
gs.Momentum += 0.325
gs.Momentum += 0.75
}

func (gs *GameState) ResetMomentum() {
gs.Momentum = 0
gs.Momentum = -0.75
}

func (gs *GameState) GetCenter(isHome bool) *GamePlayer {
Expand Down
7 changes: 7 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ func handleRequests() http.Handler {
// apiRouter.HandleFunc("/admin/sync/week/", controllers.SyncToNextWeek).Methods("GET")
// // apiRouter.HandleFunc("/admin/assign/ranks/", controllers.AssignAllRecruitRanks).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/test/college/teams/", controllers.GenerateCollegeTeams).Methods("GET")
// apiRouter.HandleFunc("/admin/import/phl/teams/", controllers.GenerateProTeams).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/init/college/rosters/", controllers.GenerateInitialRosters).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/chl/rosters/", controllers.GenerateCHLRosters).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/college/recruits/", controllers.GenerateCroots).Methods("GET")
Expand All @@ -91,6 +92,7 @@ func handleRequests() http.Handler {
// apiRouter.HandleFunc("/admin/generate/phl/playoff/games/", controllers.GenerateProPlayoffGames).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/pairwise/ranks/", controllers.GeneratePairwiseRanks).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/phl/draft/warrooms/", controllers.GeneratePHLDraftWarRooms).Methods("GET")
// apiRouter.HandleFunc("/admin/season/migration/", controllers.SeasonMigration).Methods("GET")

// apiRouter.HandleFunc("/admin/generate/pre/schedule/", controllers.GeneratePreseasonGames).Methods("GET")
// apiRouter.HandleFunc("/admin/generate/canada/schedule/", controllers.GenerateCanadaGames).Methods("GET")
Expand All @@ -104,6 +106,10 @@ func handleRequests() http.Handler {
// apiRouter.HandleFunc("/simhck/fix/standings/tables/", controllers.FixStandingsTables).Methods("GET")
// apiRouter.HandleFunc("/simhck/fix/missing/rookie/contracts/", controllers.FixAddingRookieContracts).Methods("GET")
// apiRouter.HandleFunc("/simhck/fix/postseason/tournament/", controllers.PrepareCHLPostSeasonGamesFormat).Methods("GET")
// apiRouter.HandleFunc("/simhck/fix/graduated/pro/players/", controllers.FixGraduatedProPlayers).Methods("GET")
// apiRouter.HandleFunc("/simhck/add/retirement/age/", controllers.AddRetirementAge).Methods("GET")
// apiRouter.HandleFunc("/simhck/extend/phl/players/", controllers.ExtendPHLPlayers).Methods("GET")
// apiRouter.HandleFunc("/simhck/fix/sim/phl/retired/players/", controllers.FixSimPHLRetiredPlayers).Methods("GET")

// Run
// apiRouter.HandleFunc("/admin/run/fa/sync/", controllers.TestFASync).Methods("GET")
Expand Down Expand Up @@ -145,6 +151,7 @@ func handleRequests() http.Handler {
apiRouter.HandleFunc("/export/pro/freeagents", controllers.ExportProFreeAgents).Methods("GET")
apiRouter.HandleFunc("/export/stats/chl/{seasonID}/{weekID}/{viewType}/{gameType}", controllers.ExportCHLStatsPageContentForSeason).Methods("GET")
apiRouter.HandleFunc("/export/stats/phl/{seasonID}/{weekID}/{viewType}/{gameType}", controllers.ExportProStatsPageContent).Methods("GET")
apiRouter.HandleFunc("/export/stats/phl/expansion/{seasonID}/{weekID}/{viewType}/{gameType}", controllers.ExportExpansionPlayerSheet).Methods("GET")
apiRouter.HandleFunc("/games/export/results/{seasonID}/{weekID}/{timeslot}", controllers.ExportHCKGameResults).Methods("GET")
apiRouter.HandleFunc("/games/result/export/chl/{gameID}", controllers.ExportCollegePlayByPlayResults).Methods("GET")
apiRouter.HandleFunc("/games/result/export/phl/{gameID}", controllers.ExportProPlayByPlayResults).Methods("GET")
Expand Down
61 changes: 57 additions & 4 deletions managers/CSVManager.go
Original file line number Diff line number Diff line change
Expand Up @@ -903,6 +903,59 @@ func ExportCollegeStats(seasonID, weekID, viewType, gameType string, w http.Resp
})
}

func ExportSeasonalProStatsForExpansion(seasonID, weekID, viewType, gameType string, w http.ResponseWriter) {
stats := SearchProStats(seasonID, weekID, viewType, gameType)
seasonStatMap := MakeProPlayerSeasonStatMap(stats.PHLPlayerSeasonStats)
seasonIDNum := util.ConvertStringToInt(seasonID)
seasonIDNum += 2024
seasonStr := strconv.Itoa(seasonIDNum)
baseName := fmt.Sprintf("phl_seasonal_stats_%s", seasonStr)

w.Header().Set("Content-Type", "application/zip")
w.Header().Set("Content-Disposition", fmt.Sprintf("attachment; filename=\"%s.zip\"", baseName))
w.Header().Set("Transfer-Encoding", "chunked")
zipWriter := zip.NewWriter(w)
defer zipWriter.Close()

fileName := "expansion_phl_player_stats_" + seasonStr + ".csv"
proPlayers := repository.FindAllProPlayers(repository.PlayerQuery{})
phlTeamMap := GetProTeamMap()

writeCSVIntoZip(zipWriter, fileName, func(csvW *csv.Writer) error {
header := util.GetExpansionPHLPlayerHeaderRows()
if err := csvW.Write(header); err != nil {
return err
}

for _, p := range proPlayers {
team := phlTeamMap[uint(p.TeamID)]
seasonStats := seasonStatMap[p.ID]
row := []string{
strconv.Itoa(int(p.ID)), p.FirstName, p.LastName, p.Position,
p.Archetype, strconv.Itoa(p.Year), p.Team, team.Division, strconv.Itoa(int(p.Height)), strconv.Itoa(int(p.Weight)), p.City, p.State, p.Country, strconv.Itoa(int(p.Age)), strconv.Itoa(int(p.Overall)),
strconv.Itoa(int(p.Agility)), strconv.Itoa(int(p.Faceoffs)), strconv.Itoa(int(p.LongShotAccuracy)), strconv.Itoa(int(p.LongShotPower)), strconv.Itoa(int(p.CloseShotAccuracy)),
strconv.Itoa(int(p.CloseShotPower)), strconv.Itoa(int(p.Passing)), strconv.Itoa(int(p.PuckHandling)), strconv.Itoa(int(p.Strength)), strconv.Itoa(int(p.BodyChecking)), strconv.Itoa(int(p.StickChecking)),
strconv.Itoa(int(p.ShotBlocking)), strconv.Itoa(int(p.Goalkeeping)), strconv.Itoa(int(p.GoalieVision)), strconv.Itoa(int(p.Stamina)), strconv.Itoa(int(p.InjuryRating)),
strconv.Itoa(int(seasonStats.Goals)), strconv.Itoa(int(seasonStats.Assists)), strconv.Itoa(int(seasonStats.Points)), strconv.Itoa(int(seasonStats.PlusMinus)),
strconv.Itoa(int(seasonStats.PenaltyMinutes)), strconv.Itoa(int(seasonStats.EvenStrengthGoals)), strconv.Itoa(int(seasonStats.EvenStrengthPoints)), strconv.Itoa(int(seasonStats.PowerPlayGoals)),
strconv.Itoa(int(seasonStats.PowerPlayPoints)), strconv.Itoa(int(seasonStats.ShorthandedGoals)), strconv.Itoa(int(seasonStats.ShorthandedPoints)), strconv.Itoa(int(seasonStats.OvertimeGoals)),
strconv.Itoa(int(seasonStats.GameWinningGoals)), strconv.Itoa(int(seasonStats.Shots)), strconv.FormatFloat(float64(seasonStats.ShootingPercentage), 'f', 2, 64), strconv.Itoa(int(seasonStats.TimeOnIce)),
strconv.FormatFloat(float64(seasonStats.FaceOffWinPercentage), 'f', 2, 64), strconv.Itoa(int(seasonStats.FaceOffsWon)), strconv.Itoa(int(seasonStats.FaceOffs)), strconv.Itoa(int(seasonStats.GoalieWins)),
strconv.Itoa(int(seasonStats.GoalieLosses)), strconv.Itoa(int(seasonStats.GoalieTies)), strconv.Itoa(int(seasonStats.OvertimeLosses)), strconv.Itoa(int(seasonStats.ShotsAgainst)),
strconv.Itoa(int(seasonStats.Saves)), strconv.Itoa(int(seasonStats.GoalsAgainst)), strconv.FormatFloat(float64(seasonStats.SavePercentage), 'f', 2, 64), strconv.Itoa(int(seasonStats.Shutouts)),
strconv.Itoa(int(seasonStats.ShotsBlocked)), strconv.Itoa(int(seasonStats.BodyChecks)), strconv.Itoa(int(seasonStats.StickChecks)),
}
err := csvW.Write(row)
if err != nil {
return err
}
}

csvW.Flush()
return csvW.Error()
})
}

func ExportProStats(seasonID, weekID, viewType, gameType string, w http.ResponseWriter) {
stats := SearchProStats(seasonID, weekID, viewType, gameType)
seasonIDNum := util.ConvertStringToInt(seasonID)
Expand All @@ -912,7 +965,7 @@ func ExportProStats(seasonID, weekID, viewType, gameType string, w http.Response
if viewType != "SEASON" && (weekID != "" && weekID != "0") {
weekNum := util.ConvertStringToInt(weekID)
weekNum = weekNum - 2500
weekStr = "WEEK_" + strconv.Itoa(weekNum) + "_"
weekStr = "_WEEK_" + strconv.Itoa(weekNum) + "_"
}
baseName := fmt.Sprintf("phl_stats_%s_%s", seasonStr, viewType)
w.Header().Set("Content-Type", "application/zip")
Expand All @@ -921,8 +974,8 @@ func ExportProStats(seasonID, weekID, viewType, gameType string, w http.Response
zipWriter := zip.NewWriter(w)
defer zipWriter.Close()
// Initialize writer
fileName := "phl_player_stats_" + seasonStr + "_" + weekStr + ".csv"
teamFileName := "phl_team_stats_" + seasonStr + "_" + weekStr + ".csv"
fileName := "phl_player_stats_" + seasonStr + weekStr + ".csv"
teamFileName := "phl_team_stats_" + seasonStr + weekStr + ".csv"

proPlayers := repository.FindAllProPlayers(repository.PlayerQuery{})
historicProPlayers := repository.FindAllHistoricProPlayers()
Expand Down Expand Up @@ -959,7 +1012,7 @@ func ExportProStats(seasonID, weekID, viewType, gameType string, w http.Response
timeOnIce := FormatTimeToClock(uint16(stat.TimeOnIce))

pr := []string{strconv.Itoa(int(p.ID)), p.FirstName, p.LastName, p.Position,
p.Archetype, strconv.Itoa(p.Year), p.Team, team.Division, strconv.Itoa(int(p.Age)), strconv.Itoa(int(p.Stars)),
p.Archetype, strconv.Itoa(p.Year), p.Team, team.Division, strconv.Itoa(int(p.Age)), strconv.Itoa(int(p.Overall)),
strconv.Itoa(int(stat.Goals)), strconv.Itoa(int(stat.Assists)), strconv.Itoa(int(stat.Points)), strconv.Itoa(int(stat.PlusMinus)),
strconv.Itoa(int(stat.PenaltyMinutes)), strconv.Itoa(int(stat.EvenStrengthGoals)), strconv.Itoa(int(stat.EvenStrengthPoints)), strconv.Itoa(int(stat.PowerPlayGoals)),
strconv.Itoa(int(stat.PowerPlayPoints)), strconv.Itoa(int(stat.ShorthandedGoals)), strconv.Itoa(int(stat.ShorthandedPoints)), strconv.Itoa(int(stat.OvertimeGoals)),
Expand Down
4 changes: 2 additions & 2 deletions managers/FreeAgencyManager.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func GetContractMap() map[uint]structs.ProContract {
}

func GetExtensionMap() map[uint]structs.ExtensionOffer {
extensions := repository.FindAllProExtensions(true)
extensions := repository.FindAllProExtensions(true, false)
return MakeExtensionMap(extensions)
}

Expand Down Expand Up @@ -503,7 +503,7 @@ func SyncExtensionOffers() {
proPlayerMap := MakeProfessionalPlayerMapByTeamID(professionalPlayers)
phlTeams := GetAllProfessionalTeams()
phlTeamMap := MakeProTeamMap(phlTeams)
extensions := repository.FindAllProExtensions(true)
extensions := repository.FindAllProExtensions(true, false)
extensionMap := MakeExtensionMap(extensions)
proContracts := repository.FindAllProContracts(true)
contractMap := MakeContractMap(proContracts)
Expand Down
4 changes: 2 additions & 2 deletions managers/GenerationManager.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ func GenerateInitialRosters() {
pickedEthnicity: "",
}
for _, team := range teams {
if team.ID < 73 || team.LeagueID == 2 {
if team.ID < 118 || team.LeagueID == 2 {
continue
}
teamID := team.ID
Expand Down Expand Up @@ -1223,7 +1223,7 @@ func createRecruit(position, arch string, stars int, firstName, lastName string,
HasProgressed: false,
BaseInjuryData: injuryData,
}

basePlayer.RetirementAge = basePlayer.PrimeAge + uint8(util.GenerateIntFromRange(4, 7))
basePlayer.GetOverall()

return structs.Recruit{
Expand Down
Loading
Loading