Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Environmental puzzle system 🕯️

A "one-room horror" gameplay prototype featuring modular interaction mechanics, physics-based object manipulation, and atmospheric puzzle logic.


🔗 Links

🎬 Watch demo (YouTube)


📝 About

Environmental puzzle system is a tech demo showcasing gameplay mechanics typical for the horror genre. The project focuses on creating an immersive, interactive environment where the player must solve sequential puzzles to progress.

The system was designed with extensibility in mind, allowing designers to easily create complex chains of events (e.g., correct setting -> unlock compartment -> grind skulls -> reveal chest) without tight coupling between individual objects.

✨ Key features

  • Sequential puzzle logic: A multi-stage puzzle system where one completed action physically alters the environment to reveal the next step.
  • Object manipulation: Physics-based interaction allowing players to pick up, carry, and insert objects (skulls) into specific machinery.
  • Atmospheric polish: Integration of dynamic lighting, and smooth object animations to build tension.
  • Context-sensitive inputs: A unified interaction system that adapts behavior based on the target object.

⚙️ Technical highlights

The code architecture prioritizes readability and the separation of puzzle logic.

  • Interface-based interaction (IInteractable): The player controller does not depend on concrete classes (like Sword or Skull). Instead, it communicates via interfaces. This adheres to the Dependency Inversion Principle, making it easy to add new interactable types (e.g., levers, doors) without modifying the player logic.

  • Reactive puzzle state: The system uses an event-driven approach (Observer Pattern) to monitor puzzle states. For example, the BoneGrinder doesn't check every frame if a skull is inside; it reacts to specific triggers/collisions, updating the game state only when necessary.

  • Procedural animation (DOTween): Instead of relying solely on baked Animator clips, the project utilizes DOTween for code-controlled animations (e.g., the descending chest, rotating swords). This provides precise control over timing and easing functions directly from the script.

  • Asynchronous logic (UniTask): Complex sequences (like the chest reveal cutscene) are handled using UniTask (async/await) instead of Coroutines. This avoids "callback hell" and makes linear gameplay sequences easier to read and debug.

🛠️ Used

  • Unity 6 (6000.0.41f1)
  • DOTween
  • UniTask

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages