Requesting help with using Conditions with HP

0 favourites
  • 2 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • I'm making a sidescrolling platformer similar to Castlevania. The health system I'd like to use for the player character consists of lightbulbs that are each positioned at different angles with two rows, so using the "subtracting tiled sprite" situation wouldn't quite work, at least as I understand it.

    Of course, I'd like each light bulb to disappear in sequence upon getting hit, so I've imported each of the 8 light bulb sprites and named them accordingly: HP_1, HP_2, HP_3, etc.

    I'm trying to create "conditions" in the event sheet. Right now, it looks like this:

    Player on collision with Enemy AND HP_3 is visible > Destroy HP_3

    Player on collision with Enemy AND HP_2 is visible AND HP_3 is NOT visible > Destroy HP_2

    Player on collision with Enemy AND HP_1 is visible AND HP_2 is NOT visible > Destroy HP_1 AND Destroy Player.

    ...except the Enemy only destroys the HP_3 light bulb and that's...all it does. When I walk into the enemy a second time, absolutely nothing happens and I'm invincible, stuck with 2 health forever. I'm obviously doing something wrong, but it seems like it should work! lmao.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • What you described is a very complex and inefficient method. You only need one sprite, not 8. Here is a much easier way:

    If you need different images for different lightbulbs, you can add them as frames, and set animation speed to 0.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)