Commit Graph

3 Commits

Author SHA1 Message Date
hypercross ccd0e3afb4 feat(world): add singleton component support
Introduce a mechanism to manage components on a shared, lazily-created
singleton entity. This simplifies access to global state by providing
dedicated methods for adding, removing, getting, and checking for
singleton components.

Refactor the Tetris example to utilize this new singleton pattern for
game state components like Board, Score, and Piece.
2026-06-01 23:52:47 +08:00
hypercross efa92be5ab feat(bt): implement subtree status clearing in TaskRunner
Introduce `clearSubtree` to recursively reset status for an entity and
all its descendants. This ensures that when a task reaches a terminal
state, its entire branch is properly reset.

Also refactor the Tetris example to use a sequential task node within
the behavior tree.
2026-06-01 23:24:43 +08:00
hypercross c3c24d2350 feat(examples): add Tetris game example 2026-06-01 23:18:07 +08:00