WorkFam Co. is a HTC Vive experience representing a boring cubic scenario where people want to escape from. It was developed by a group of four people of which I was the only programmer.
In this project, I built a state machine which used six classes. Each class represented one chapter of the story which helped separate the narration and implementation into several parts.
To increase the feeling of VR interaction, I used complicated layer setting in Unity to avoid the collision conflicts. For example, the stamp object has three layers of colliders which are respectively designed for grabbing interaction, normal physical collision and stamping mechanism trigger.
I also implemented the stamping mechanism, material switching mechanism, and the environment-camera calibration. The environment-camera calibration is to generate the environment in a preset position and rotation relative to the camera. Because in VR development camera position is always controlled by middleware, to put the camera in a desired position can only be done in an opposite way, changing the environment position. Wherever the guest is when the last scene is loaded, the environment will always be in the appropriate position. Therefore, the guest will be in the capsule and face forward.