During this past semester, I took an app development class and for my final project was able to make a prototype Google Cardboard game for it using Unity. Below are the main part of my game design document detailing some of the plans I had for the app, which I may eventually implement in the future.
Mothman VR (temp)
December 17, 2015 | Genre: Horror | Platforms: Google Cardboard (Android, iOS)
Summary: Experience several past encounters with the Mothman and experience the horror in first person with Google Cardboard on both Android and iOS devices!
Mockups of Main Menu, Level Select, Pause, and HUD:
The HUD will be empty except for a battery level display in the upper left corner of the screen. In early builds, it will only be text but eventually will become an image of a battery like a camcorder or phone has to show player the battery level.
Controls:
-Magnet – Tigger Auto walk On/Off, Select Menu Option
-Look Down – Pause
Current Build Details: The current build includes a fully working main menu and a sample first level encounter with the Mothman. Current main menu has temporary Cardboard Mode toggle, which will be removed in the final build.
Gameplay Ideas (None of the following are guaranteed features):
- Throwing mothballs at the Mothman to make him go away
- Battery-powered flashlight that eventually runs out, unless you find more batteries. Light level may also get weaker as batteries run out of juice.
- When player sees the Mothman, the screen will get a reddish tint and slight motion blur may occur
SDKs and Game States:
Game Uses Google Cardboard SDK and Unity Game Engine
Game is split into several scenes in Unity, MainMenu and a GameScene for each level.
- MainMenu
- Scene includes a canvas with all menu graphics and text elements
- Camera is centered on canvas along with light for player to read it in the scene
- Main camera includes lenses for each eye
- There are several separate C# scripts:
- CardboardModeMgr.cs
- Part of the script is temporary which is the part that changes the mode between Cardboard and touch controls, other part triggers the start of head tracking so game knows which menu item is selected
- FadeController.cs
- Fancy effect that controls when menu fades after option is selected
- CardboardModeMgr.cs
- MainMenuEvents.cs
- Keeps track of what to do depending on level selection
- GameScene
- Scene includes terrain plane for player to walk on, along with level design
- Audio source is attached to character to play music and sound effects
- Player character includes main camera and lenes for each eye
- Several C# scripts to include:
- CardboardModeMgr.cs
- See above description
- Movement.cs
- Script to control movement of player
- CardboardModeMgr.cs
- Flashlight.cs
- Controls fade of flashlight
- PauseManager.cs
- Controls if pause menu is triggered and displayed
- Mothman.cs
- Specifies movement and events
- LevelManager.cs
- Saves local variable when level is complete and loads next level when level is completed
- Controls level events
- As far as saving data, everything is saved in the local player preferences file (which is a sealed class file) in the app, including number of levels unlocked and whether cardboard mode is enabled in the current build
- Example Save Code:
- PlayerPrefs.SetInt(“VREnabled”, Cardboard.SDK.VRModeEnabled ? 1: 0);
PlayerPrefs.Save();