My BSc in Computer Science – Results Summary

The past three years at the University of Hull have flown incredibly fast; A good sign, that I have thoroughly enjoyed my time there studying for my BSc in Computer Science with Games Development. In fact, it was probably one of the best decisions I ever made, despite how hard it was to take up the challenge as a 27 year old with commitments and nearly 10 years since prior academic study.

My plan will now be to continue on at Hull University to study a post-graduate MSc degree in Computer Science. Relocation and seeking employment will be on the cards aferwards, but I can rest assured having ‘put my all’ into the past several years, I am proud of the results I have acheived and I certainly never expected to do as well as I did, acheiving a First Class honours degree. Below is a summary of my results from the past three years:

Year 1

Module Mark Credit
Computer Systems 73 20
IT and Professional Skills 80 20
Programming 1 92 20
Programming 2 96 20
Quantitative Methods for Computing 87 20
Software Engineering and HCI 77 20
Year 1 average

Year 1 average

Year 2

Module Mark Credit
2D Graphics and User Interface Design 89 20
Advanced Programming 83 20
Artificial Intelligence 78 20
Networking and Games Architecture 88 20
Simulation and 3D Graphics 94 20
Systems Analysis, Design and Process 83 20
Year 2 average

Year 2 average

Year 3

Module Mark Credit
Commercial Games Development 81 20
Games Programming & Advanced Graphics 94 20
Mobile Devices and Applications 83 20
Visualization 86 20
Development Project 88 40
Year 3 average

Year 3 average

 

A ‘Mature’ Reflection:

To any people out there reading this who may fall into the mature student catagory of being a little older and thinking of studying a degree, I would say this; If you are passionate about the subject that you want to study, have proven your interest in it through personal projects, and can cope with the lower standard of living while you study, then go for it and don’t look back. It’s not just about career development, but also a time of personal acheivement and self discovery, where you can find much about your own abilities that perhaps you never knew you had. I think many people can muddle on in life not knowing if they would be any good at ‘this’ or ‘that’. A formal degree can help answer this, giving you confidence in that discipline, which can be it’s own reward. When you realise that generally speaking, unless your lucky enough to be the next Einstein, people achieve great things not through raw intellect or genius, but ‘hard work’ and effort. In this regards, mature students probably have a motivational advantage, since they have more to lose, less time to dawdle and life experience to help them focus.

 

Advertisements

Halloween Pumpkin’s – GLSL Programming

ACW2.rfx-Pumpkin Party

 

For the Advanced Graphics module as part of my BSc in Computer Science, we were tasked to create a 3D scene with a theme of a ‘Halloween Pumpkin Party’. The scene was produced using RenderMonkey and programmed via GLSL vertex and fragment shaders.

The scene displays a variety of shader effects including: Cube mapping, displacement mapping, height bump-mapping, parallax bump-mapping, fragment based-lighting, particle systems, texture bill boarding, smooth-step vertex transformations and stencil masks.

Below is a brief description of each component of the scene and how it was implemented.

Enviroment

Cube Mapped Skybox

I created a new cube map using several textures by creating a DDS file using the ‘DirectX Texture Tool’. The cube map was then applied onto a cube model in RenderMonkey.

Terrain Displacement Map and Height Map

Terrain Displacement Map

Terrain Displacement Map

The terrain features texture displacement mapping, a height bump map and fragment lighting. It was made using a single tessellated plane with a terrain texture. In the vertex shader I displaced each vertex along its normal using the texture colour values. I applied a uniform coefficient to control scaling.

A separate texture is used for bump mapping to create a grass effect. The height map was done by transforming the view direction and light direction into tangent space via a matrix. In the fragment shader, I retrieved the height map data, calculated the difference between two pixel samples and determined the normal for each fragment. All other objects that use height bump maps in the scene are done the same way.

Dispersed Fog Particle System

Fog Particles

Fog Particles

The fog is implemented using a particle system and quad array. A time coefficient is first calculated and then another coefficient used to progressively spread the particles apart from each other. Each quad in the system is ‘bill boarded’ to always face the view, which is achieved using the inverse view matrix. The fog colour transitions across the texture by decrementing it’s coordinate using the timer resulting in multi hued particles. A smooth fade is added around the edge of each quad to help it blend better. By increasing the size of the particles, lowering the speed and extending the particle system range, I created the above effect.

Fireworks Particle System

Firework Particle System

Firework Particle System

