"It's nae a skirt!" - the first 5 months developing Flak Jack

What? Why?

Back in early April, I got slapped in the face with a ridiculous idea. It was so vivid from the get go, that I knew I had to make it; 

"A comedic VR game where you fly a plane with your head movements, and shoot with motion controllers in air to air dogfights, set in WW1. The pilot is a mad Scotsman. He has a co-pilot dog. It's called Flak Jack."

That all came to me in that very first instant. It was so daft, I had to dive right in. Nobody else was going to dream that one up.

View fullsize
Early reference images - The 3 main elements of Flak Jack

Early reference images - The 3 main elements of Flak Jack

 

I've been tinkering with game development for a couple of years now since the release of Unreal Engine 4. Spurred on by a couple of friends at Weta who are also interested in game dev, I've been stepping it up, working away on various things several nights a week. In that time I've realised that the bit I really enjoy the most is game design itself, dreaming up worlds and gameplay systems. So, after a fair amount of time playing with certain aspects of UE4, learning the engine, I decided I was just going to go all in, and make a complete game. I was also going to try and do it just using UE4's blueprint system for visual scripting. That means I would be typing next to no code.

It's a stupidly ambitious thing to try and do. Even a "simple" game is more complex than most people would imagine. Still, if there is one thing I've learned from 13+ years of film VFX, it's that I've got a pretty solid sense of how to break complex things down into manageable pieces and construct a system. I know how to create spectacle. I've got a fairly good idea of how drama and pacing work. In that way, there is a lot of crossover between VFX and game development. More than that though, after years of making other peoples stories and worlds, I felt it was time to put something out there that was my idea. 

Where the hell did that come from?

At first glance it seems like a pretty random game concept, but ideas do not come from a vacuum. My Dad's side of the family is Scottish and I grew up exposed to Scottish culture (I grew up in Australia). My Mum's father built model air planes and I used to build model kits as a kid. I spent many a school holiday at their house playing flight sims...and Doom. We played lots of Doom. It was my grandfather who first introduced me to 3D graphics, he used to draw plans for his model builds in AutoCAD. I've played plenty of shooter games over the years, and despite the vast numbers of shooters out there, I feel I've found a somewhat fresh take on things - especially for a VR game.  There are dozens of other references and influences that have since fed into the game idea; Tintin and Snowy. Hans and Chewie. Wallace and Gromit. John Woo movies. Tarantino. Slapstick comedy. Indiana Jones. Bagpipes. Sea Shanties. Homing pigeons. The advancement of technology. It's a good ol' mix.

Get on with it.

So I started. Armed with UE4, an Oculus DK2 VR headset, and a Razer Hydra - hand held motion controllers.  Beginning with the flying game template provided by Epic, I took their crude flying saucer demo and wired it up so that the pitch/roll/yaw of the DK2 controlled the pitch/roll/yaw of the spaceship. Then I swapped out the spaceship for a dodgy model of a plane I found online. Already I could fly around a level steering the plane with my head, the plane sitting in front of the view, moving at a constant speed.

View fullsize
VR Camera + Plane + Distance Markers

VR Camera + Plane + Distance Markers

The absolute basics of flight were now working. There is a huge amount still to do on flight mechanics but I'll save that for another day.

Clouds

One of the main goals I have for Flak Jack is to be able to use 3D volumetric clouds as a play space, not just a backdrop. Clouds and skies in many games are either an image mapped on to a giant sphere that surrounds you, or 2D cards/sprites with a cloudy texture applied. Neither was going to be enough in my case. UE4 does not have a native method for creating volumetric FX like clouds. They are typically heavy to render and require lots of data. So, I had an idea and fired up Houdini. The basic concept was to make cloud volumes in Houdini, render them from a bunch of angles with lighting baked in, and then use UE4's imposter sprites to draw the clouds in the game. Imposters are a trick used to show the impression of a 3D object from a series of images taken at slightly different angles. Here is an early test result.

Houdini volume renders with lighting baked, as imposter sprites in UE4

Houdini volume renders with lighting baked, as imposter sprites in UE4

This was an interesting test, but I knew it was going to be limited and time consuming to generate enough variety. 

Then I discovered Truesky. It's a plugin for UE4 that allows for the creation of very natural looking clouds, with automatic sun light control and atmospherics. It's also fully volumetric and controllable with blueprints. It runs great in VR, and they have an Indie licencing option. Boom! Clouds. Sorted.

View fullsize
Early Truesky test with a terrain ripped from Google maps. Promising!

