I need help


#1

Hello, I’m very new to coding on Defold and I wanna ask if anyone know how to add in health packs or at least where to start from. I’ve looked everywhere and seem to be stuck. Thank you so much!


#2

A good place to start is always the documentation. In particular, the tutorials are a good place to look, where the tutorial runner has a detailed description of how to implement pickups and score systems, which might be what you mean by “health packs”.

The general ideas useful for health and similar properties of game objects are known as script properties. A key feature used for passing around these properties (such as increasing health when picking up a health pack) is message passing.

If you feel completely lost, start at the tutorials or with the building blocks.

Try some of it out, and if you get stuck, don’t hesitate to ask questions about any of the specific details.


#3

The question is very vague, but I assume you want something on the level that you can touch to pickup and gain lives? I would recommend that you take a look at the runner tutorial and specifically how the coins are handled.