Player12
An open source football management simulator
Loading...
Searching...
No Matches
SeasonReviewModel Namespace Reference

The board's season-end verdict and the season-end news. More...

Classes

struct  EventNames
 

Functions

SeasonVerdictResult judge (const SeasonVerdictInputs &inputs)
 
const char * verdictKey (SeasonVerdict verdict)
 
const char * gradeKey (ObjectiveGrade grade)
 
void postEvents (Inbox &inbox, const GameDateValue &date, const SeasonReview &review, const EventNames &names)
 

Variables

constexpr int MIN_MATCHES_TO_JUDGE = 12
 
constexpr float SACK_CONFIDENCE = 25.0f
 
constexpr int SURVIVAL_MARGIN = 3
 

Detailed Description

The board's season-end verdict and the season-end news.

Function Documentation

◆ gradeKey()

const char * SeasonReviewModel::gradeKey ( ObjectiveGrade  grade)

◆ judge()

SeasonVerdictResult SeasonReviewModel::judge ( const SeasonVerdictInputs &  inputs)

Judges a season against the board's objectives. The league finish weighs most; cup, finances and youth add or take away (when the board set them for the season). A manager in charge for too few matches is not judged; a failed season (league target missed, or the books failed without a strong league finish) sacks him when confidence is low, when the club went down although it was not expected to fight relegation, or when he had already been warned.

◆ postEvents()

void SeasonReviewModel::postEvents ( Inbox &  inbox,
const GameDateValue &  date,
const SeasonReview &  review,
const EventNames &  names 
)

Posts the season's news for the managed club in order: champions, promotion, relegation or survival, the domestic cup, continental qualification, then the board's verdict.

◆ verdictKey()

const char * SeasonReviewModel::verdictKey ( SeasonVerdict  verdict)

Language keys (e.g. "SEASON_VERDICT_PLEASED", "SEASON_GRADE_MET").

Variable Documentation

◆ MIN_MATCHES_TO_JUDGE

constexpr int SeasonReviewModel::MIN_MATCHES_TO_JUDGE = 12
inlineconstexpr

League matches in charge before the board judges a season at all.

◆ SACK_CONFIDENCE

constexpr float SeasonReviewModel::SACK_CONFIDENCE = 25.0f
inlineconstexpr

Confidence under which a failed season costs the job.

◆ SURVIVAL_MARGIN

constexpr int SeasonReviewModel::SURVIVAL_MARGIN = 3
inlineconstexpr

Places above the drop zone that still count as a relegation fight.