going through the haxe game tutorial and im stuck at part 8 due to my game crashing #2337
-
after some experimenting i found out the bit of code that is doing this is the "else if (entity.name == "coin") i tried searching it up but got nothing, and i dont really know what is wrong, can someone help? here is the code help would be greatly appreciated |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
When placeEntities gets run, your coin group hasnt been initialized yet. Try moving coins = new FlxTypedGroup up to above the map.loadEntities call. |
Beta Was this translation helpful? Give feedback.
When placeEntities gets run, your coin group hasnt been initialized yet. Try moving coins = new FlxTypedGroup up to above the map.loadEntities call.