Blog
Notes on game development, algorithms and side projects.
2016
- B-Spline Noise
Java code for generating B-spline noise.
2014
- Advancing Front Triangulation
Generating low poly meshes from implicit surfaces: from 2.5D Delaunay via surface nets and dual marching cubes to an advancing front triangulator.
2012
- Dynamic hard shadows in 2d
How the shadows in Shadowess are made: light geometries with the shadows carved out, rendered on the GPU. With interactive demos.
2011
- Shooting at a moving target as3
Leading a target: solving for the time of impact with the quadratic formula, so a tower can hit a moving enemy. With AS3 code.
- Random direction in 2d
Three ways to generate a uniformly random direction in 2D, and one intuitive way that is subtly biased.
- Simple Shadow Casting in 2D
Drawing a flashlight-style light cone and casting 2D shadows from walls, with a demo you can walk around in.
- Ray casting in a Spatial Hash with DDA
Ray casting through a spatial hash by walking only the cells the ray touches, using a DDA line algorithm. With a demo and AS3 code.
- How to check if a point is inside a hexagon
A fast point-in-hexagon test that uses the hexagon's symmetry to get away with a bounding box check and a single dot product.
2010
- Playchilla Physics Engine
A simple AS3 physics engine with simultaneous, continuous motion and a spatial hash, built over a summer holiday. With a demo.
