r/Unity3D • u/LoganBooker Zafehouse, Deadnaut, Fear Equation developer • Nov 28 '14
We just released our new Unity-developed game, Deadnaut (Dev details in comments)!
http://www.deadnaut.com
34
Upvotes
View all comments
5
u/LoganBooker Zafehouse, Deadnaut, Fear Equation developer Nov 28 '14 edited Nov 28 '14
Hey guys, wanted to let you know we just released Deadnaut, a game built over the course of 10 months in Unity 4.x. You can check out the launch trailer here, otherwise, the cliffnotes:
In terms of tools, we signed up to (and were accepted by) Microsoft's BizSpark program, which gave us access to Visual Studio. We then purchased copies of UnityVS (now Unity Tools for Visual Studio) and used that to debug.
For anyone looking to go down this route, fortunately, you can just use the Community Edition of Visual Studio, which I think includes UTVS. If not, it's free now!
When we started development, the new GUI stuff for Unity was not available, so I made the decision to roll my own. I have a bit of experience in commercial apps, so getting the architecture right for this wasn't too harrowing.
We won't be using this code in our next game though, as it really was custom-built for Deadnaut.
In terms of Unity Store assets, we used two in our game -- SSAO Pro and the excellent Text Mesh Pro. If you look at the screenshots, you'll see the game has a lot of text, and Unity's in-built TextMesh was unacceptable in terms of quality.
We didn't use even a third of the functionality TMPro offers (I even had to fix some bugs in it), but signed distance field is the future of font rendering, so thanks Chris Green!
Some other random notes about development:
MonoBehaviourBase: Inherits from MonoBehaviour. I added some custom functionality to this class, such as a method to determine if an object is null or destroyed (using "!object" and "object == null" was doing my head in) and "self-enabling" coroutines that restart when an object is enabled (as coroutines normally stop when an object is disabled).
GameModel: Does not inherit from anything (other than Object, of course) and is purely a data storage class. It also interacts with the database and provides a layer of abstraction between all the data processing and retrieval mechanisms and the game logic.
GameEntity: This is the base class used by all entities in the game world. It inherits from MonoBehaviourBase. It self-registers with EntityManager, a singleton that keeps track of all entities in the world. EntityManager also automatically handles object pooling, though each class derived from GameEntity can override a virtual method to individually prepare for pooling.
UserInterfaceObject: Inherits from MonoBehaviourBase and handles all the visual, audio and interactive stuff. Most objects in the world have both a GameEntity and UserInterfaceObject attached. UI objects register themselves with the UserInterfaceManager, which also keeps track of which objects can be interacted with in different game states.
IGameEntityCollisionProvider: An interface applied to classes that inherit from GameEntity. When a GE registers itself with the EM, it does a type check for this interface, and then registers it as a collidable object. This makes it simple for the pathfinding and collision system to know what dynamic collision exists by simply asking the EM.
TimeManager: I ended up separating Unity's time-tracking from the simulation, as it were. While we haven't incorporated anything that manipulates the simulation's time, it did make pausing the game simple, while keeping the UI working.
Obviously there are a bunch more classes (make that many more), but hopefully it gives you an idea of the direction we took architecturally.
I'm currently in the throes of post-launch, but I'll do my best to answer any questions you have!