haxeflixel

Cannot import library on Haxe & FlashDevelop

核能气质少年 提交于 2020-01-06 03:20:20
问题 I added some classes through http://lib.haxe.org/ and git with the correct command (haxelib install x) and, while the classes are in the haxe/lib folder, I can't access most of them. Sometimes I'm able to import a library(I get the autocomplete and everything), but when I try to compile it gives me the error Class not found . I searched everywhere and I still don't know how to fix this. I tried to add through Project>Properties>Classpath and I'd even edited the global Classpath but it still

Windows cpp target slows down in higher resolutions

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-24 00:21:24
问题 I'm having some unexpected performance issues with my haxeflixel game when building a windows (cpp) target with the following settings <window if="cpp" width="480" height="270" fps="60" background="#000000" hardware="false" vsync="true" /> I notice that when I'm re-sizing the window to bigger resolutions, or going full-screen up to 1920x1080p, the game becomes slower and lagging. However according to the flixel debug console, the frame rate is the same for all the resolutions. Something even

How to exit Haxe/OpenFL program?

人走茶凉 提交于 2019-12-12 08:41:18
问题 I am making a game using Haxe, OpenFL (Formerly NME) and HaxeFlixel. However, problem is, I can't seem to find a good way to make a Flixel button that will shutdown the game when pressed. I was planning to make a "quit" button on the main menu. Is there any simple method to do so or is it impossible? 回答1: It depends on the compilation target: I'm going to assume you're compiling to CPP (Windows EXE). In which case you should just be able to use the following: import flash.system.System; // Or

Macro --include is recursively including packages not appropriate for build target

只愿长相守 提交于 2019-12-11 05:15:04
问题 I'm building a game using the HaxeFlixel lib. In one part of my code I'm dynamically resolving classes via Type.resolveClass() . In order to avoid having to reference every potential class individually, I tried to use --macro include() by adding this to my project.xml : <haxeflag name="--macro" value="include('my.pack')" /> This worked fine when compiling against the Flash target, but when I try to compile against neko I get: C:\HaxeToolkit\haxe\lib\flixel/3,0,4/flixel/FlxG.hx:3: characters 7

Why is this Haxe try-catch block still crashing, when using Release mode for C++ target

北慕城南 提交于 2019-12-10 18:22:30
问题 I have a HaxeFlixel project, that is working OK in Debug mode for misc targets, including flash, neko and windows. But Targeting Windows in Release mode , I'm having an unexpected crash, and surprisingly it's happening inside a try-catch block. Here's the crashing function: /** * Will safely scan a parent node's children, search for a child by name, and return it's text. * @param parent an Fast object that is parent of the `nodeNamed` node * @param nodeName the node's name or a comma

How to exit Haxe/OpenFL program?

这一生的挚爱 提交于 2019-12-04 04:05:11
I am making a game using Haxe, OpenFL (Formerly NME) and HaxeFlixel. However, problem is, I can't seem to find a good way to make a Flixel button that will shutdown the game when pressed. I was planning to make a "quit" button on the main menu. Is there any simple method to do so or is it impossible? It depends on the compilation target: I'm going to assume you're compiling to CPP (Windows EXE). In which case you should just be able to use the following: import flash.system.System; // Or nme.system.System if you're using NME ... // in your FlxButton callback: System.exit(0); I can't test right