5 Days Mechanic – Body Disposal

Today I tried to come up with the coding for one of the 5 Days mechanics. As I am still quite a novice at coding, I chose to produce the body disposal mechanic as I felt this could be relatively simple. This is where you, the protagonist, approach the body or person, pick it up and drop it off somewhere. If we decide to take this idea forward as the final one idea, I hope to try and expand on this mechanic by taking into account having to attack the object without being detected first. Even if we don’t take this forward, I may still try to attempt this anyway.

I haven’t used Unity properly in a very long time, so I started today by messing around with some of the settings. Through doing this, I managed to remember how to create a plane, create a 3D object, apply a rigid body etc; this made my confidence grow.
I started out by designing the code in my book as I struggle to take it straight to code. Using this technique has definitely helped me to improve and also showed me that I know more than what I give myself credit for. I would like to try and produce more pseudo code in order to bring my confidence levels up as well as help me to design better code through practice.

See Lectures/Crits/Talks book, light pink tab labelled 5 Days Body Disposal, pages 72 – 77 for all of my notes clearly.

From here, Dr James and I discussed how I was looking to make this a 3D game and so he helped me accordingly to work out what extra bits and pieces I would need in my code. Having Dr James to help me fix my code meant that I could add appropriate annotations and comments to the code with how I go about doing things for future reference. This will also certainly help me in order to practice and remember certain terminologies that I often forget the meaning of. I plan to use commenting in my code more in order to help me progress my skillset.

Here are the three tries of the prototype that I made:

I’m really pleased with myself as I have been learning through using the commenting element of Unity. Now that I know how to do this, I will be making sure that I make comments and notes in all of my code so that whenever I look back at them, I can figure out what I’d been doing straight away. It could also help me to create new code as if I look back, I can figure out what I can recycle or see if I can change anything.
The best thing too is now that I have these, I can create a library of scripts so that I can use them whenever I need to.
Below is the code:



Andy’s Workshop in the iLab – Flocking

I signed up to Andy’s workshop on Flocking that ran today. I didn’t know too much of what to expect but I learnt a lot and it was a mentally tiring and challenging workshop.

I made a document showing my progress through the workshop through screenshots and notes. You can find it on my memory stick in the folder called Coding – Andy’s Workshop iLab..

Andy first started by taking us through the brief basics of HTML and how to make general stuff. I hadn’t touched HTML in… about 7 years(?!) but found this really useful to look at as it ended up being really quite simple and something that I could easily do and make myself.

html tryout.png

The HTML tryout I did for fun

I found this workshop very helpful in many ways. I felt that this helped me to improve my confidence in coding with different languages. When we got to the later exercises, they definitely increased with difficulty but I was pleased that I still managed to keep a basic understanding of what was going on. 

This workshop also helped me to further understand our C languages that we’ve been working on with Dr James. It turned out that all of these languages tended to have similarities between them and whilst discussing with Andy how to program with JavaScript, he would ask about how you would do these sorts of things in C++ or C# and when Millie and Aaron would reply, it seemed to all slot together with more clarity. 

Doing this workshop has definitely helped me with progressing my core skills and it makes me feel more confident in myself that I can make things happen on a screen with code. I feel that I have definitely progressed recently in trying to understand coding languages. Taking the code to the laptop is about ‘translating it into French’ which I am not so good at right now. But these workshops have definitely helped to restore confidence in myself. It would be nice to try and work out how I could code some of the prototypes I’ve been given to do – such as the character customisation.

Dr James’ Lecture – Designing Code

Today’s lesson helped me a lot; Dr James has decided to do more of 1-1 basis with everybody in order to help us all with our own personal advancements. As there was a small handful of us that were looking to work on similar things, we were brought together as a group and began to revisit how to structure code from scratch.


I found this lecture really useful. I actually managed to design the code which gave me more confidence. I still am not quite sure how to go about doing the transition from designing code to the computer, yet as Dr James said, this designing process and working out the fundamentals is still an important part. 

After this lesson, I feel like I want to try and do more designing of code for simple things to get into practice. Maybe I could try and work out a prototype for my game this way from some of my ideas that I’ll be creating.

For notes on the lecture, see Lectures/Crits/Talks book, light pink tab labelled Designing Code, pages 61 – 68.

Idea Generation with Millie and James. 

See Sketchbook 2, blue tab labelled Idea Generation, pages 43 – 52 for Group Idea Generation.
See Sketchbook 2, blue tab labelled Individual Idea Gen, pages 53 – 60 for Individual Idea Generation.

We gathered as a group to brainstorm some of the areas that we were interested in and figure out how they could possibly connect. This was a fun and exciting exercise as we came up with a variety of different ideas and there are a few which we are excited to develop and see what happens with them already. 

We started using Andy’s workshop from last year in order to create a load of ideas, whether they were awful or not. It did work quite well so we’ve decided that as we are all going to be away from each other tomorrow, we shall individually work on more of this technique in order to come up with a variety of ideas when we combine Thursday. Thursday, we will come together again, collate everything we’ve worked on and try out some more ideation techniques.

