Commit Graph

14 Commits

Author SHA1 Message Date
011901eb8f Refactoring of the interaction system and preliminary integration of save/load functionality across the game. (#44)
### Interactables Architecture Refactor
- Converted composition to inheritance, moved from component-based to class-based interactables. No more requirement for chain of "Interactable -> Item" etc.
- Created `InteractableBase` abstract base class with common functionality that replaces the old component
- Specialized child classes: `Pickup`, `ItemSlot`, `LevelSwitch`, `MinigameSwitch`, `CombinationItem`, `OneClickInteraction` are now children classes
- Light updates to the interactable inspector, moved some things arround, added collapsible inspector sections in the  UI for better editor experience

### State Machine Integration
- Custom `AppleMachine` inheritong from Pixelplacement's StateMachine which implements our own interface for saving, easy place for future improvements
- Replaced all previous StateMachines by `AppleMachine`
- Custom `AppleState`  extends from default `State`. Added serialization, split state logic into "EnterState", "RestoreState", "ExitState" allowing for separate logic when triggering in-game vs loading game
- Restores directly to target state without triggering transitional logic
- Migration tool converts existing instances

### Prefab Organization
- Saved changes from scenes into prefabs
- Cleaned up duplicated components, confusing prefabs hierarchies
- Created prefab variants where possible
- Consolidated Environment prefabs and moved them out of Placeholders subfolder into main Environment folder
- Organized item prefabs from PrefabsPLACEHOLDER into proper Items folder
- Updated prefab references - All scene references updated to new locations
- Removed placeholder files from Characters, Levels, UI, and Minigames folders

### Scene Updates
- Quarry scene with major updates
- Saved multiple working versions (Quarry, Quarry_Fixed, Quarry_OLD)
- Added proper lighting data
- Updated all interactable components to new architecture

### Minor editor tools
- New tool for testing cards from an editor window (no in-scene object required)
- Updated Interactable Inspector
- New debug option to opt in-and-out of the save/load system
- Tooling for easier migration

Co-authored-by: Michal Pikulski <michal.a.pikulski@gmail.com>
Reviewed-on: #44
2025-11-03 10:12:51 +00:00
512e8cade5 IntroNarration 2025-10-17 14:38:42 +02:00
Michal Pikulski
65e14c07d2 Fix bug where input was blocked from levels other than main menu 2025-10-13 12:41:04 +02:00
47d942d176 Switched Unity version to 6.2, updated some packages + installed GraphToolkit 2025-09-26 08:48:33 +02:00
31f2ce338d Component move/copy utility 2025-09-19 10:08:58 +02:00
abffb5c558 Michal saw we were programming with sticks 2025-09-11 13:53:42 +02:00
2be6b5626e Reimplemented intro animation as regular ol' sprites 2025-09-09 14:22:05 +02:00
ed093c3ddd Intro cinematic implementation and Apple Hills map 2025-09-09 13:11:18 +02:00
Michal Pikulski
749d72904e Add main menu scene, setup framework for orientation switching 2025-09-08 12:44:35 +02:00
Michal Pikulski
d20004238d [Bootstrap] First go at Addressables bootsrapped objects 2025-09-07 12:36:35 +02:00
Michal Pikulski
4a098365d0 Setup Universal Render Pipeline 2025-09-05 09:10:19 +02:00
Michal Pikulski
82595e8991 [Player] Add CineMachine tracking camera in the main level, set to follow player 2025-09-01 16:57:08 +02:00
8b0f6b9376 Added tilemap plugin and tilemap 2025-09-01 15:07:27 +02:00
Michal Pikulski
1a5126a259 [Player][Input] Switch to generic input consumption interface. Version package json file 2025-09-01 15:04:15 +02:00