Player12
An open source football management simulator
Loading...
Searching...
No Matches
match_play_overlay.cpp File Reference
#include "gui/render/match_play_overlay.h"
#include <algorithm>
#include <array>
#include <cmath>
#include <cstdio>
#include <numbers>
#include "gui/widgets/theme.h"

Functions

void drawMatchPlayOverlay (ImDrawList &drawList, const IMatchRenderer &renderer, const MatchRenderSnapshot &snapshot, const MatchPlayOverlayState &state, ImVec2 viewMin, ImVec2 viewMax)
 

Function Documentation

◆ drawMatchPlayOverlay()

void drawMatchPlayOverlay ( ImDrawList &  drawList,
const IMatchRenderer &  renderer,
const MatchRenderSnapshot &  snapshot,
const MatchPlayOverlayState &  state,
ImVec2  viewMin,
ImVec2  viewMax 
)

Play-mode overlay over a rendered match view: a ring under the active footballer with his name and condition above him, the power bar while a button is held, a lighter ring on the next switch candidate, an arrow at the view's edge when the active footballer is out of the picture, and a radar of the whole pitch at the bottom of the view. Draws through the renderer's own projection, so it fits the 2D and the 3D view alike, and allocates nothing.