Make a Platform object jump while in the air?

0 favourites
  • 8 posts
From the Asset Store
112 High-Quality destruction sounds for videogames
  • It seems that when using the "Simulate control" expression for jumping, it only works when on the ground. Which makes sense, of course -- but I'm trying to make my Mario jump off of enemies' heads after landing on them, which means he isn't exactly on the floor, so in this case it's working against me.

    How might I work around this? <img src="smileys/smiley5.gif" border="0" align="middle" />

  • I'm a beginner my self but maybe it would work to create a invisible object on top of the enemy that your character can jump off of.

  • Well, it's certainly not ideal and it doesn't always work, but it'll have to do for now. Thanks for the idea mate!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm having the same problem, did anyone ever figure out a solution to this?

    EDIT: the same effect can be achieved in platform behaviour by setting the Vector Y to the same number as the jump strength (make sure to make it negative though so the character actually travels up) Gotta admit, some of the naming conventions can be a bit unclear as to what they mean/do for the conditions/actions. Too bad there isn't a way to turn the visual representation off and just view the actual code, it'd be neat to be able to toggle between the two... then confusion like this might not happen so much maybe

  • I done it by coding this:

    Player On collision with Enemy > Player Set Platform vector Y - 150

    The value depends on your physic world values.

    Trial & error situation :)

  • Example it's basically what AngeloFernandes says, plus one more condition so it won't trigger everytime, only when jumping from above.

  • I believe this is atleast twice shown in "How do i" section for how to do a mario like jump over enemies in Platformer behavior

    scirra.com/forum/how-do-ifrequently-asked-questions_topic45416.html

    The simulate control as i know is just doing same like when you press a button in default to jump or move.

    So for what you are looking for, you definitely want to use the vector Y

    to do any kind of jumps in anywhere than on solid ground in my opinion.

  • Yeah, that action wasn't available at the time I made this topic. Unfortunately the original solution was the only thing we could do at the time. You whippersnappers should be grateful that it's so easy for ya now. <img src="smileys/smiley36.gif" border="0" align="middle" />

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