-
Notifications
You must be signed in to change notification settings - Fork 0
cu_when_awake en
mouse114514 edited this page Sep 12, 2026
·
1 revision

Triggers once when the game has finished loading. It is the initialization entry point of your mod - put all registration blocks here (items, recipes, buildings, tiles, locales, statuses) so they are ready before the game uses them.
This is a hat block: it can only be placed at the top of a script, and the blocks connected below run in order when the event fires.
This block has no parameter slots.
| Slot | Type | Description |
|---|---|---|
| (none) | - | no inputs |
| Connection | Type | Description |
|---|---|---|
| Top | - | hat block, cannot connect |
| Bottom | Statement | blocks below run in order when the event fires |
- Register custom items, recipes, buildings, tiles and locale strings
- Register status effects
- Initialize custom variables
- Run one-time setup commands
when mod awakes
├── register item id "customSword" name "Sample Sword" desc "A test sword" sprite "sword.png"
├── recipe input list → output customSword amount 1
├── set myVar to 0
└── run command "log mod ready"
This block emits the patch marker //PATCH:Awake, which is injected into the Awake() method of the generated plugin class.
Block ID: cu_when_awake