(Feat) Tools Creation

This commit is contained in:
2026-06-22 23:32:46 +02:00
parent 2234ed14ce
commit 6527f559e1
36 changed files with 2917 additions and 369 deletions
@@ -0,0 +1,24 @@
---
name: pickable-vestigial-networkobject
description: Existing Pickable prefabs carry an unused FishNet NetworkObject; the canonical generated prefab omits it.
metadata:
type: project
---
The hand-authored Pickable prefabs (e.g. `Prefabs/Food/Pickable/Raw Steak.prefab`,
`Prefabs/Pickable/Tools/axe01.prefab`) still carry a FishNet `NetworkObject` component, left
over from a pre-refactor design.
**Why it's dead:** `Pickable` now derives from `WorldObject` (not `NetworkBehaviour`), and
`PickableRegistry.SpawnDropVisual` creates drops with a plain `Instantiate(item.WorldPrefab,…)`
— a local visual, never a network spawn. The registry syncs only ids/drop records. So the
`NetworkObject` on those prefabs does nothing. This matches CLAUDE.md §3 ("World objects
(pickables, harvestables) are not NetworkObjects").
**How to apply:** When generating or authoring world pickup prefabs, do NOT add a
`NetworkObject`. Required pieces are: the Pickable layer (11), a non-trigger collider on the
SAME GameObject as the `Pickable` (the interactor reads `IInteractable` via
`hit.collider.TryGetComponent`), the `Pickable` script wired to its `ItemData`, and id = -1
(scene instances get a baked id via Tools ▸ Ashwild ▸ Assign World Object IDs). The Ashwild
Database tool ([[ashwild-database-tool]]) generates them this clean way. The vestigial
NetworkObjects on old prefabs could be stripped in a cleanup pass.