|
Player12
An open source football management simulator
|
Generation of scout backgrounds and the effectiveness model. [P]. More...
Functions | |
| ScoutExpertise | generate (Language nationality, std::uint64_t world_seed, std::uint32_t scout_id, std::span< const LeagueID > countries) |
| ScoutEffectiveness | compute (const ScoutExpertise &expertise, std::uint8_t judging_ability, std::span< const TargetCountry > countries, LeagueID league, std::uint32_t league_days) |
Variables | |
| constexpr float | MIN_MULTIPLIER = 0.6f |
| constexpr float | MAX_MULTIPLIER = 1.5f |
| constexpr float | JUDGING_PER_POINT = 0.004f |
| constexpr float | HOME_COUNTRY = 0.20f |
| constexpr float | KNOWS_LEAGUE = 0.20f |
| constexpr float | KNOWS_COUNTRY = 0.10f |
| constexpr float | SPEAKS_LANGUAGE = 0.10f |
| constexpr float | LANGUAGE_BARRIER = -0.15f |
| constexpr float | FAR_FROM_HOME = -0.10f |
| constexpr float | FULL_EXPERIENCE_DAYS = 365.0f |
| constexpr std::uint16_t | LANGUAGE_LEARNED_DAYS = 540 |
| constexpr std::uint16_t | MAX_LEAGUE_DAYS = 9'999 |
Generation of scout backgrounds and the effectiveness model. [P].
| ScoutEffectiveness ScoutExpertiseModel::compute | ( | const ScoutExpertise & | expertise, |
| std::uint8_t | judging_ability, | ||
| std::span< const TargetCountry > | countries, | ||
| LeagueID | league, | ||
| std::uint32_t | league_days | ||
| ) |
Effectiveness = 1 + judging + home + league/country experience + language +- distance, clamped to [MIN_MULTIPLIER, MAX_MULTIPLIER]. Country terms are weighted by the countries' shares of the assignment.
| league | Specific league of the assignment (0 = none) and league_days the scout's days there. |
| ScoutExpertise ScoutExpertiseModel::generate | ( | Language | nationality, |
| std::uint64_t | world_seed, | ||
| std::uint32_t | scout_id, | ||
| std::span< const LeagueID > | countries | ||
| ) |
Deterministic background of a scout: languages from his nationality (native plus plausible second languages), usually a spell in his home country's top league and up to two leagues abroad, preferring countries whose language he speaks or that are on his continent.
| countries | Top league ids of the world's countries. |
|
constexpr |
Another continent.
|
constexpr |
|
constexpr |
|
constexpr |
+-20% across 1-100.
|
constexpr |
After a year there.
|
constexpr |
After a year there.
|
constexpr |
|
constexpr |
Picked up abroad.
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |