Game Dev Log #3 (6/18): Player and Camera Movement

Another sprint has been finished, and it is once again time to a dev log.

Our last sprint focused on drawing our maze using only two different wall tiles.

In this sprint we have added player and camera movement, removed an annoying memory bug and also improved the frame rate of the game.

Player and Camera movement

Adding player movement was super easy, because we had already implemented a input handler using the Command Pattern.

The game is going to be turn-based in the end so the player moves one ’tile’ at the time.

Next up was setting up the camera movement. A key part of the game is that the maze is divided into smaller ‘chunks’ and that you are only able to see the chunk the player is currently in.

This means that the camera does not move around all the time but only when the player moves out of the current chunk and into a new.

We use this camera model to increase the puzzle feel of the game.

Still need a collision system though 😉

Improving frame rate

The game is developed on both OS X, Windows 7 + 10 and Ubuntu. And we always make sure that the game always works in all four.

On OS X and Ubuntu we write code in Emacs and compile the code using a makefile. On Windows however, we use Visual Studio.

In this sprint we first found that the game was surprisingly slow on our Windows 7 machine. This is also our oldest and slowest laptop, so I first tried to make different small optimizations to reduce the problem.

One thing I did was to move smaller things from the CPU into the vertex shader. This first introduced some minor visual bugs as seen below. I’m still not sure why it added a single extra black voxel for each voxel ’tile’.

But it didn’t really fix our frame rate problem.

I then booted the game up on our Windows 10 PC and found that the game was also really slow here. This was really surprising since this is by far our most powerful PC. At the same time it ran perfectly smooth on the same computer booted up in Ubuntu and on our MacBook Pro.

After a lot of wondering and googling it turned out that our problem was not within the game. The problem came from using debug mode in Visual Studio.

In release mode the game runs smoothly. However,  the debug mode can really slow down your application if you use C++ and the Standard Template Library (STL).

This might be fine in a normal business application, but not in a game which constantly updates.

Voxel robot bug

Finally I also created a new little voxel model. A voxel robot bug. The light blue on the back is supposed to be its energy storage. My plan is do implement a bloom effect in the rendering engine to emphasize this.

Next up is adding collision detection, a goal chest and measuring the time from the player enters the maze to the chest is found 🙂




Game Dev Log #2 (5/18) : Drawing the Maze

Yesterday we finished the second sprint for our maze game, so I figured today would be a good day for my second Game Dev Log.

We are working on a roguelike maze game. The maze part is currently our main focus.

Last summer I made a student project on algorithms for generating mazes and we started our last sprint with including the implementations I did last summer into this project. The rest of the sprint mainly focused on how to draw the maze for our game.

Voxel Wall Models

Since our game is using voxel graphics, I made two small wall models in MagicaVoxel. A center wall and a half wall.

To the right: center wall. To the left: half wall

We then use these two models to create the different wall types needed to draw our maze. Another approach would be to create all the types manually in MagicaVoxel, but we decided against this.

The reason for this was that while it might be faster to create them manually for the first types of walls, it could end up taking more time later when we want to add several different zones to the game.

All 15 wall types needed for our maze. These are all created by combining the center and half wall in different ways.

I used my notebook to sketch out the wall types we needed, and ended with 15 types which we then created using the center wall and half wall.

Our maze generation algorithm specifies the maze using ‘0’ for floor and ‘1’ for wall. To figure out which wall types should be used for each ‘1’, I implemented a filter algorithm. This algorithm looks at each ‘1’ in the maze and decides its wall type based on its neighbours.

We could then finally draw a full maze.

Comining the 15 wall types we can now draw a full maze

Why use voxels?

At the current state of the game, it might seem bad to use voxels for our graphics instead of normal 3D models.

There are two main reasons for why we have chosen to store our models as voxels.

First of all we really like voxels and love to learn more about how voxels can be used for different kinds of projects. I actually just finished a student project on data structures for storing voxels and I’m very eager to try out some of my findings in practice.

The fact that voxels are wonderful and intriguing might not be enough reason to base our project on them (or maybe it is?). However, we also plan to use the voxel models for more gameplay specific features. But more on this when we get to it 😉

Secondary sprint issues

The sprint we just finished mainly focused on drawing the maze using the voxel models. However, we also finished a few secondary issues.

First I created a cute little player model. A little person with a hoodie.

The algorithm which generates the maze, also creates a start position for the player. Our secondary issues in this sprint were to draw the player at the start positions and limit the view of the maze, so that only part of the maze around the player is visible.

Next sprint

We are setting up our next sprint tonight. From our current backlog I can see that the main focus most likely will be player movement and collision detection.

As part of the player movement we will also have to setup the camera so that it moves when the player moves out of the current view.


We also plan to work a bit more structured in the next sprint. If we look at the Burndown Chart from the last sprint, it is clear that we work a lot on few days.

In the next sprint we instead want to try to work on the game every day. Some days it might only be 20-30 minutes, but we hope that by looking at the project every day we will eventually be more efficient and also be able to divide the work more evenly between the days.

Burndown Chart from last sprint

Finally here is the first gif I’ve ever made 😉

Our little player is eager for us to add content to the maze.



Someone is eager for us to add content to the maze

Game Dev Log #1 (4/18) : Introduction

I’ve wanted to start writing development log regularly for a while now (this first post has actually been hiding half finished on the blog for more than 6 months now 😮 ).

So, instead of procrastinating on reddit looking for ideas on how to write a dev log, I finally decided to just do it 😉


I’m currently working on a maze game, which might also turn into a roguelike at some point. The game currently has no title, so at home we just call it AMazing.

This project actually started as an Arduino Game, but then I decided also to do a project on algorithms maze generation as part of my master degree, and the project out grew the capabilites of the Arduino.

However, I do plan to finish this simple version for the Arduino at some point.

This new and larger version also have several new features that the Arduino version does not. But I won’t reveal to much before I start working more on the gameplay.

While I looked into different algorithms for generating mazes, I rendered the mazes in 2D using placeholder art found at

Initial 2D maze

I implemented, tested, analyzed and compared a selection of algorithms and created a range of plots from the results for the project report.

One of the things I looked at, was the branching factor of the created mazes and how long sub-paths starting at each branching was.

One of several plots from the report I wrote on algorithms for maze generation

Based on this project I now have a selection of implemented algorithms ready to plugged into the game. How and which I will end up using is not yet clear. One idea is to have a Create Game menu which will enable the player to specify what settings to use when a new maze is generated. Such as few branches with long paths or many branches with short paths.

I try to work agile and scrum inspired and have chosen to use JIRA to plan out the project and the sprints. I like JIRA because it is easy to setup sprints and chose to only see tasks within a selected group in the backlog. It can also generate several useful reports which can be used to visualize development progress. But more on that another time I think 😉

Game dev log

So, this was a somewhat short introduction to the game project I’m currently working one.

Feel free to ask anything about the project, and I’ll try to answer as good as I can 🙂

Currently my plan is to write both overview dev logs presenting what I’ve worked on since last and also more in-depth posts explaining specific problems that occurred and how I’ve tried to solve them.


Check out the about page to find out more about who I am.

You can also follow me on Facebook and Instagram.

How to get started with biped robots – Bob the Biped

A couple of weeks ago I made a post with cool advanced humanoid robots you can make.

The skill level (and money) required for most of the projects was however relatively high.

So this week is about biped humanoid robots for beginners.

Biped robots

First we have to establish what a biped robot actually is.

A biped (bipedal) is a robot which walks on two legs in a human-like way. You can find both humanoid biped robots and non-humanoid ones. An example of a non-humanoid biped robot is Cassie the ostrich bot seen in the following video.

Another example is NABiRos which is also an interesting new take on bipedal robots.

No matter which kind you think are more interesting, the starting point is the same. A two legged robot with a minimum amount of joints per leg.

Bob the Biped

Enter Bob the Biped.

Bob is the most simple biped robot you can make. He has two legs and require only four servos.

The original Instructable for Bob can be found here.

Since the first original Bob the Biped was build, many other versions of him has emerged. Several also include an ultra sound sensor to make it easier to interact with the robot.

I have looked at a lot of tutorials for these robots, and my personal favorit for beginner is this one for Otto DIY. The best thing about this version is that the Instructable has a lot of pictures of how to assemble the robot. this is especially helpful for beginners.

But there are many other versions as well!

Otto is actually programmed using code from the robot Zowi by BQlabs. However Zowi uses servos that are a bit larger than the micro servos used for both Bob and Otto.

If you are a little more adventures you can try to combine parts from different versions and create you very own Boto or Zoob. Or if you have mastered 3D modelling you can try to create your very own design.

My first biped robot
My own Otwi

I’m currently building a combination of Otto and the Zowi mini (Otwi 😉 ). However, I’m currently spending a lot of time on my OpenGL 3D game, so my Otwi is still missing a proper brain.

