Skip to content
Lab

Playable · WebGPU

Composition

A small test scene for the engine's component system. Barrels, soldiers and grass are each just a set of parts, and fire and frost bolts act on whichever parts they find.

  • Gameplay
  • Composition
Composition, a screenshot

Play in browser · 22 MB

Keyboard and mouse recommended

How it works

There are no barrel, soldier or grass types in the code. A barrel has a health part and a flammable part. A soldier has health, flammable and freezable parts. Grass only has the flammable part. A fire bolt sets anything flammable on fire and a frost bolt freezes anything freezable, and what happens after that follows from which parts each object has.

More from the lab

All demos