Link zoom of the released game: Auto or Fit (#279)
1 parent
09d1f978ac
commit
f8ee57b6ff
3 files changed
+14
-5
No files matched your search
+4
-1
@@ -582,7 +582,10 @@ and `project.gameScale` (the game view's scale) live in the project too since #2
|
||||
`core/model/playSettings.ts`; anything unknown reads as the default. The switch is an undo step
|
||||
like every project setting. The scale is saved but never pushed on the undo stack
|
||||
(`EditorState.setGameScale`), and one picked while playing is written into the saved model as well,
|
||||
so Stop does not throw it away. None of these fields needed a format bump: a document without them
|
||||
so Stop does not throw it away. `project.gameLinkZoom` (#279, `'auto'` or `'fit'`) is read the same
|
||||
way and is the one thing the page of a released game takes from these settings: `GameScreen` hands
|
||||
it to `cameraView` where it used to pass a fixed `'auto'`. It is deliberately not `gameScale`,
|
||||
which changes whenever somebody zooms the Game tab. None of these fields needed a format bump: a document without them
|
||||
reads as the defaults, which is precisely what older projects meant. The only thing still kept in
|
||||
the browser is the save of a persistent Variables asset (`editor/saves.ts`).
|
||||
|
||||
|
||||
+9
-3
@@ -143,8 +143,14 @@ the link dead; publishing again afterwards hands out a new one. Deleting the pro
|
||||
release down. The link is `play.html?game=<token>`, the token 128 random bits and the only key.
|
||||
|
||||
The game on the link always starts in the start scene (the *Active scene* switch is the editor's
|
||||
alone), zoomed like the game view's **Auto**: the largest zoom step at which the whole camera fits,
|
||||
never a scale between the steps. It waits for a click or Enter before it starts — browsers play no
|
||||
alone). How it is zoomed is the project's **Link zoom** in *Menu → Project settings…* (#279):
|
||||
**Auto**, the default, is the game view's Auto — the largest zoom step at which the whole camera
|
||||
fits, never a scale between the steps, which keeps pixel art sharp. **Fit** fills the window in
|
||||
one direction at whatever factor that takes, like the game view's Fit. The setting is its own and
|
||||
not the scale of the Game tab, which is how the editor looks at the game; fixed steps such as 100%
|
||||
are not offered, since nobody knows the size of a player's window. It is an undo step, and like
|
||||
every other change it reaches the link only with **Update release**. The game
|
||||
waits for a click or Enter before it starts — browsers play no
|
||||
sound before one, and the keyboard would have nowhere to go. Every key belongs to the game, Tab
|
||||
included. A game that stops itself (`Stop game`) offers to play again; `Restart game` and
|
||||
`Load scene` work as in the editor. Persistent variables are saved in the player's browser under
|
||||
@@ -163,7 +169,7 @@ of words has one too, and a tab whose name was cut short shows the whole name. O
|
||||
notice line, the save status, the frame rate and the **Account** menu. What the bar used to spell
|
||||
out lives in the menu now: the project list in *Open project…*, the project name, the
|
||||
**start-scene switch** (*Start scene* / *Active scene*, see **Start scene**), the **While playing**
|
||||
preset (see above), the **symbol scale**
|
||||
preset (see above), the **Link zoom** of the released game (see above), the **symbol scale**
|
||||
of the scene view's icons (see [Scene editing](Scene-editing)) and the collision layers in
|
||||
*Project settings…*. A project is deleted in *Open project…*: **Delete** asks first, and Cancel, Esc
|
||||
and the deletion itself all lead back to the project list. The active scene is picked where the scenes are — by double-clicking
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ php tests/php/accounts.test.php # the API's accoun
|
||||
# has and the web server's container has not (SKIP there)
|
||||
php tests/php/snapshots.test.php # the snapshot store (#231), the same way
|
||||
php tests/php/releases.test.php # the release store (#266), the same way
|
||||
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1668 editor checks, screenshots in /tmp/gm-e2e-*.png
|
||||
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1671 editor checks, screenshots in /tmp/gm-e2e-*.png
|
||||
GM_STEPS=20 node tools/e2e.mjs # or 1-12, or 6,20 — a subset while working on one step
|
||||
./e2e.sh start [GM_STEPS] # the same run detached, see below
|
||||
./e2e.sh status # live progress, or the last run's result
|
||||
|
||||
Reference in new issue
Block a user