About the How do I...? category

Ask questions to get help using GDevelop and about game development in general.

3 Likes

If you want to post a question, we need some additional Informations to be able to help.

  • What you want to do?
  • What is the issue you are facing?
  • Make sure you gave a try by yourself before asking for help. Please add a screenshot (Not a photo!) of the events you have written to your post, for context.
    • If you are writing about not knowing how to approach your problem, try to break it down into simpler task that you can carry out easily with events (see below).

Breaking down a problem:

Let’s say you want to create a gun in your game and do not know how to approach it. Asking here how to do a gun will most likely yield limited answers of limited usefulness - such a broad game mechanic can be understood in many different ways, and listing them all is too big an endeavor for anyone to do.

It is your job to break it down a higher level problem into simple logic fits your vision and can be expressed through events: After all, only you know exactly what you want your game to become.

For example, the mechanic “a gun” could be broken down by one like this:

  • When the key X is pressed, you want a bullet to be created.
    • In events: When key X is pressed, create bullet object
  • A bullet should be shot in the direction of the nearest enemy
    • In events: When a bullet is created, pick the enemy object nearest to the player object, and rotate the bullet towards the enemy object
  • A bullet should always move in the direction it was shot towards
    • In events: Add a force towards the angle of the bullet to the bullet
  • When an enemy or wall is hit, the bullet should be deleted
    • In events: When the bullet is in collision with the BulletTarget object group, delete the bullet
  • When an enemy is hit, its health variable should be decreased by 1 or 2 randomly
    • In events: When the bullet is in collision with the Enemy object, remove RandomInRange(1, 2) from variable Health.

If the preview is black, stuck on the loading screen or frozen :

Press on the crashed preview Ctrl+Shift+I
A debugging menu should appear. Don’t press a second time, it sometimes takes some time to appear but pressing the key combination again will close it.
Go to the console tab, and send a screenshot of the output and most importantly the errors showing up in it (only red messages, yellow ones are not relevant).


These actions will help us a lot and spare time if you directly do this, instead of waiting for us to ask you for it. This context is crucial for everyone in the forum to be able to help. Thank you for following this advice!

8 Likes

and one more important thing: grammar and spelling.
you might give us as many info as we need, but to no avail if we don’t understand!
I know, English is a hard language, it isn’t the native language of mine too. surely I’m making many grammatical mistakes too. but please try to be understandable.

2 Likes

Is there some way to mark questions as answered? It would help others searching solutions rather than questions…

Edit: Having asked that question I notice some of the questions are prefixed with
[SOLVED]
So that could be the answer to my question.

1 Like

All these title with [Solved] are manually added by me in general because i check every thread. (Yeah i’m a bit crazy to check all post every days, but when you love you didn’t count the time.)
And when i see a solution or someone said “thank you it’s working” i edit the title.
I’ve asked to @4ian an addon for it i’ve found one but for now it’s manually since 1 years :’)

Fun fact after 1 year i can now write [Solved] without see my keyboard :sweat_smile:

9 Likes

just joined this community, thank you for making it awesome!