diff options
| author | historia <[not public]> | 2026-06-10 01:48:28 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-06-10 01:48:28 -0400 |
| commit | a226d72e51eecb768b13600303f73483118d9104 (patch) | |
| tree | 458d15ef049732c15dacc591a830d3beddbedfde /internal/action/action.go | |
| parent | 6a0f3d7a252de4b1741cfe5e1c561412c602becc (diff) | |
| download | thehouseoficarus-a226d72e51eecb768b13600303f73483118d9104.tar.gz | |
feat: implemented janky object interaction model
Diffstat (limited to 'internal/action/action.go')
| -rw-r--r-- | internal/action/action.go | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/internal/action/action.go b/internal/action/action.go new file mode 100644 index 0000000..9cd4c0f --- /dev/null +++ b/internal/action/action.go @@ -0,0 +1,32 @@ +package action + +type Action struct { + Type string + TargetID string + TargetName string + Step int + WaitLeft int + Data map[string]any +} + +func (a *Action) Advance() bool { + if a.WaitLeft > 0 { + a.WaitLeft-- + return false + } + return true +} + +type DropEntry struct { + ItemID string `yaml:"item_id"` + Table string `yaml:"table"` + Weight int `yaml:"weight"` + Quantity int `yaml:"quantity"` + Depletes bool `yaml:"depletes"` + Message string `yaml:"message"` +} + +type DropTableDef struct { + ID string `yaml:"id"` + Drops []DropEntry `yaml:"drops"` +} |
