Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(1 edit)

The scene editor doesn't generate code, it generates a JSON description which is then used to build the actors.

Basically, each actor does:

const myActor = new Sup.Actor("My Actor", parentActor);

Then if you have a sprite renderer for instance, it'll do:

new Sup.SpriteRenderer(myActor, "Path to sprite asset");

etc.

You can find the whole code for setting up an actor component from its scene configuration in its runtime folder. For the SpriteRenderer for instance: https://github.com/superpowers/superpowers-game/blob/master/plugins/default/sprite/runtime/SpriteRenderer.ts