Merge dev to haxe3

Fix merge conflicts, made Console and ConsoleCommand haxe3 compatible, add workaround for NME setTextFormatBug