velocity check not registering

0 favourites
  • 4 posts
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • Greetings I'm trying to create a simple you event that triggers when you fall too far in a platformer. It's pretty basic and I'm just getting the physics Y velocity and seeing if it is greater than a certain amount to determine if the player has fallen too far and should die. The weird part is that this works without issue when I pause and step through in debug but gets completely ignored even with a breakpoint when I just run the game.

    I should say that I'm pretty new to Construct 3 but not to game dev. I did try to search for the solution for this but I'm not really seeing anything. Kind of an obscure thing to find the correct search terms for.

    thanks

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi bbowling you might be able to achieve this with a couple methods. Method 1 is kind of crude but effective you simply make a sprite that is invisible and if player is overlapping this sprite cause death events then just place the invisible object where you want. Method 2 is using the platformer "is falling" and a system wait X seconds like the image below. Hope this helps.

    If you're looking to make fall damage use a global variable that kicks in and then if on landed and variable=1 do the death or health loss events. Kinda like this.

    You can also make it so it waits for a second then starts increasing the global variable and you can take fall damage based on how far you fell. If you need an example of that I can provide 1 just let me know.

  • Rebel Zodiac Thanks for the reply and suggestions. I had not thought about approaching it that way. I may just try the invisible sprite idea first and see if that will work. I like simple solutions. I'll post back what I come up with.

  • No problem. Best of luck with your game!

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