Skip to content

Phones and Tablets

Games here are played on phones. The Game view shows your game at a phone’s or a tablet’s size, so you see what a player sees before you publish it.

Press Play, then choose a Device in the Game view’s toolbar:

DeviceSizeWhat it is
Phone402 × 874An iPhone 17
Small Android360 × 800The second most common phone size in the world
Tablet820 × 1180An iPad Air 11”
Responsivethe panel’sThe game takes the Game view’s own size, as it did before

The game then has that size: it is drawn smaller to fit the panel, and the size and how much smaller it is drawn show in the toolbar (“402 × 874 · 57%”). The device’s corners and its notch or camera are drawn round it.

  • Landscape turns the device on its side, and back.
  • Safe area stripes the room the device keeps at its edges for its notch, its status bar and its home bar. The game is told of that room, as a phone tells it: a Canvas of its UI is laid out inside it, so a score or a button stays clear of the notch. Whether the stripes show, the game keeps inside them.

On a device the mouse is a finger: the game is told of touches, as on a phone, and not of a mouse. Hold Alt as you press to add a second finger, mirrored about the middle of the screen, to pinch with. In Responsive the mouse is a mouse again.

The Agent sees the game at a device’s size too. Ask it, for example, “show the game on a phone in landscape and check that the score is not under the notch”.

The device you choose is your own view in this browser, kept for next time. Nothing of the game or the Project changes.

On your phone, at the right of the Game view’s toolbar, shows a QR code. Scan it with your phone’s camera: the game opens there as it is in the editor now, your scripts and scenes included, signed in as you.

  • The link works once, for 10 minutes. Whoever opens it first plays as you, with no sign-in, so keep it to your own phone: don’t show the code on a screen others can scan, as in a stream. New link makes another, and Copy link copies it, to send to your phone some other way.
  • The phone plays the game, and that is all: it has no editor, changes nothing in the Project, and makes no link of its own.
  • While the phone has the game open, the toolbar says so (iPhone · Safari · connected):
    • what the game writes to the console on the phone comes to the editor’s Console, marked phone, its errors too. The first line says what the phone is: its screen, what the game draws at, and how long it took to load;
    • the Frames tab of the Systems panel shows the phone’s frames with This editor | Phone (see Systems).
  • Disconnect stops the phone telling the editor. The game plays on there until you close it.

Your phones send at most 20 messages a second together, and 50 lines in each; when they write more than that, the Console says some was left out. Four of your phones can be connected at once. An agent reads the phone’s lines with read_log, as phone’s.

Play on your phone works in the online editor. An editor on your own computer (Work on your computer) has no address a phone can reach.