mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-11-26 11:22:17 -05:00
Show player state flags on the "Player" tab of Save Editor (#1851)
This commit is contained in:
parent
57c1f4dce2
commit
fb0b71ea54
@ -1563,6 +1563,27 @@ void DrawPlayerTab() {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
ImGui::Text("Player State");
|
||||||
|
uint8_t bit[32] = {};
|
||||||
|
uint32_t flags[3] = { player->stateFlags1, player->stateFlags2, player->stateFlags3 };
|
||||||
|
|
||||||
|
for (int j = 0; j <= 2; j++) {
|
||||||
|
DrawGroupWithBorder([&]() {
|
||||||
|
ImGui::Text("State Flags %d", j + 1);
|
||||||
|
for (int i = 0; i <= 31; i++) {
|
||||||
|
bit[i] = ((flags[j] >> i) & 1);
|
||||||
|
if (bit[i] != 0) {
|
||||||
|
ImGui::Text("Flag %d", i);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
ImGui::SameLine();
|
||||||
|
}
|
||||||
|
DrawGroupWithBorder([&]() {
|
||||||
|
ImGui::Text("Sword");
|
||||||
|
ImGui::Text(" %d", player->swordState);
|
||||||
|
});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
ImGui::Text("Global Context needed for player info!");
|
ImGui::Text("Global Context needed for player info!");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user