aboutsummaryrefslogtreecommitdiff
path: root/go/ui
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fischer@muhq.space>2025-08-23 19:03:46 +0200
committerFlorian Fischer <florian.fischer@muhq.space>2025-08-23 19:03:46 +0200
commitd2f1fbbecc36f24e131cf050071a8f073dc058d8 (patch)
tree0dc01df490b9675182d9398ba4d832e8bc8e537e /go/ui
parent1ad53231c04a4b46f3d81790f434cdaeba700585 (diff)
downloadmuhqs-game-d2f1fbbecc36f24e131cf050071a8f073dc058d8.tar.gz
muhqs-game-d2f1fbbecc36f24e131cf050071a8f073dc058d8.zip
improve draft activity ui and introduce wasm specific ui constants
Diffstat (limited to 'go/ui')
-rw-r--r--go/ui/constants.go6
-rw-r--r--go/ui/constants_wasm.go8
2 files changed, 14 insertions, 0 deletions
diff --git a/go/ui/constants.go b/go/ui/constants.go
new file mode 100644
index 00000000..052ae527
--- /dev/null
+++ b/go/ui/constants.go
@@ -0,0 +1,6 @@
+//go:build !wasm
+package ui
+
+const (
+ DRAFT_DECK_VIEW_SCALE = 0.5
+)
diff --git a/go/ui/constants_wasm.go b/go/ui/constants_wasm.go
new file mode 100644
index 00000000..e6e2bbce
--- /dev/null
+++ b/go/ui/constants_wasm.go
@@ -0,0 +1,8 @@
+package ui
+
+const (
+ // The atlas of the ebiten wasm port does not allow as big imaes as the linux version.
+ // Therefore, we scale the deck view to reduce its size.
+ // FIXME: This is only needed because the cardView rendering is very naiv.
+ DRAFT_DECK_VIEW_SCALE = 0.35
+)