This commit is contained in:
Forrest 2026-10-02 09:54:59 -04:00
parent 32ed347b58
commit f41e197f20
4 changed files with 100 additions and 149 deletions

View file

@ -48,9 +48,11 @@ const MARK_STRENGTH := {"source": 1.0, "respond": 1.2, "selected": 2.0, "target"
# 1600 × 900 base size; scale by the viewport.
const BASE := Vector2(1600, 900)
const PANEL_LEFT := 300.0
const PANEL_RIGHT := 360.0
const PANEL_TOP := 44.0
## The status bar, and under it the row of player strips over the table.
const BAR_H := 44.0
const STRIPS_H := 40.0
const PANEL_TOP := BAR_H + STRIPS_H
const PANEL_BOTTOM := 176.0
## Gap between a panel and the screen edge.
const MARGIN := 8.0
@ -277,4 +279,4 @@ static func scale_of(vp: Vector2) -> Vector2:
## The screen rect the panels leave free for the table, in viewport pixels.
static func table_region(vp: Vector2, bottom := PANEL_BOTTOM) -> Rect2:
var s := scale_of(vp)
return Rect2(PANEL_LEFT * s.x, PANEL_TOP * s.y, vp.x - (PANEL_LEFT + PANEL_RIGHT) * s.x, vp.y - (PANEL_TOP + bottom) * s.y)
return Rect2(0, PANEL_TOP * s.y, vp.x - PANEL_RIGHT * s.x, vp.y - (PANEL_TOP + bottom) * s.y)