// SPDX-License-Identifier: GPL-3.0-only
// Presentation and selection only. The existing session validates each swap.
std::string App::engine_lineup_controls() {
return "
Aufstellung
"
"
Zwei Spieler zum Tauschen anklicken.
"
"
Der Tausch wird erst nach Bestätigung übernommen. "
"Formationen, Anweisungen und Schützen sind hier noch nicht angebunden.
"
"
" +
esc(engine_busy_ ? engine_operation_ : engine_notice_) + "
";
}
std::string App::engine_player_profile(const Json &projection) {
if (engine_player_.empty()) return {};
const Json *row = nullptr;
for (const auto &member : engine_data_.at("squad").at("data").at("players"))
if (member.at("player").at("id") == engine_player_) row = &member;
if (!row) return {};
Json strength;
for (const auto &entry : projection.at("rows")) if (entry.at("id") == engine_player_) strength = entry.at("strength");
const auto &person = row->at("player");
const auto photo = person.at("photoAssetId").is_string()
? person.at("photoAssetId").get