Steering behaviours in Haxe, ported from Advanced Actionscript Animation by Keith Peters