Haxe 3 compatibility
Merge as3boyan