The aim is that on Friday, we will go through all of our ideas and pick a maximum of 10 that we are interested in doing.  From there, we will use the next week to start prototyping the ideas and see what works and what doesn’t. This will help to inform our final three choices in the following week after that. 

Back to Basics – Dr. James’s Lecture

Today was a tricky day. It was clear that other members of the year were upset that we all had to go back to the basics when some people were understanding the previous lectures. I personally was understanding the concept and theory of the previous lessons however I was struggling to remember how to structure code and how to design code – it was having a domino effect when coming to exercises in lessons so I felt I did need to go back and revisit topics.

Unity coding screenshot.jpg

The task was to create a movement script and make the character jump too. Unfortunately, I hadn’t touched Unity in months (since last semester of last year) and had completely forgotten how Unity worked and even how to set it up. I took a severe knock to my confidence today which is frustrating.

I feel the problem for me is that I understand code when I look at it, to a degree, but when it comes to writing it from scratch, my mind goes blank; I don’t know how to structure the code. One lesson a week is definitely not enough time to learn coding and unfortunately, there really isn’t a lot of time outside of these lessons to push our learning due to demands from other subjects that affect grades. More tests like the one that Dr James made last year would help people like me a lot more and it would help my confidence to practise outside of uni. I know that it helped me a lot last year as I realised I knew more than I thought I did and in turn, it improved my confidence. Having these tests on a weekly basis or bi-weekly basis could really help coding to sink into those who are less confident. Even if it meant doing it in our free time, doing these tests for a half hour would mean that we can practise which could help us all code more efficiently. 

Dr James made a great help sheet which I will be keeping a firm hold of. See it in Lectures/Crits/Talks, light pink tag labelled Back to Basics, pages 57 and 58.

Header Files

Today, we learned about Header Files and how they are useful to us in Games Design.
A Header File is a bedrock when working on orientated programming. It helps create a blueprint for our class structure and only ever describes the ‘why’ in a situation, not the ‘how’. By using the header files and the matrices, we can build our own AI from this. It’s exciting, and I am interested in it especially seeing as I am looking into Bionics and how AI could change in the future. It would be nice to create a game with intelligent AI but I’m not sure at the moment.


I found the lesson today relatively difficult. I understood on paper what I was roughly doing, yet when it came to translating everything into code, I became quite confused. I’m going to plan to knuckle down over the next few weeks in order to make sure I understand what we’re doing in the lesson by looking over notes regularly to refresh my memory.

For notes on the lesson see Lectures/Crits/Talks book, light pink tag labelled Header Files, pages 44 – 52.

Markov Chains

This week, we looked into Markov Chains which use matrices to create incremental changes to base values. This is mainly used within economic statistics but it’s also really handy for creating AI. If you combine Finite State Machines (FSM – we’ve been learning these for three years now) and the Markov chains method, we can create individual and interesting AI.

The workshop we did where we used Pokemon as an example of Markov chains was slightly confusing as I haven’t played a lot of Pokemon and so wasn’t sure what everyone was going on about in most cases. I understand the actual chains principle so at least that’s something…

This session was useful as it helped to recap previous lectures we’d looked at and help to move this into applicable situations within Games Design. I feel relatively comfortable that I could design something like today’s lecture for an AI character. Depending on what direction my project goes in, I may try and prototype some FSM and implement the Markov chains method to show how my AI would react. I’d like to involve some innovative AI in whatever I do this semester as these sorts of NPC actions could help separate your game from someone else’s. 

For notes on the lesson see Lectures/Crits/Talks book, light pink tag labelled Markov Chains, pages 35 – 41.

XML Data Structures and Pointers

For the lecture today, we looked into Extensible Markup Language or XML where its only use is for structuring data into trees and branches. I say “only” but this makes up a lot of what we use and see today i.e. Amazon’s cataloguing of items etc. 
It was interesting and useful to learn about them, what they are and also about the lady who discovered it – Admiral-Doctor Grace Hopper. It was quite inspirational to see that even back in a time where women were not seen as equal to men, she fought for what she loved to do and believed in and is now the reason we have compilers. 

You can see notes in the Lectures/Crits/Talks book, light pink tag labelled XML Data Structures pages 16 – 19 for my notes in the lesson.


To begin with, we looked at the idea of creating a book collection/library. It really helped me to understand XML’s as we were breaking it down into sections of what a compiler can do and has the potential to do. It made me think about how we use this within games design and in turn, we had an exercise to make an inventory list with a consumable and non-consumable item. I felt that even though I didn’t quite finish it (or remember to actually include the consumable tags!) I did understand the majority which made me quite proud of myself and interested me in trying to make my own structures.

Above on the left is my attempt at the inventory exercise and on the right is Dr James’s example. It was informative to do the exercises and then learn from any mistakes that you had made.