The fireworks use the same principles as the fog except using a different algorithm. All particles start on top of each other, ascend into the air, and then spread apart, slowly drifting down. This is achieved by setting an initial velocity, it then checks if each particle is below the explosion threshold. If it is, it increments the particles with positive velocity. If not, it decrements the particle by the negative velocity and spreads them apart over time.The particles slowly fall back down.

Pumpkins

Pumpkin 1

Cube Mapped Pumpkin

Cube Mapped Pumpkin

Features:

  1. Cube mapped.

Each fragment is coloured using a reflection vector to access the texture data from the cube. The shape is a 3D model.

Pumpkin 2

Parallax Bump-mapped Pumpkin

Parallax Bump-mapped Pumpkin

Features:

  1. Parallax Bump Mapping (normal\height map)
  2. Non-uniform vertex transformation light flickering.
  3. Flame bill board.
  4. Fragment lighting.
  5. 3D model used.

The parallax bump-mapping gives a nice bumpy surface using a simple brick texture. The is effect achieved in the fragment shader by retrieving the normal and height texture data and then correcting the texture coordinate.

I created a nice lighting effect to simulate flickering flame light. It works by displacing the normal slightly based on a sine function. This is done on all flame pumpkins.

Flame

Flame billboard

The pumpkin flame is created using 3 different textures, a shape , colour and a noise layer. The vertex shader billboards the quad and in the fragment shader, the shape layers are animated and transformed.

Pumpkin 3

Stencil-masked Spherical Pumpkin

Stencil-masked Spherical Pumpkin

Features:

  1. Stencil masked cut-out holes.
  2. Smooth step transformation from a sphere. Top is removed.
  3. Height Bump Mapping.
  4. Non-uniform vertex transformation (breathing, veins swelling, light flickering).
  5. Flame bill board.
  6. Fragment lighting.

The face is made using holes that are cut out using a simple face texture as a stencil mask and then discarding fragments. The pumpkin shape is made from a basic sphere that has been stretched and the top removed in the shader.

A breathing effect has been added where the veins on the texture swell when the pumpkin exhales, this is achieved by applying a sine function to the bump normal. The breathing is done using a ‘smooth step’ sine function on the lower vertices.

Pumpkin 4:

Glowing Pumpkin

Glowing Pumpkin

Features:

  1. Glowing eye and mouth holes via blended billboard.
  2. Glowing aura via billboard texture.
  3. Non-uniform vertex transformation light flickering.
  4. Fragment lighting.
  5. 3D model used.

The glowing eyes and mouth are made using separate passes. It is done by bill boarding a texture and blending it over the holes. A direction is calculated so that it only glows when it’s looking at the camera.

Pumpkin 5

Transformed an displaced pumpkin from teapot model

Transformed and displaced pumpkin from teapot model

Features:

  1. Smooth step transformation from a teapot. Handle and spout translated inside.
  2. Wings extruded via smooth step and animated.
  3. Displacement mapped spikes.
  4. Hovering animation.
  5. Height Bump mapped fur.
  6. Fragment lighting.

Shape is made by translating the spout and handle vertices inside the pot. The wings are extruded via smooth step to make them curved. The spikes are made by deforming the vertices along the normal based on a texture. The hovering is done by applying a sine and cosine function to the vertices x and z components, the wings are similarly animated.

Gravestones

GravestoneSimple 3D models featuring bump-mapping and fragment lighting.

Summary

The project was challenging and very fun to work on, allowing me to learn many different shader rendering techniques and effects that are a staple in modern graphics and games programming. Using RenderMonkey allowed focus to be directly on shader programming and not the OpenGL framework i.e handling model loading and vertex buffers etc, which made sense considering the limited allocated time for the coursework. I was also very pleased to have received a mark of 90% for it! It really goes to show the power and variety of what can be achieved purely with shaders.

Dungeon Master – An Iconic RPG

Box Art

Box Art

Aged probably no more than 6, I looked on in excitement and fear at the Amiga monitor. My parents were playing Dungeon Master again, it’s labyrinthine dungeons, fiendish puzzles, stunning graphics (for the time) and always death, waiting around the next corner.

Dungeon Master was a pivotal game of my childhood, it taught me how real and immersive games could actually get, despite computer limitations. Using a 2D perspective trick, it could render a seemingly 3D environment as if seen from the eyes of the player. This of course was an illusion, but it did it so effectively, that it stood out back then with hugely impressive visuals. It wasn’t just nice to look at though; featuring groundbreaking level design and puzzle concepts, being brutally difficult but still rewarding; there was something about it that left a lasting impression on you. It was a little like the Dark Souls of it’s day.

