House Simulation 2

“House Simulation 2” is an upgraded version of my first digital twin project. It adds new interactive features like letting users change the color of objects around the room and includes a more dynamic UI. This project improves on House Simulation 1 by giving users more control and making the experience more immersive.

Created In: 2022
Collaboration: Solo
Link to Play the Game: m4tin – itch.io
Game Engine: Unity- C#

In House Simulation 2, since the space was small, I adjusted the camera’s field of view to better showcase the room. I also used Unity’s Cinemachine to handle the main camera, ensuring smooth and flexible camera control throughout the simulation.

The UI in House Simulation 2 follows the same circular design as in the first simulation, with a key improvement: when users click on objects that can change color, the system automatically extracts the materials from the object and generates buttons for each material in the UI. Since different objects can have varying numbers of materials, I used math to evenly space the buttons along the circle, ensuring a consistent look regardless of how many buttons are generated.

To communication between the UI and the scripts, I implemented the Observer Design Pattern, allowing the UI to respond dynamically to user actions.

When users click the Change Color button, a color palette window pops up, allowing them to easily select new colors. I also added a feature to let users bring back previous colors or remove colors conveniently, ensuring a smooth and flexible customization experience.

Pure CSS3 Tabs
  • Inside Game Button Controller

  • Change Color Script

  • GUI Button Script

For the color customization in the game, I built a color palette where users can select colors for objects in the room. To create a seamless UI, I used math to generate buttons along a circle for each material, allowing users to easily interact with the options. When a user selects a color, the system extracts the material from the object and applies the new color by adding an additional material layer on top.

I also created a custom color picker myself by tracking the mouse position and reading the pixel color directly.

Pure CSS3 Tabs
  • Color Picker