fix: mobile entry click and add fullscreen button
- Delay virtual controls creation until after game starts (ctrl overlay was intercepting title screen touches) - Add touchstart handler on game container for mobile entry - Add fullscreen button overlay in top-right corner - Hide title text after game starts
This commit is contained in:
+3
-2
@@ -83,7 +83,8 @@ c.onmouseup = (ev) => {
|
||||
|
||||
// ─── Mobile virtual controls ───
|
||||
|
||||
if (is_touch) {
|
||||
// Called from main.js after game start
|
||||
create_touch_controls = () => {
|
||||
let ctrl = document.createElement('div');
|
||||
ctrl.id = 'ctrl';
|
||||
ctrl.innerHTML =
|
||||
@@ -148,5 +149,5 @@ if (is_touch) {
|
||||
if (t.identifier === touch_id) touch_id = null;
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user