I have tested simple walking routines on it by attaching and Arduino Uno on its head. But my plan is to make a custom made PCB which will fit nicely inside the head.

Links to files on Thingiverse:

Ready to start making your own simple biped robots?

Here are the direct links to the 3D files for the projects mentioned in this post.

Please don’t hesitate to share what you have made once you finished!

Bob the Biped

Otto DIY


Mini Zowi



Building an Arduino Game System 1.0: Setup and schematics

Posts in this series so far:

  1. Introduction
  2. Setup and schematics
  3. Making a Breakout Game (coming soon)

Setup and Schematics

In this first blog post on my Arduino Game System project, we will look at the basic schematics and ideas the project is based on.

Just like most other Arduino projects, the Game System consists of three parts; input (sensors), logic and output.

Input (sensors)

As an input for the Game System we obviously need some buttons, so we can control the players, navigate a menu etc.

In this first version of the Arduino Game System I have chosen to have six different buttons, four movement buttons and two action buttons.

I have used simple tactile switches in this version of the system. Small 6 mm switches for the direction buttons and the larger 10 mm ones for the action buttons. If you decide to make some kind of casing for your Arduino Game System later on, the small switches fits perfectly under a d-pad like the one on the original Game Boy.


The logic in this system is done on an Arduino Uno. But you can also use other equivalent boards.

For some boards you may have to change the output pins for the composite signal. In this case remember also to change the pin number in the TVout library.


What kind of output you need of course depends on the screen you are going to use.

For this first version og my Arduino Game System, I used a small car rear view monitor I found on Amazon. This is a NTSC/PAL TFT screen which requires a composite video input. For this reason this version of the Game System will have a composite tv signal for its output.

To generate the composite signal I used the Arduino TVOut library.

After some time (and a lot of game code) I did have some problem with this library. But for smaller games this if just fine to begin with. I would like to make a new library for composite video signals at some point, but it is not really a priority at the moment.

To generate the composite video signal you need to resistors. Each connected to a digital pin in one end and connected together to form the signal in the other end as shown in the image above.

Which resistors and pins to use are specified here. As stated previously you may have to change the output pins when using other boards than the Arduino Uno.

Making the games

This post was about the setup of the first version of my Arduino Game System.

If you have some experience with Arduino and programming you might be  able to make your own game right away.

Here at GitHub I have put a bunch of classes which can be used as inspiration for the basic structure of your game. Please note that this repository is a work in progress and meant for inspiration and testing – it might not all work perfectly together all the time 😉

For those of you who are looking for more help getting started with making Arduino games, I also plan to make a small in-depth blog series on how to make a simple Breakout/Arkanoid game for the first version of my Arduino Game System.

I hope you found this post useful 🙂


Advanced 3D printed humanoid robots you can build

This friday is all about advanced 3D printed humanoid robots, that you can build!

As the title says, these are advanced projects. And thus mostly meant as inspiration and motivation. In the end of this post you will however find information about an entry level bipedal robot.

InMoov – life-sized and open source humanoid robot

This first robot is huge! And might not be the first project you’ll build. Actually you might never get to build this unless you have a lot of money and spare time.

Or you could be lucky and work at a place that would find this kind of project interesting.

InMoov was developed by Gael Langevin who is a French sculptor and designer.

If you watch the video below and totally fall in love with InMoov, but don’t have the resources to make all of the robot, dont worry. You can easily start with the fingers, a hand and then maybe a full humanoid robot arm!

For more information about how to get started with InMoov, take a look at .

Poppy – open source humanoid robot (83 cm tall)

This one is so cute, and I totally want one!

A humanoid robot like Poppy is absolutely my ultimate goal.

The smart serial servos used does however make the price for a Poppy a bit higher than I can afford at the moment 😉

But maybe once I’m done with my masters in Computer Science and Engineering and hopefully get a well paid job.

The Poppy humanoid would however be a cool university project!

Luckily the Poppy Project has also made it relatively easy to get started without building a full (super cute) Poppy.

Instead you can start with the Poppy Torso or the Ergo Jr robot arm.

For more information on how to build these project go to .

Darwin-OP clone (45 cm)

This next robot is one that is used in some of the soccer Robocup competitions around the world.

In the video below is a walk test of a Darwin-OP clone which is made using these instructions on instructables.

Just like the previous robots this can be an expensive build because of the smart servos used.

If you have the cash and don’t want to make it all from scratch, it is also possible to buy an original Darwin-OP (or ROBOTIS-OP). One place to buy it is here at .

