Category Archive: C++

Nov 03

Mysterious DirectX Release-mode Crash

Background I’ve recently been working a lot with Microsoft DirectX and have found myself converting one of my DirectX 10 projects into DirectX 11. During this process, I ran into a very strange problem with the DirectX Math library, which supersedes the old D3DX maths related stuff. Note: I’ve removed all comments and definitions from …

Continue reading »

Dec 31

Generating a Maze

When I was coming up with ideas for my Christmas game this year, I ended up thinking of one that would work best with procedurally generated (i.e. generated using a particular algorithm, but using randomly generated numbers etc. for content). This post shows some of my ideas and techniques for creating such a system, and …

Continue reading »

Jul 25

PurpleEngine Released!

Catching Game Example

While at university I used an engine created to help beginners learn game programming, that was designed to be able to make 3D games very easily with little knowledge of how things are working. It was a great engine, but as I have bit of a passion for 2D games, I decided to attempt to …

Continue reading »

Apr 19

Make More!

I’ve already written about using make files to compile programs, but only briefly. This little tutorial should expand on enough for you to be able to use make files yourself. If you haven’t already then read this first. As explained in the previous post, a make file is pretty much just a set of instructions …

Continue reading »

Mar 08

Pointing at Things That do Stuff!

… that is, pointing at functions. Introduction Pointers in C++ are probably one of the most powerful aspects of programming using the language. They can allow you to easily pass data around with using additional memory and provide a very efficient way to access variables from elsewhere in the program. But, that’s not all they …

Continue reading »

Feb 19

Organising Classes

This tutorial explains how classes should be organised in separate files and what the benefits of this are. The Vector class from the previous tutorial is used, if you haven’t read it you should go there first: link. Introduction As discussed in the previous tutorials classes are a very useful part of programming in C++. …

Continue reading »

Feb 09

Vector Class

Dot Product Formula

This tutorial shows how to create a basic vector class for vectors in C++. If you haven’t already, read the previous tutorial about the basics of classes here. Introduction Vectors are very important in many computer programs involving graphics, and are especially crucial in games. Having a vector class makes them easier to use and …

Continue reading »

Feb 07

Classy Programming

A step-by-step introduction to classes in C++. Introduction Classes are a very useful feature in programming. They allow for an easy and efficient method to use an object-oriented approach to programming, and also help to create more structures and organised code. Not only that, they save a lot of effort by removing the need to …

Continue reading »

Feb 04

Making Things

As you have have read in my previous blog post, I’ve been using Linux quite a bit now. So I’ve been experimenting with how to compile my programs on it and so I’ve been learning to use Makefiles. In software development, make is a utility that automatically builds executable programs and libraries from source code …

Continue reading »

Jan 09

Operator Ad-Hoc Polymorphism

… More commonly known as Operator Overloading. a specific case of polymorphism in which some or all of operators like +, =, or == have different implementations depending on the types of their arguments. Sometimes the overloadings are defined by the language; sometimes the programmer can implement support for new types. (from Wikipedia) I’ve been …

Continue reading »

Older posts «