Early Truesky test with a terrain ripped from Google maps. Promising!

Blueprints / UI

I realised fairly early on that I still had a huge amount to learn about UE4's Blueprints system. Mainly, how various blueprints should talk to one another. After I hooked up the headset/flight control I saw straight away some kind of sensitivity control should be exposed to the player so that the plane movement wasn't too twitchy.  I got started on a UI, and made a slider to control sensitivity. In VR games you really need to have any kind of UI as a physical thing in the 3D world, you cant just slap it on the screen with no distance from your eyes, otherwise it makes you want to puke and you can't focus on it. The Oculus Store has a nice UI interaction system where the selection cursor is locked to the middle of your view, so you just look at the thing you want to click on. I decided on the same thing for Flak Jack. I made my UI buttons, stuck them on a 3D widget, added the widget to sit a bit in front of my game camera, and then did a line trace from the camera to the widget to work out what button was sitting in line with my gaze. I added a crosshair graphic, and made the buttons change colour when hovered over. I decided to use the sensitivity slider purely as visual feedback on the UI - the user changes it with the left stick on the controller.  It's not a slider that you click on and grab. I did this because it makes it faster and easier to change when mid flight. Originally, the slider was visible whenever you call the game UI, but now it only shows up when you are actually in flight and call the UI.

View fullsize
Oculus style menu selection for VR UI, with slider feedback

Oculus style menu selection for VR UI, with slider feedback

Motion controllers / Jack IK

Flak Jack is a third person game. Jack flies standing up in the cockpit so he can shoot out over the top of the planes wing with hand held weapons. I wanted his arm movement to be in sync with how the player was moving the motion controllers. I set up some really basic arm IK, and did some calibrating and offset of the Hydra controllers, so that the player motion was offset from their position, to where Jack was standing in front of them. Eventually I'll need to do something where I get the players maximum reach / arm length and adjust the IK and Jack animation to match. The plan is to incorporate gesture controls for reloading and things like that.

July rebuild

After a couple of months of slapping things together, my blueprints and project were already getting messy even at this early stage. I stopped adding new shit and did some house keeping. I had originally just added lots of things as components on the flying pawn. The plane mesh, Jack, all the motion controller stuff, particle FX, the UI etc etc. I began to bundle things into their own blueprints and then added those blueprints as child components to the flying pawn. I then added all the required functions to each blueprint, moving them off the flying pawn. It's now much cleaner and logical and is more in line with how I should have done things to begin with. I began to get more comfortable with casting, and getting all the blueprints talking to each other. All rookie errors I'm sure, but I'm glad I caught them early.

Mission control

One goal is to make the steps from first opening the game, to flying an actual mission as seamless as possible. It needs to ease you in to things so you can get comfortable being in VR - once you are actually flying and shooting its going to get pretty hectic. The game loads up with you positioned just above the clouds. The idea is you pick a mission type and then various aspects of the mission are randomly generated, one of those being the clouds and time of day. So, before the mission actually starts, the game goes through a little 15 second sequence I'm calling the "pre trip". It gives the player a moment to get settled in. During the pre trip a timelapse happens and the clouds/sky changes, you get transported to the mission area, and Jack swoops in from behind you, does some funny things or starts telling a story, and you are gradually given control of the plane flight as it settles in front of you. It's visually cool, gives a chance for some character dev with Jack, allows time for the mission elements to load and basically takes you from point A - the start menu, to point B - the mission start in one smooth move. Sweet. I'm still sussing out the clouds timelapse and need to smooth out the travel speed, but the basic idea of it I think will work.

I created a blueprint called "Mission Control" that handles all of this pre trip stuff, sets all the parameters for the selected mission, and just generally initiates and keeps track of the current mission setup.

Art - I mean "Art"

Over the years my art skills have got pretty rusty, but I started to flesh out a few stand in art assets to act as place holders. The first of those was the logo, which I wanted to make look like trails in the sky. I also mocked up a super simple model of the plane you will fly with in the game - The mighty Bristol F2b.

View fullsize
OOOOOOOOOO purty

OOOOOOOOOO purty

View fullsize
Probably the best 3D model ever made

Probably the best 3D model ever made

Where it's at 

So that covers a lot about what's been involved in getting things to this point. Right now it's all still something I'm just bashing out a few evenings a week, I'm happy with the progress however. It's got a long long way to go, but here is a video of it all together.

 

<div class="sqs-video-wrapper" data-provider-name="YouTube" data-html="[youtube=://www.youtube.com/watch?v=hkbBLTV6CdI&w=854&h=480]">