Now if you like the Darwin robot but can afford the “real” thing, it is also possible to buy a Darwin-Mini.

The Darwin-Mini is a cute smaller version of the original Darwin-OP and should also be easier to get started with.

Bioloid humanoid robot clone (39.7 cm)

Feeling a bit frustrated with the prices of the above robots?

But you still really want a top notch humanoid to program and mod so it can be your best friend/assistent/what-ever ?

Then this next project might be for you.

While the price is still not student friendly, it is a big step down from the previous robots.

The Bioloid still uses smart serial servos, but a variant that is a bit cheaper than the ones used for Poppy and Darwin.

Actually the instructions on instructables for this Bioloid clone was made by the same guy how made the instructables for the Darwin clone. His reason was that even though it is cheaper the build your own Darwin than to buy one, he knew that the price tag was still to high for most people.

So he made this instructable on how to build a humanoid robot for under 1000 USD.

Entry level Bob The Biped

Okay so all of the robots above might be well beyond your paycheck?

Luckily there are other places to start!

But first I have to note, that the reason that the robots are so expensive is, that it requires a lot of servos if you want to make a robot with enough joints to make it seem human-like.

In addition the needing a lot of servos, the servos used are smart servos which can also have a higher price tag than normal servos.

But fear not!

It is of course possible to make smaller and more simple bipedal robots. These are also good practice while you save up money for those 17-18 smarts servos you need for a bigger robot!

A good place to start is to make one of the various versions of Bob The Biped. Bob only requires four regular micro servos 🙂

I hope the videos in this post were inspirational.

You might not be able to go out a build one of the first four robots any time soon. But my intension was mostly to show what is possible, and maybe give some inspiration and motivation for you to start working on and learning about bipedal humanoid robots 🙂

I am currently building a version of Bob the Biped myself. When it is done I will try to make a post about the build, how to get started and also ideas on how to make a simple biped robot more advanced.


Featured image credits:

Poppy Project / Rafiaa Khaddhar

Photo M. Lapeyre

Can be found here.

Building an Arduino Game System: Introduction

Earlier this year, I made an 8×8 LED matrix Arduino breakout game. The game was inspired by the classic Atari Breakout, but limited to 8×8 pixels for the display.

It was a fun way to test the LED matrix and also show how useful these small LED matrixes actually are!

The project also got my interested in other ways to create more advanced Arduino games and maybe even some kind of Arduino Game System.

Posts in this series so far

  1. Introduction
  2. Setup and schematics
  3. Making a Breakout Game (coming soon)

Arduino Breakout

As a start I made a new Arduino Breakout Game using a small tv screen as the display. For this project I used the Arduino TVout library to generate a composite video signal in software.

I will be making another blog post about this game at some point, but for now all I have is some pictures and a video of the ball movements from when I started making the game.

Arduino Game System

After working on the Breakout Game above I wanted to start working on a more dynamic game system. This new system will have a start menu where you can choose what game to play, display high scores etc.

I usually only write about my projects after they are finished, but since I have had some very nice feedback on the initial images and videos I have shared on both my Facebook and Instagram pages, I have decided to make a blog series about the project while I am working on.

This blog series will not be a regular tutorial or How-To, but instead give an insight into what I am working on, the difficulties I encounter, the possible solutions to potential problems and the design choice I make.

Stay tuned for the first blog post which will include the schematics and the base code for my first Arduino Game System.

Until then here is a short video of the Arduino game I am currently working on.



How to add jumper wires to your dc motor – no soldering

In this blog post I will present you to a simple no-soldering way to add jumper strips to you dc motors.

This method can be used when you just want to try out a new idea or if you are a beginner with no soldering iron.

For more permanent connections, soldering could however be required.

What you need: 

  • dc motor: the motor you want to connect to your project
  • 2 x jumper wires: make sure one of the ends (male/female) fits to where the motor should be connected later
  • Gaffa tape
  • Wire cutters

Step 1: Strip off insulation

First we have to clip off one of the ends of the wire. Make sure that you clip off the right head, and not the one you need later to connect the motor to your project!

After removing the end, strip off 2-3 cm insulation.

The wire is now ready to be attached to the dc motor.

Step 2: Attach wire to motor

Insert wire through hole at motor.

Fold the wire back onto itself and twist it together.

Be careful with this part. The metal connectors on the motors can be quite fragile, so don’t move then around to much.

