Personal Project
| Engine | Project Type | Time (hrs) | Number of Developers |
| Unity 3D | Personal | 40 | 3 |
As the only programmer on this project, my main contribution was the system for how the puzzles work so that anyone can make the puzzle with limited code being written. There is a script that will trigger when someone completes a puzzle and you can change what will be the trigger and the effect of the puzzle being completed in the inspector.
For example if you wanted a key to unlock a door, there is a script that checks if an object has been placed into a location and if so, trigger the effect. A key placed into a locked door will open it, a fuse put into the fuse box will turn all of the power on. This allows anyone to create a puzzle within the inspector. This means that any puzzle can be made to have any effect happen. The only time new code needs to be written is if you want a trigger that has not been made or an effect that has not been made.
This made it so that more time could be used on other areas of the game and you could test each part of a puzzle individually to make sure that it all works.
As well as this I also made it so that you could inspect any object you could pick up and see if there are any notes on it. This was done with a ray cast intersecting the object and if it has a collider to move it to the players hand and to make it a child of the player. When the player presses the inspect button, it would show the object on a new screen, and it could be rotated. This was done by getting the mesh of the object and getting the minimum and maximum vertex in world space and finding the centre location and rotate the object around that point. This allowed for any object to be picked up and inspected and no scripts had to be attached to the object.


