Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion wiki/pygbag-code/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,15 @@ import platform
# document may not exist on non-emscripten platforms
if sys.platform == "emscripten":
platform.document.body.style.background = "#404040"
```
```
### Getting a consistent random sequence across runs
Call `random.seed()` before any random functions to base the sequence on the current time.

```py
import random, time
random.seed(time.time())
```

### mobile events handling

TODO, drag/drop events, gestures.
Expand Down