From 07d00ff04848f09eefd177df2b475ff049cb6c56 Mon Sep 17 00:00:00 2001 From: Joshua Granick Date: Sat, 1 Nov 2014 10:16:34 -0700 Subject: [PATCH] Fix template --- templates/haxe/DefaultAssetLibrary.hx | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/templates/haxe/DefaultAssetLibrary.hx b/templates/haxe/DefaultAssetLibrary.hx index 388886564..1461e6d14 100644 --- a/templates/haxe/DefaultAssetLibrary.hx +++ b/templates/haxe/DefaultAssetLibrary.hx @@ -654,20 +654,25 @@ class DefaultAssetLibrary extends AssetLibrary { ::end:: #end -#elseif (windows || mac || linux) +#else -::if (assets != null):: #if openfl -::foreach assets::::if (type == "font")::class __ASSET__::flatName:: extends openfl.text.Font { public function new () { super (); __fontPath = "::targetPath::"; fontName = "::fontName::"; }} -::end::::end:: +::if (assets != null)::::foreach assets::::if (type == "font")::class __ASSET__::flatName:: extends openfl.text.Font { public function new () { super (); __fontPath = "::targetPath::"; fontName = "::fontName::"; }} +::end::::end::::end:: #end + +#if (windows || mac || linux) + +//::if (assets != null):: //::foreach assets::::if (embed)::::if (type == "image")::@:bitmap("::sourcePath::") class __ASSET__::flatName:: extends openfl.display.BitmapData {} //::elseif (type == "sound")::@:sound("::sourcePath::") class __ASSET__::flatName:: extends openfl.media.Sound {} //::elseif (type == "music")::@:sound("::sourcePath::") class __ASSET__::flatName:: extends openfl.media.Sound {} //::elseif (type == "font")::@:font("::sourcePath::") class __ASSET__::flatName:: extends openfl.text.Font {} //::else::@:file("::sourcePath::") class __ASSET__::flatName:: extends lime.utils.ByteArray {} //::end::::end::::end:: -::end:: +//::end:: + +#end #end #end