VectorY and Is On Floor problem

  • Hey everybody!

    I'm implementing a downward dash move from mid-air using the platform behaviour where players are supposed to be able to break objects beneath by shooting down like a projectile. I tried using VectorY for this and it works insofar as the player shoots down and gets obstructed by any solid objects beneath. But if I try to use the Is On Floor condition to check if they're on ground the check fails. It's like they're not touching the ground at all even though the two objects are obviously in contact with each other.

    Changing gravity instead of VectorY works fine with Is On Floor, but then I lose control over acceleration so I'd much rather stick with incrementing VectorY for the downward movement. Any suggestions?

    The event structure goes like this:

    System | Chr.Platform.VectorY < 1400      | Set Platform Vector Y to Chr.Platform.VectorY + (7500*dt) 
                                              | Set Platform max fall speed to 1400
    
    *Chr | Platform Is on Floor               | Set Platform Vector Y to 0
                                              | Set Platform max fall speed to 700 (default)
                                              | Set Action to ACTION_ENDSTOMP
    [/code:bqdhobfm]
    * Never becomes true.
    
    Replace with Gravity and the condition succeeds:
    [code:bqdhobfm]
    <No condition>                                         | Set Platform Gravity to 5000
                                                           | Set Platform max fall speed to 1400
    
    Chr | Platform Is on Floor                             | Set Platform Gravity to 800 (default)
                                                           | Set Platform max fall speed to 700 (default)
                                                           | Set Action to ACTION_ENDSTOMP
    [/code:bqdhobfm]
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)