Although there had been other well known ‘dungeon crawler’ games (as they came to be known) like Bard’s Tale and Wizardry, it was DM that really culminated the best attributes of the genre, distilling it into what is in my opinion the best of the lot, even to this day. It’s no coincidence that Almost Human’s ‘Legend of Grimrock’ in 2012, cited Dungeon Master as large inspiration and something that is clearly evident having finished Grimrock and noticing many ‘tips of the hat’ to DM’s puzzles, mechanics and creatures. All those puzzles of putting an item on a pressure plate to close a pit, or placing a torch in a wall sconce to open a secret door hearken back to this era.

DM was in fact the largest selling title of all time for the Atari ST, whose version differed only mildly from that of the Amiga, with the latter featuring improved 3D sound effects where most noticeably, you can hear creatures moving around with unnerving effect.

Using the free Amiga emulator WinUAE the past week, I have finally finished Dungeon Master after all these years. I loved every second of it, scarily so, because I was telling myself continually throughout, “why am I playing a 27 year old game in this day and age?”. Irrespective of the answer, I had more fun playing it then most state of the art games I have played recently! Why? Well, many reasons, the challenge and immersion are two, but ultimately, I guess I’m a pretty hardcore gamer and there’s just something about playing old school classic RPG’s, a charm or ambiance if you like, akin to rolling that dice in a pen and paper D&D game. I’m sure many can empathize with that.

A pack of skeletons.

A pack of skeletons.

Dungeon Master does have a story and plot, though sparse and not a driving force for the progression of the game. It revolves around having to descend into the depth of the mysterious dungeon and find an artifact known as the ‘Firestaff’, as tasked by your master ‘Lord Order’. Ultimately, if your party survive the horrors long enough, you come across writings detailing the evils that will occur should you complete this quest and instead come to realise that you must descend to the deepest depths of the dungeon, combine the staff with the ‘power gem’ and defeat ‘Lord Chaos’ (think Sauron), restoring ‘Balance’ to the world.

You start the journey in the ‘Hall of Champions’, a place at the start of the dungeon where you can look upon windows on the walls and see magically suspended heroes, whom you can either ‘resurrect’ or ‘reincarnate’ to join your party, up to a total of four party members. Resurrection ensures the character maintains it’s identity, combat skills and experiences whereas reincarnation allows you to rename the character, forfeiting their skill set, but gifting them enhanced physical attributes so to enhance learning and allow you to shape the character as you see fit. Ultimately, the tried and tested composition of two fighters at the front, a priest and a wizard at the back worked wonders for my play-through, though having four ‘jack-of-all-trades’ is viable too. As 2012’s Grimrock, the party moves through the dungeon in 1st-person view in a 2 by 2 formation, meaning that only the two members of your party at the front can reach enemies with melee weapons, with the back two having to rely on ranged, throwing weapons and spell casting. Consequently, only the front two will take damage from the front, and if a ‘baddie’ creeps up behind you, your squishy casters won’t be very happy. Part of the the games meta strategy, involves you being able to change your players around in the formation at any time e.g if your front fighters get wounded, you can swap them out with the back.

Character Inventory.

Character Inventory.

The predominate theme of the game is undoubtedly ‘survival’. Staying alive is really, really not an easy thing unless you have learned the tricks and techniques generally gained after many horrible deaths, whether that be to the jaws of giant worms, starvation or plummeting down a pit arriving several levels lower than you could possibly hope to deal with. The only items you have at your disposal are those you find along the way, and that way is strewn with illusory walls, guarded chests, locked doors and secret passages that without consulting a guide or a printed map, you have little chance of ever finding yourself (hand holding pfff who needs it?). Even basic concepts we all take for granted in games today such as being able to SEE, is a premeditated game mechanic in dungeon master, where the dungeons are pitch black without a light source and torches are scarce, making the use of a wizard or others with the skills to cast ‘light’ spells essential.

One of the  most memorable mechanics which is still pretty innovative today is the magic system. To the right side of the screen are a bunch of runic symbols. The boxed game’s manual documented an alphabet of these symbols describing there purpose. As you cast a spell you first choose a rune representing the ‘power’ of the spell, would you cast a short duration spell or a potent offensive spell for instance? Then sequentially you chose the spells ‘elemental influence’, ‘form’ and ‘alignment’. It all sounds rather complicated but when you know off by heart that a weak fireball is LO FUL IR and a potent healing potion is PAL VI, it starts to become second nature, especially when you realise you can drop the power level if your priest is low on mana and make a weaker healing potion like LO VI for instance. In combat, you would be expected to click these runes in the correct order at the heat of the moment, you soon realised that if you didn’t ‘get gud’ and memorise them, then you simply got ‘dead’. In a funny kind of way, it really did feel like you were learning magic and having to go through the motions to learn and cast the spells your party depended on and I love that.

