Drop vending machine interactable (no targetable proxy object)
Hospital vending machines resolve to target.GetObject()==null, so they can't be detected or cleanly overridden. Ship sink + fridge + med cabinet (all working). VendingTable loot kept for future re-add / reuse on a detectable furniture. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
parent
e2135794d6
commit
41c8e29cea
2 changed files with 18 additions and 10 deletions
23
README.md
23
README.md
|
|
@ -10,10 +10,10 @@ two-stage repairable sink (repair, then gather water).
|
|||
|
||||
## Features
|
||||
|
||||
- **Searchable furniture** — medical cabinet, fridge, and vending machine yield
|
||||
random items from weighted, config-defined loot tables. Per-object cooldown.
|
||||
- **Searchable furniture** — medical cabinet and fridge yield random items from
|
||||
weighted, config-defined loot tables. Per-object cooldown.
|
||||
- **Repairable sink** — repair with a `Wrench`/`PipeWrench`, then gather water
|
||||
into a held/inventory container. Per-player cooldown, configurable amount.
|
||||
into a held container. Per-player cooldown, configurable amount.
|
||||
- **JSON-configured** — interactables, loot tables and scalar tunables live in
|
||||
JSON under `<ProfileFolder>/YAInteraction/`. Defaults are written on first
|
||||
start and read (overriding defaults) on every start after. No target/loot
|
||||
|
|
@ -21,12 +21,17 @@ two-stage repairable sink (repair, then gather water).
|
|||
|
||||
## Target objects (v1)
|
||||
|
||||
| Classname | Action | Loot table |
|
||||
|-----------|--------|-----------|
|
||||
| `StaticObj_Furniture_case_sink_a` | Repair → Gather Water | — |
|
||||
| `StaticObj_Furniture_lekarnicka` | Search | MedTable |
|
||||
| `StaticObj_Furniture_fridge` | Search | FoodTable |
|
||||
| `StaticObj_Furniture_vending_machine` | Search | VendingTable |
|
||||
Identified by their YAProxy proxy name (substring match):
|
||||
|
||||
| Proxy | Action | Loot table |
|
||||
|-------|--------|-----------|
|
||||
| `case_sink_a` | Repair → Gather Water | — |
|
||||
| `lekarnicka` | Search | MedTable |
|
||||
| `fridge` | Search | FoodTable |
|
||||
|
||||
> Vending machines (`vending_machine`) are **deferred**: in tested buildings the
|
||||
> proxy exposes no targetable object, so it can't be detected. `VendingTable` is
|
||||
> still defined for when that's solved or its loot is moved to another furniture.
|
||||
|
||||
## Configuration files
|
||||
|
||||
|
|
|
|||
|
|
@ -113,7 +113,10 @@ class YAInteractionConfigLoader
|
|||
d.Interactables.Insert(MakeEntry("case_sink_a", YAInteractionConfig.ACTION_REPAIR_WATER, "", Settings.SinkPlayerCooldownSec));
|
||||
d.Interactables.Insert(MakeEntry("lekarnicka", YAInteractionConfig.ACTION_SEARCH, YAInteractionConfig.TABLE_MED, Settings.ObjectCooldownSec));
|
||||
d.Interactables.Insert(MakeEntry("fridge", YAInteractionConfig.ACTION_SEARCH, YAInteractionConfig.TABLE_FOOD, Settings.ObjectCooldownSec));
|
||||
d.Interactables.Insert(MakeEntry("vending_machine", YAInteractionConfig.ACTION_SEARCH, YAInteractionConfig.TABLE_VENDING, Settings.ObjectCooldownSec));
|
||||
// Vending machines deferred: in tested buildings the proxy has no targetable
|
||||
// object (target.GetObject()==null), so it can't be detected/overridden
|
||||
// cleanly. VendingTable below is kept for when that's solved or moved to a
|
||||
// detectable furniture. Re-add: MakeEntry("vending_machine", ACTION_SEARCH, TABLE_VENDING, ObjectCooldownSec)
|
||||
|
||||
// --- Loot tables (classnames verified in P:\DZ) ---
|
||||
YALootTable med = MakeTable(YAInteractionConfig.TABLE_MED);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue