tophat2d / tophat

:tophat: a 2d game library for Umka
https://tophat2d.dev
BSD 3-Clause "New" or "Revised" License
73 stars 5 forks source link

Playground crashes after a compile error #188

Closed vtereshkov closed 4 months ago

vtereshkov commented 4 months ago
error: /playground_main.um (17, 24): Invalid character literal
status: Exception thrown, see JavaScript console
Uncaught RuntimeError: memory access out of bounds

It can be fixed by replacing

if (thg->umth_frame_callback != -1)

with

if (thg->umka && umkaAlive(thg->umka) && thg->umth_frame_callback != -1)

in frame().