|
Player12
An open source football management simulator
|
Functions | |
| const char * | nameKey (SquadStatus status) |
| const char * | expectationKey (SquadStatus status) |
| SquadRole | toSquadRole (SquadStatus status) |
| SquadStatus | expectation (SquadStatus assigned, SquadStatus deserved) |
| SquadStatus | deserved (std::size_t rank, int age) |
| float | moraleOffset (SquadStatus assigned, SquadStatus deserved, float ambition) |
Variables | |
| constexpr int | PROSPECT_MAX_AGE = 21 |
| SquadStatus SquadStatusModel::deserved | ( | std::size_t | rank, |
| int | age | ||
| ) |
Status a player's ability rank in his squad earns (0 = best), as the player himself sees it: top 3 Star, then Important (4-6), Regular (7-11), Rotation (12-16); beyond, young players are prospects and the rest backups.
| SquadStatus SquadStatusModel::expectation | ( | SquadStatus | assigned, |
| SquadStatus | deserved | ||
| ) |
Status whose minutes a player expects once the manager gave him assigned: the assigned one, but never more than one level below what his ability rank earns in his eyes (deserved). A promotion raises the expectation; a demotion only lowers it a little and is resented on its own (moraleOffset()).
| const char * SquadStatusModel::expectationKey | ( | SquadStatus | status | ) |
One-line playing-time expectation of status (language key).
| float SquadStatusModel::moraleOffset | ( | SquadStatus | assigned, |
| SquadStatus | deserved, | ||
| float | ambition | ||
| ) |
Weekly morale target offset (negative) when the manager gives a player a status clearly below the one he believes he deserves: nothing within one level, then -4 per extra level, scaled by ambition (clamped to 0.75-1.5, so even modest players resent a clear demotion). A status above his standing costs nothing here but raises the minutes he expects.
| const char * SquadStatusModel::nameKey | ( | SquadStatus | status | ) |
Language key naming status (e.g. "SQUAD_STATUS_STAR").
| SquadRole SquadStatusModel::toSquadRole | ( | SquadStatus | status | ) |
Playing-time expectation of a status.
|
inlineconstexpr |
Age up to which a player may be given (or suggested) Prospect status.