|
Player12
An open source football management simulator
|
Staff ratings, effects, generation, wages and contracts. More...
Functions | |
| std::array< StaffAttribute, 2 > | keyAttributes (StaffRole role) |
| std::uint8_t | rating (const StaffMember &member) |
| StaffEffects | computeEffects (std::span< const StaffMember *const > staff) |
| std::uint32_t | marketWage (const StaffMember &member) |
| std::uint32_t | renewalWage (const StaffMember &member) |
| std::int64_t | severance (const StaffMember &member) |
| std::array< std::uint8_t, STAFF_ROLE_COUNT > | roleCounts (std::uint8_t reputation) |
| std::vector< StaffMember > | generateClubStaff (const Team &team, const LeagueEconomy &economy, std::uint64_t world_seed, StaffRoster &roster) |
| void | generateWorld (GameData &gamedata) |
| void | refreshMarket (GameData &gamedata, std::int32_t ordinal) |
| std::vector< std::string > | seasonEnd (GameData &gamedata, TeamID managed_team_id, std::uint16_t year) |
| float | potentialErrorSd (float scouting_accuracy) |
| const char * | roleKey (StaffRole role) |
| const char * | roleDescriptionKey (StaffRole role) |
| const char * | attributeKey (StaffAttribute attribute) |
Variables | |
| constexpr std::array< std::uint8_t, STAFF_ROLE_COUNT > | ROLE_LIMITS |
| constexpr std::size_t | MARKET_SIZE = 70 |
| constexpr double | FOOTBALL_STAFF_SHARE = 0.35 |
Staff ratings, effects, generation, wages and contracts.
| const char * StaffModel::attributeKey | ( | StaffAttribute | attribute | ) |
| StaffEffects StaffModel::computeEffects | ( | std::span< const StaffMember *const > | staff | ) |
Effects of a club's staff.
| std::vector< StaffMember > StaffModel::generateClubStaff | ( | const Team & | team, |
| const LeagueEconomy & | economy, | ||
| std::uint64_t | world_seed, | ||
| StaffRoster & | roster | ||
| ) |
Generates a club's staff: numbers and quality follow reputation, wages add up to the football-staff share of the club's non-player wages.
| void StaffModel::generateWorld | ( | GameData & | gamedata | ) |
Generates staff for every club plus the market (new worlds and saves from before staff existed).
| std::array< StaffAttribute, 2 > StaffModel::keyAttributes | ( | StaffRole | role | ) |
The two attributes that matter most for a role.
| std::uint32_t StaffModel::marketWage | ( | const StaffMember & | member | ) |
Weekly wage a member asks for on the market.
| float StaffModel::potentialErrorSd | ( | float | scouting_accuracy | ) |
Standard deviation of a scout's potential estimate in overall points: the youth potential spread (9) divided by d' = 0.8 + 1.3 * accuracy.
| std::uint8_t StaffModel::rating | ( | const StaffMember & | member | ) |
Role rating (1-100) from the role's key attributes.
| void StaffModel::refreshMarket | ( | GameData & | gamedata, |
| std::int32_t | ordinal | ||
| ) |
Replaces part of the market with new candidates (monthly).
| std::uint32_t StaffModel::renewalWage | ( | const StaffMember & | member | ) |
Weekly wage asked to extend a contract.
| std::array< std::uint8_t, STAFF_ROLE_COUNT > StaffModel::roleCounts | ( | std::uint8_t | reputation | ) |
Staff members a club employs per role at a reputation.
| const char * StaffModel::roleDescriptionKey | ( | StaffRole | role | ) |
| const char * StaffModel::roleKey | ( | StaffRole | role | ) |
Language keys.
| std::vector< std::string > StaffModel::seasonEnd | ( | GameData & | gamedata, |
| TeamID | managed_team_id, | ||
| std::uint16_t | year | ||
| ) |
Season end: ageing, retirements, contract expiry (AI clubs mostly renew and refill vacancies from the market).
| std::int64_t StaffModel::severance | ( | const StaffMember & | member | ) |
Compensation for terminating a contract (up to a year's wages).
|
inlineconstexprprivate |
Share of non-player wages paid to football staff. [P]
|
inlineconstexprprivate |
Target size of the staff market.
|
inlineconstexprprivate |
Most members a club may employ per role.