-
C++11 / Boost: Multi-threading – The Parallel Aggregation Pattern
In the first part of this series we looked at general multi-threading and multi-core programming concepts without getting into the meat of any real problems. Tutorials on how to spin up worker threads in C(++) using POSIX/Pthreads, Windows or Boost.Thread are a dime a dozen so I won’t spend too much time on that here; instead…
-
Crash Course: Excel VBA Macros For People Who Don’t Care About Excel VBA Macros
Every 6-9 months I have to write some macros in Excel. I spend most of my coding time working in C++, C# and PHP and I tend to forget both VBA syntax and the Excel API really easily. So for those of you who believe – like me – that coding in VBA is anathema,…
-
Introduction to Multi-Threaded, Multi-Core and Parallel Programming concepts
In this article I’m going to present a gentle and modernized introduction to multi-threaded and parallel programming. While there are no concrete examples in this overview, I’m going to cover the general concepts and terminology, as well as an overview of the tools available to you as a developer to leverage multi-threaded techniques in our…
-
LightSwitch for Games Part 1: Introduction to Building your Game Data Network with LightSwitch
NOTE: Although this series is aimed at small game developers, it is equally applicable to anyone wishing to learn how to use LightSwitch. Most modern video games have an online component nowadays. For games with online leaderboards, stats tracking, world-viewable awards and achievements, online virtual currency and distributed non-real-time turn-based games (for a very simple…
-
Tetris: Adding polish with music, sound effects, backgrounds, game options, an intro sequence and other tweaks
Our previous version of SimpleTetris is working quite well as a single-player game, but lacks the professional touch. In this article, we’ll look at: how to make pausing and unpausing the game also pause and unpause all of its subsystems how to add music and sound effects and tie them into game events with SimpleFMOD (a library…
-
C++ Class Hierarchies Crash Course: Derivation (“is-a”) vs Composition (“has-a”), and Is a Square a Rectangle?
In this article I’m going to rattle over some basic design choice dilemmas you might face when trying to organize classes into a hierarchy. We’ll look at standard derivation (the “is-a” relationship), composition (the “has-a” relationship), when to use which, and also touch briefly on interfaces and private inheritance. Pre-requisites you should know before reading:…
-
Cutting Your Teeth on FMOD Part 5: Real-time streaming of programmatically-generated audio
This article was inspired by David Gouveia – thanks for the suggestion! In this article, we shall look at how to generate sounds programmatically using a function which generates each sample one by one, and how to feed these samples into the audio buffer of a playing stream in real-time. Note: The SimpleFMOD library contains all of…
-
C++ Explained: Object initialization and assignment, lvalues and rvalues, copy and move semantics and the copy-and-swap idiom
In this article I’m going to try and clear up some fundamental C++ topics which are a common source of confusion for beginning and intermediate C++ programmers, and programmers coming to C++ from other languages such as C# or Java: the difference between initialization and assignment, which uses of the “=” operator trigger initialization and…
-
2D Platform Games Part 11: Collision Detection Edge Cases for The Uninitiated
IMPORTANT! To run the pre-compiled EXEs in this article, you must have Windows 7 Service Pack 1 with Platform Update for Windows 7 installed, or Windows 8. This article builds upon the demo project created in 2D Platform Games Part 10: Improved Level Management and Storage. Start with 2D Platform Games Part 1: Collision Detection for Dummies if you just stumbled…
-
Visual Studio 2012 – Day 1 Annoyances (with an emphasis on C++)
Update 21st February 2013: added information about Update 2, the C++11 Compiler November 2012 CTP (in two sections) and Find & Replace Update 16th April 2013: the final version of Update 2 is now released; Update 1 is no longer needed (article updated) So this is it, huh folks? 16 years of development, and the…