Skip to content

Commit

Permalink
Added assetpack's build version in HUD (if used) (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
iWas-Coder committed Jun 12, 2024
1 parent 761593c commit d23ba22
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/sk_scene_gameplay.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,15 @@ void sk_scene_gameplay_draw(sk_state *s) {
EndMode3D();
// HUD
DrawText("Client Version: " sk_xstr(SK_VERSION), GetScreenWidth() - 190, GetScreenHeight() - 20, 14, LIGHTGRAY);
const char *ap_version = "N/A";
#ifdef NDEBUG
if (s->ap.fd) ap_version = TextFormat("%lu", s->ap.header.build_ver);
#endif
DrawText(TextFormat("AssetPack %s", ap_version),
GetScreenWidth() - 190,
GetScreenHeight() - 40,
14,
LIGHTGRAY);
DrawFPS(10, 10);
DrawText(TextFormat("%.4f ms", GetFrameTime() * 1000), 10, 33, 20, LIME);
if (s->is_online) {
Expand Down

0 comments on commit d23ba22

Please sign in to comment.