Skip to content

Fix iOS battle HUD - #119

Open
Elementalzx14 wants to merge 1 commit into
DramaticShape:devfrom
Elementalzx14:fix/ios-battle-hud
Open

Fix iOS battle HUD#119
Elementalzx14 wants to merge 1 commit into
DramaticShape:devfrom
Elementalzx14:fix/ios-battle-hud

Conversation

@Elementalzx14

Copy link
Copy Markdown

Fixes the battle HUD rendering path on iOS.

On iOS, the Canvas-to-Canvas HUD composite is presented vertically
inverted. The previous iOS fallback avoided this path, but resulted in
opaque white HUD backgrounds and prevented the HUDs from using the
full display width.

This change:

  • enables the snapped edge HUD path on iOS
  • compensates for the vertically inverted iOS canvas blit
  • keeps the enemy HUD in the upper-left
  • keeps the player HUD on the right
  • removes the opaque/frosted iOS HUD backings
  • skips the mirrored text-box frost panel
  • preserves the battle menu border, text, cursor, and transparent fill
  • responds correctly in portrait and landscape orientations

Tested on

  • iPhone 17 Pro Max
  • iOS 27 Public Beta
  • portrait orientation
  • landscape orientation
  • wild Pokémon battles

Screenshots

Before:
630468771-f486273b-077c-4e5c-91c7-752f5af195b2

After:
IMG_3470
IMG_3469

@Elementalzx14

Copy link
Copy Markdown
Author

Please note, this was not tested on PC or Android, only on IOS

absol89 added a commit to absol89/DramaticShapeVoxelMod that referenced this pull request Aug 6, 2026
…ponent panels

On iOS the snapped HUD path was skipped (it drew upside-down + opaque),
leaving semi-transparent (0.84) in-frame panels. Port the upstream PR DramaticShape#119
correction for our fork:

- snapHUDs now runs on iOS: the player/opponent HUDs get OPAQUE WHITE
  backplates (BattleHud.panel is frosted-only and no-ops at FROST/TINT 0,
  so a plain white fill is the right primitive) and the HUD layer is blitted
  with the vertical-flip that corrects iOS's upside-down Canvas-to-Canvas
  presentation. The text box's backing is skipped on iOS (it would ghost
  upward), so the box stays as the engine's own opaque-white panel.
- HUD glyphs on iOS stay BLACK (dark=false) to read on white; the WHITE
  arena fill still inverts to black ink + white drop-shadow.
- drawHudPanels iOS fallback draws opaque white (1,1,1,1) instead of 0.84.
- The dialogue/action/move/type boxes keep the engine's native opaque-white
  panel with black glyphs on iOS (drawTextArea returns early there).

Desktop (Windows/Android) is unchanged.

Co-Authored-By: Hermes Agent <noreply@hermes-agent.com>
absol89 added a commit to absol89/DramaticShapeVoxelMod that referenced this pull request Aug 6, 2026
…, keep boxes white

The iOS HUD path drew a plain opaque-white g.rectangle over the full
snapped HUD band (HUD_RECT), which covered the whole top and bottom-right
of the screen -- including empty diorama where no UI belongs -- producing
the white cards reported by iOS users. Remove those fills: the HUD glyphs
now blit straight onto the diorama (transparent, matching upstream PR DramaticShape#119).

Text boxes (dialogue, action-select, move-list, type, yes/no, move-learn)
stay opaque white because they are the engine's own Font.drawBox, which
drawTextArea preserves on iOS. HUD glyphs keep the engine's native white
ink (dark = true) to read over the scene.

Desktop (Windows/Android) is unchanged.

Co-Authored-By: Hermes Agent <noreply@hermes-agent.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant