@galoyo Ah. Well, I don't think I could use trace any less and still get much useful data. I'll make my own function to log diagnostics. Thanks.
Posts made by CharType
trace() causing program to lag
I am trying to use trace() to debug my program, and I'm having a problem. I have code set up that calls my debugging code on a timer. (Currently it is called every .5 seconds.) When I add trace() to my debugging code, my program lags to the point of unusability.
I see no inherent reason this should happen, since logging text to a terminal should not take much processing power. Is there something I can do to make trace() not cause this lag? Or do I just have to display diagnostic statements a different way?
FlxNestedSprite not working
I'm trying to use FlxNestedSprite in my program, but I'm encountering some problems. The first is just a minor annoyance as far as I know, but the second is making my game crash. I have a class that extends FlxNestedSprite, and I'm trying to add a child to it.
My first problem is that when I try to import FlxNestedSprite, a problem displays under the problems tab. I use the line "import flixel.addons.display.FlxNestedSprite;" and the error message it gives me is: "Type not found: flixel.addons.display.FlxNestedSprite" My code still compiles, but I'd like to know if there's a way to get rid of this error message.
My second problem is that when I add a child to my object, my program crashes immediately upon starting. I'm using the following code (in new()):
_tire.makeGraphic(10, 5, FlxColor.BLACK);
_tire.x = 2;
_tire.y = 2;
The program crashes when I add the last line. Does anyone know how to fix this? Thanks.
RE: How to resize sprite hitbox (setSize() not working)?
@dean Thanks, but that's not what I'm looking for. I want to resize just the hitbox. setGraphicSize() scales the whole graphic.
How to resize sprite hitbox (setSize() not working)?
I am trying to resize my sprite's hitbox so I can use flixel.util.FlxSpriteUtil to draw new things outside my sprite's original dimensions. I used a makeGraphic with width 50 and height 20 to make my sprite, and I tried resizing it like this:
(_playerCar is my sprite.) But the hitbox stays exactly the same after this, and I still can't draw anything outside my original rectangle. Is there a way to increase the size of the hitbox? Thanks.
Does Haxeflixel come with images and sounds?
I recently installed Haxeflixel, and I was wondering, does Haxeflixel come with free-to-use images and sounds? I know that some of the examples have images, but I don't know if there's a larger images folder somewhere. Does Haxeflixel come with images and/or sounds, and if so where are they? Thanks.
Way to change editor command when running from console?
Is there a way to change the editor command used when creating a new flixel project using the console? For example, when using "flixel -c". Specifically I would like to make it use "code --add", so it using Visual Studio Code and adds the new folder to the existing project in a multi-root workspace. Thanks.