(FIXED) Game generally isn't working properly

My game has 2 major issues. One is that the object variables on an object get ignored. Second problem is that when the particle systems spawn in, only one set of them (particles with the same object variable value as the enemy hitbox object variable; basically an id system) actually moves with the enemy hitbox.

Project file

There is a template to posting on this forum. It would be helpful if you could follow that, rather than just briefly describe what you experience and link the source files.

Some things to consider:
What object variable gets ignored?
Where are the events the appear to ignore it?
Do the objects exist in the scene?
Are the Ids different for each particle system?
Can you provide screen shots of what happens, and the events that you expect to work but don’t?

First question: All of them in the infomap object. This object serves as a way to transfer info between the external layout and main scene.

Second question: The ones that refer to the infomap object.

Third: Yes.

Fourth: Each enemy base has 2 particle systems attached to it. I attach them using object variables. I check the enemy base’s id, then the 2 particle system’s id. If the particle system’s id matches the enemy base’s, the particles follow the base. The enemy base is an object that serves as the hitbox and ai. The particle systems are just for better visuals.


You have 2 mapinfo objects in the scene - one from game scene, the other from the external layout. It could be a lottery to whether GDevelop uses the one you want…


You didn’t check your project to answer the question. I’ve downloaded the project, and there is no enemybase in either the game scene or the external layout.

If there’s no enemybase, then the enemy particle systems won’t be created.

Fourth : The events look like the same Id is assigned to both enemy1 and enemy2. You make no attempt to change the identity held in enemybase between assignments:

Fifth: Yes, because you have the following event actions running every frame, overriding the initial position to the mapinfo variables:

I wasn’t testing the enemies, so I didn’t add them in either the main scene or the layout.
Also, the enemies always have different IDs when I add them in.

Thank you for solving the position problem though.

Then what are the particle system issues then? I can only see that enemy1 and enemy2 are partcle systems…


The particle systems are a visual representation of the ai-controlled objects. The ai objects are name “enemybase”. They aren’t in the scene because I removed them later to test the mapinfo object.

Sure, I understand that. But you listed 2 issues in your initial post - the instance variables and the particle system objects not working how you expected. You should have included the particle system in the scene in the source code you linked. We can’t help with the enemy issue otherwise.

Makes sense. I’ll update the project file soon.

The same link should point to the new version of the game. I have added enemies in the main scene.

The problem was fixed. All I had to do was use a “Repeat for each instance of (object here)” event type for the enemy bug.

The map object not working was because none of the features I coded relating to it was bugged. It was half fixed by MrMen. Thank you for helping me figure this out!

1 Like