Add a small piece of gaffe tape to strengthen the connection.

Repeat step 1-2 for the second wire.

Tips and tricks

Congratulations you have now added jumper wires to your dc motor!

Using this method you can now connect your motor to a male/female header on your project.

Remember that the connectors on the motor can be fragile, so you should be careful not to pull to much in the wires after they have been connected. You could also tape the wire to the side of the motor to decrease the chance of pulling off the metal connectors.

3 Maker’s Muse videos to watch when starting 3D printing

If you just bought your first 3D printer or is thinking about it, these three videos are a must see!

Maker’s Muse is a youtube channel focusing on 3D printing and you will find a lot of valuable information here.

I have been watching tons of videos on 3D printing on Youtube the last couple of months. And about two weeks ago we finally got out own printer 🙂

The following three videos are the ones I found most useful starting out.

10 places to get FREE 3D Printing Files

A good way to get to know you printer is by printing different small models.

This video introduced 10 places where people share free 3D models.

Be sure to check the license of the models you download and give credit where it is needed 🙂

The Best Way to Orient you 3D prints

Okay so you are ready to print your first model, but how should it be oriented when printing?

This video introduces you to pros and cons of different orientations.

Stop the stringing with Retraction

One of the first problems I experienced with my prints was stringing.

Stringing is when there are strings of filament in places where they should not be. This happens when filament is oozing out of you nozzle in places the printer should not print.

The video bellow is an introduction to retraction which can be used to limit stringing.

I am definitly a fan of Maker’s Muse, and if you liked the videos above I would encourage you to like their youtube channel for more cool content!

A note on Slicer software

To prepare a 3D model (in .stl format) for 3D printing you also need a slicer software which help create the .gcode for your printer.

Though this is also a big part of 3D printing, I have not included a video about it in this post.

When you first get your printer it doesn’t matter much which slicer software you use. Instead of spending a lot of time selecting the perfect slicer, just pick one and start printing models.

After the first couple of prints you can start looking into different slicer software if you are not content with what you started with 🙂


Happy 3D printing!

Copenhagen Maker Festival 2016

Copenhagen Maker Festival was on this weekend. I went with the family on Saturday.

Here is some of the highlights from our trip.


We arrived around shortly after they opened. The atmosphere pictures are from when we arrived. After lunch the place was packed!

copenhagen maker

copenhagen maker

No maker festival without 3D prints

The 6-year-old maker was really exited to finally see a 3D printer in person. Luckily there was a lot of models at both Labitat and

When I first told her about 3D printers, her response was that she wanted one, so she could print a Pikachu. had this one on display at Copenhagen Maker.

img_1061 also had free 3D printed diamonds. Being able to print diamonds is not on the 6-year-old makers list of reasons for buying a 3D printer.
3D prints at
3D printed shoes at
My favorit 3D print at the festival
3D prints at Labitat
The 6-year-old maker is exploring 3D prints at Labitat
3D prints at Labitat
More prints at Labitat

MyLogo Game – with DIY Hama beads

Making a Logo for the My Logo Game
Making a Logo for the My Logo Game
my logo
The point board for the My Logo Game

IoT pen-plotter (

Final adjustments before the 6-year-old maker had her portrait printed on the IoT pen-plotter

Printed ceramics

This was really cool. Making ceramics in to ways: the old school way and using a 3D printer.

Old school ceramics and 3D printed ceramics. Laura Penman

Polygo: Geometric Creatures

Really cool laser cut triangles which can be puzzled together to form many different geometric shapes and creatures.

These were also used to make a huge LED flower, which can be seen in the video at the top of this post.

Polygo: Geometric creatures. Simion Iulian Belea
Of course all the signs at the faire was laser cut.

DIY t-shirt printing

Makershirt brought two heat presses so the kids could make their own t-shirts. Definitely the 6-year-old makers favorite DIY-activity at the festival.

DIT t-shirt print at

My favorite DIY at the Maker Festival

InfinityPV brought lots of their cool flexible printed solar cells. I am definitely using this for some kind of wearable project at some point.

Inside it generates 3V and outside it reached 6V.

Defiantly the coolest freebie at the festival!

Time for a break

Of course we also needed a lunch break at some point. Or well, someone would much rather play than eat 😉

She wore a dress I made out of an adult t-shirt we bought at the DTU RoboCup competition earlier this year.

Active break at the playground
Active break at the playground

Thats all for now.

I am going to Berlin Maker Faire next weekend, so expect more cool maker festival pictures and videos in October!