Crafting — DemoHooks (Samples)¶
This subfolder contains sample-only hook components used by Crafting demo scenes.
Purpose¶
These scripts exist to:
- Wire demo scenes together (simple input, logging, and debug hooks)
- Demonstrate basic integration patterns such as:
- Subscribing to
CraftingServiceevents - Implementing
ICraftingValidator - Providing data via
ICraftingLevelSource - Show minimal, copyable examples of interacting with the Crafting system
They are intentionally small and focused so you can see where to plug in your own systems.
Important¶
These scripts are not part of the supported Crafting API.
They are:
- sample code only
- not required to use the Crafting system
- not supported as extension points
- not covered by API stability guarantees
They may be simplified, incomplete, or intentionally naive.
What These Are NOT¶
These scripts are not:
- production-ready systems
- recommended gameplay architecture
- full implementations of UI, progression, or persistence
- a reference for error handling, validation flows, or UX design
They intentionally do NOT demonstrate:
- preflight-driven UI flows
- full user-facing feedback systems
- save/load or persistence
- multiplayer or authority handling
What They Actually Demonstrate¶
Each component focuses on a single concept:
- HUD/controller examples → calling the service and handling events
- validators → implementing
ICraftingValidator - data providers → implementing simple interfaces like
ICraftingLevelSource - event sinks → reacting to service events (e.g., XP, completion, failure)
They are examples of where integration happens, not how your full system should be built.
Using These Samples¶
You can:
- Use them as reference examples
- Copy small pieces into your own code
- Use them to understand where to hook into Crafting
Production Guidance¶
For real projects:
👉 Implement your own runtime components using the public Crafting API
👉 Replace these with your own UI, progression, and gameplay systems
👉 Treat these scripts as learning scaffolding, not reusable building blocks
Relationship to Crafting¶
- Crafting defines the service + interfaces
- Your project defines the runtime behaviour
- These samples demonstrate basic integration points only