Hi. I have a function.
if (map.collideWith(hero, 0, 0))
{
trace("Hit");
remove(hero);
}
Why does the hero get removed, but the output doesn’t trace anything!?
Hi. I have a function.
if (map.collideWith(hero, 0, 0))
{
trace("Hit");
remove(hero);
}
Why does the hero get removed, but the output doesn’t trace anything!?
A few possibilities:
trace()
statements elsewhere that haven’t worked? Some other code could be modifying hero
that makes you think it got removed even if it didn’t.trace()
outputs to the console, not to FlashPunk’s debug overlay.trace()
statements to appear. Running in release mode silences trace()
. Your tools could be similar.Hmm. I’m running flashdevelop. I’ll try to find the faulty part ^^ Thanks
I don’t remember, tbh But the trace statement doesn’t work anywhere. I googled some and it’s very confusing, but there’s probably some setting I can change to make it work. Thread can be closed. THank you both
Are you compiling the game in debug mode? If you compile it in release, the trace statements won’t appear.
Jycerian, it didn’t work! I guess I’m not compiling the game in debug as zach said. How do I compile it in debug mode? I googled but couldn’t find the answer