[WIP] Contra-like movement issues

This forum is currently in read-only mode.
From the Asset Store
Run and Jump in 3 Dimensions! Take your platformer to the next level!
  • Hey guys :)

    I'm trying to work out movement like in Contra games, with 8 directional shooting, and I've come up with silly issue

    My controls and animations are preety much ready, and everything works almost perfectly but this - after pressing Up Arrow the player's angle changes which allows user to shoot up, but then when player release Up, animation gets back to idle state but bullets are flying up instead of left/right.

    Is there a condition which I can use so the bullets will lose their ability to change direction once they are shot?

    My Events and screenshot of the issue

    i60.tinypic.com/30mqv85.png

  • Hey

    If someone was curious how I handled previous bullet issue - I've created another object just for gun, pinned it to the character and used events to point it to desired direction/angle. Works fine.

    Now I have another issue.

    In Contra there are two falling animations - one triggered when player jumps ("rolled" jump animation until player falls on the ground) and other when player walks off a floor edge (single frame from walking animation).

    I'm trying to recreate this but so far without success.

    Whenever I'm trying to make different animation played when player walks from a edge it interferes with rolled jump anim because condition "is falling" or "is not on ground" is triggered due to in game physics and rolled jump animation is played only to top arch of the jump.

    Does anyone has any idea how to bypass this and set two different fall animations?

  • you could try,

    is falling + is overlapping ground at offset (-10x, -5y) -> Set animation to "fall drop"

    ELSE + is falling + is overlapping ground at offset(-10x, -5y) -> Set animation to "fall drop"

    ELSE + is falling -> Set animation to "fall roll"

    The conditions won't be exactly like that I think, but I think there is a check for overlapping at offset in CC. Hope that works!

    Edit: Also add a check to all three to make sure the player isn't already playing animation "fall drop" or "fall roll", so it only triggers once each time they fall (make the drop off platform fall a looping animation even though it's a single frame).

    And you might need to remove the tag "Falling" from the roll fall, since the events have to override it.

  • Thanks Jayjay, but unfortunatelly it doesn't worked

    Although I've made it differently

    I've added a variable to the player called "is_jumping", and then my events looks like this

    1. Player is on ground - set "is_jumping" to 0

    2. Player is jumping - set "is_jumping" to 1

    3. Player is falling :

    • value "is_jumping" equal to 1 - play rolled animation
    • value "is_jumping" equal to 0 - play standard animation
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hello again

    I'm currently working on dying animation and I've encountered two issues:

    1. When player hits killing block he's always knocked back to different distance.

    2. When player collides with said block while jumping he's thrown very high in the air. See here

    While I could live with first thing, the second is really annoying and I really can't understand why this is happening. I tried using set air acceleration or jump strenght to 0 but this doesn't work.

    This is how my events look

    Help with both issues will be much appreciated

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