|
Player12
An open source football management simulator
|
#include <imgui.h>#include <memory>#include "gui/render/imatch_renderer.h"#include "gui/render/match_kit_colors.h"#include "gui/scenes/match_scene_tuning.h"Go to the source code of this file.
Classes | |
| class | MatchRenderer2D |
Functions | |
| MatchViewport | computeMatchViewport (float topLeftX, float topLeftY, float availableWidth, float availableHeight) |
| const char * | playerIntentLabel (PlayerIntent intent) |
| void | drawGoalCelebration (ImDrawList &drawList, const MatchViewport &viewport, int homeScore, int awayScore, float celebrationRemaining, float celebrationDuration) |
| MatchViewport computeMatchViewport | ( | float | topLeftX, |
| float | topLeftY, | ||
| float | availableWidth, | ||
| float | availableHeight | ||
| ) |
Fits the pitch into the available screen space at its real 105 x 68 m proportions (never stretched); the caller centres the result.
| void drawGoalCelebration | ( | ImDrawList & | drawList, |
| const MatchViewport & | viewport, | ||
| int | homeScore, | ||
| int | awayScore, | ||
| float | celebrationRemaining, | ||
| float | celebrationDuration | ||
| ) |
Goal flash and banner centred on the viewport; shared by both views.
| const char * playerIntentLabel | ( | PlayerIntent | intent | ) |
Short English description of a player's current intent (tooltips).