Samuel Evans-Powell

< Home

Draygon Tensor

A game engine developed with three others as part of a university project.

Things learnt

  • How to apply forces to rigid bodies and calculate their resulting linear and angular motion.
  • Physics engine architecture.
  • How data-oriented design increases flexibility and decreases iteration time.
  • How to develop external tools for a game engine.
  • The importance of a solid build system.
  • Group and time management.

Some of my responsibilities included:

Engine architecture

The engine is a fairly lightweight class that aggregates systems. Systems are a collection of functionality that contain and operate on some data. Systems communicate with one another using the message bus, the engine class is responsible for passing those messages between systems. An entity-component system is used to manage, and provide functionality to, objects in the scene.

For example, the 'Physics' system may own a number of physics components. These physics components contain information about the physical properties of an object (e.g. inertia tensor). The physics system interfaces with a physics engine to update these physics components. The physics system then sends messages to other systems in the engine, so they can update their components if necessary.

This architecture was inspired by Randy Gaul (and his series of articles here), Niklas Frykholm (especially his entity-component system articles here), and various posts from Sean Middleditch (blog).

Developing data formats

I was responsible for developing the data formats the engine uses.

The engine is almost completely data-driven; startup parameters are specified in a 'config.json' file, the functionality of the game is specified in a Lua file (which has access to a number of exposed engine methods), '.prefab' files specify how to construct objects in the scene and '.material', '.shader', '.texture', and '.mesh' files specify the properties of those objects (these are all custom json-formats).

Cross-platform build system

I used CMake to create the build system for the project, all required dependencies are downloaded as part of the build (if required).


Our physics engine was based off the cyclone physics engine.

I was responsible for integrating our physics engine with the game engine and also worked on various parts of the physics engine.


Lua was used as a scripting language for the engine. I was responsible for integrating Lua into the game engine and creating and documenting the Lua bindings.

Blender plugins

Export script

I developed a Blender script that takes an entire Blender scene and outputs it in a format our game engine expects.

Affordance plugin

The affordance plugin allows us to specify the affordances of an object using the Blender UI.


Rigid body plugin

The rigid body plugin allows a user to add collision shapes, mass and inertia tensor properties to an object using Blender's UI.


Math library

I was also responsible for creating and testing the math library.

External links

Author: Samuel Evans-Powell

Created: 2018-07-25 Wed 15:47