Skip to content

Latest commit

 

History

History
69 lines (51 loc) · 1.5 KB

File metadata and controls

69 lines (51 loc) · 1.5 KB

t-rex-runner

the trex runner game extracted from chrome offline err page.

see the source from chromium

go and enjoy! 😄

chrome offline game cast

Event Stream Format

The game connects to an event stream API that sends individual event objects (not arrays). Each event has the following format:

{
  "mac": "d324sdDEI",
  "event": "button|startup|disconnected",
  "name": "tiny-rex",
  "value": 34
}

Event Types

  • startup: When a device starts up, a new dino is added to the game
  • disconnected: When a device disconnects, the corresponding dino is removed from the game
  • button: When a button is pressed, the corresponding dino jumps

Example Events

Device startup:

{
  "mac": "d324sdDEI",
  "event": "startup",
  "name": "tiny-rex",
  "value": 0
}

Button press:

{
  "mac": "d324sdDEI",
  "event": "button",
  "name": "tiny-rex",
  "value": 34
}

Device disconnects:

{
  "mac": "d324sdDEI",
  "event": "disconnected",
  "name": "tiny-rex",
  "value": 0
}

🚀 Local Development Setup

This project uses live-server to automatically reload the browser whenever you make changes to your files.

📦 Prerequisites

You’ll need Node.js installed on your system.