The Shared Game Timer can connect to any Bluetooth LE (Low Energy) device and not only read data from it (and trigger actions in the game e.g. End Turn) but also send data when something changes in the game timer.
Here are some examples of what you could do:
- Set the color of a smart lightbulb to the current player's color.
- Three minutes into someone's turn, tell your alert bracelet to vibrate.
- Six minutes into someone's turn, tell the doorbell to ring.
- When you press some button, end your turn.
- When you shake the device, perform Undo.
- During Admin Time, play elevator music on your stereo.
This is not the easiest to set up, but it is where you can really create some unique experiences and let your creativity go wild! If you want help set up your Bluetooth device, feel free to email me at firstname.lastname@example.org.
If you want to see example projects that use the Bluetooth feature to do cool stuff with the Shared Game Timer, check out these guides!
Summary of Setup
The communication between the Shared Game Timer and a Bluetooth LE device is done using Action Maps and/or Write Scripts.
Bluetooth devices may send status updates, for example "Button A pressed". Action Maps is a list of keywords to listen for and which action to perform in the Shared Game Timer when those keywords are found.
|Button A||End Turn|
Available actions you can pick from are:
'Poll' is a special action that will immediately activate a Write Script. (see next section)
The Shared Game Timer may send status updates about the game timer to the Bluetooth LE device.
This is split into two parts, What to send and When to send it.
What to send (the Write Script)
This is easiest to explain with an example. The script below will blink a lightbulb on/off two times with the current player's color.
0 #000000 500 sgtColor 1000 #000000 1500 sgtColor
A Write Script is basically just lines of text, where each line starts with a number, followed by some spaces, and then a command to send to the Bluetooth device.
The number at the start of each line is the number of milliseconds to wait after the trigger before sending that command. The commands also undergo some substitutions. So in the example above, the Shared Game Timer will send the text '#000000' (black) immediately when the Write Script is triggered, then wait half a second, then send the player color in hex Red-Green-Blue format (e.g. red would be #ff0000), wait another half second and then do it all again.
This assumes that the lightbulb can understand the commands #RRGGBB and correctly act on them.
The full details of the substitutions (e.g. sgtColor player color) are explained on the page where you define these scripts, so I will not go into further details here.
When to send it (the Trigger)
These Write Scripts may be triggered at certain events in the Shared Game Timer.
- At the start of a particular player's turn.
- When the game timer enters Admin time.
- When the game timer is paused.
- At the start of the game.
- At the end of the game.
- At certain times into a player's turn.
- When a sand timer is started, stopped or reset.
- When a sand timer runs out of time.
- When polled by an Action Map's 'Poll' action.
Because these triggers can be specific to certain players, they need to be set up for each game. This step is very quick though. Connect to the device, pick the relevant Write Script and check some checkboxes. Done!