These runes are used to cast all the games many Wizard and Priest spells.

These runes are used to cast all the games Wizard and Priest spells.

Other mechanics such as food and drink meters for each character really puts that hanging dread over your party for the entirety of the game, since you never know when your next meal is coming up and when you’ll see a fountain again to refill your water skins. Realising your lost deep somewhere with no water left and down to your last couple of hunks of meat is pretty terrifying. Luckily though, some of the critters are edible if you can kill them, ‘Screamer Slice’, ‘Worm Round’ or ‘Dragon Steak’ anyone? Yum!

A water fountain, always a welcome sight!

A water fountain, always a welcome sight!

Having finally finished the game after all these years, I felt an immense sense of accomplishment because it’s a game that I grew up thinking was simply too tough for me to contend with, and to be fair, me being less than 10, it probably was! The end showdown with Lord Chaos is no simple matter. Once you have collected all the ‘Ra keys’, broken into the vault of the Firestaff, defeated it’s Stone Golem guardians and retrieved it, you then have to descend to the last level, defeat a wingless dragon and free the power gem with a spell you better have learned along the way or your buggered! (*cough* Google). You then must combine the staff with the gem, creating an ultimate weapon and then go back up a level and find Lord Chaos. Using the staff’s power you must surround him with ‘Fluxcages’ and finally ‘Fuse’ him to restore ‘Lord Balance’ and beat the game. If that sounds straightforward, it really isn’t, especially considering even if you do figure this all out on your own from a subtle hint in an very well hidden scroll, you have to do all this while being attacked by demons, black flame elementals and Chaos himself flinging fireballs at your face!

Defeating Lord Chaos and restoring Balance.

Defeating Lord Chaos and restoring Balance.

I’m currently now playing through it’s sequel ‘Chaos Strikes Back’ (Yes…it really IS called that) and it is unbelievably hard, as in Dark Souls has nothing, not a bean compared to this in terms of difficulty. CSM will eat you alive and then spit out your regurgitated remains for a second helping. Firstly, the sequel starts at the same difficultly level that DM ends at. You can import your characters which you may think will help and sure enough it does a little, but little prepares you for the first 10 seconds of the game which pretty much goes like this:

“Ok, let’s go, hmm it’s pitch black…where am I? My party is naked with no weapons…I can hear things moving around me…let me cast a light spell. That’s better! SHIT there’s four armoured worms in here with me and no exits…no wait, SIX worms…EIGHT….I’m surrounded…can’t move….DEAD.”

That’s your first taste of Chaos Strikes Back, shoved into an infested pit of worms with no weapons and no obvious way out, but like Dark Souls, I still love it.

As reported in 2012 in a Rock, Paper, Shotgun article here, one chap amazingly spent 6 months, eight hours a day of his own time, programming 120,000 lines of code to port the Atari ST version, creating a C++ executable version that runs today on any modern PC. It can be found here free: Chaos Strikes Back for Windows (and Linux, MacOS X, Pocket PC)

For those used to emulators, by getting hold of the Amiga .adf ROM file (basically an image of the game disk), you can run it in WinUAE (my personal preference for the better sounds) but ultimately, only ex-Amiga junkies would likely do this over the ported PC version :D.

Dungeon Master is a truly iconic game that has undoubtedly influenced many great games, not just across the dungeon-crawler and RPG genres like the classic ‘Eye of the Beholder’ series or recently the ‘Legend of Grimrock’, but also modern popular AAA titles such as the Elder Scrolls. It’s a testament to it’s influence that the game still has it’s own updated Encyclopedia site: http://dmweb.free.fr/  and even an online message forum with an active and thriving community: http://www.dungeon-master.com/forum/.

I would encourage anyone who is curious about classic RPG’s games, interested in why modern games are like they are and all that jazz to check out old titles like Dungeon Master, because although the graphics leave much to be desired by today’s standards, the game play is still truly as good as it ever was. It’s clear there is still much to wonder and marvel at, in both game design and execution in this old gem.

My party in the hall of fame after beating the game!

My party in the hall of fame after beating the game!