Monday, July 29, 2013

Intellesense Recognizes imports but FlashDevelop compiler does not

After about an hour of trouble shooting why my AS3 game project compiles on my old computer, but NOT on my new computer... I finally figured it out. The older version of FlashDevelop let me get away with this: A file named: FlxTileMapEXT.as Inside the class: [...] public class FlxTilemapEXT extends FlxTilemap [...] When I imported and used the class: import FlxTilemapEXT Everything worked... But on my new computer it kept saying that the definition "FlxTilemapEXT" could not be found. See the problem? Answer: Case sensitivity. My file name is FlxTileMapEXT, but it defines a class FlxTilemapEXT. FlxTileMapEXT != FlxTilemapEXT However, the old version of FlashDevelop let me get away with this. SIDE NOTE RELATED TO HAXE: NOTE: Haxe compiling in flash develop is even stricter. Avoid underscores in your file names. Also, avoid folders that start with CAPITOL letters, as it will short-circuit import statements. The compiler will think the folder is a class.

No comments:

Post a Comment