Walking Up/Down Stairs (resolved)

  • #1, by HelixAbyssFriday, 22. January 2016, 02:17 4 years ago
    Hi, I have another question. How do I go about having my character go up/down stairs properly? Originally I had a separate outfit with the walking up stairs animation as the walk animation and then when the player chooses to go up a staircase, I hide the cursor, change the outfit, send them to the proper point, then change the outfit back and unhide the cursor. This works just fine for some stairs, but on side views it does not because the character will face the wrong direction. So for example if I have a side view of stairs and the character is supposed to face to the right while walking up the stairs, because of the way the point is offset from the initial point, she uses the back-right version instead. I searched all over and it doesn't seem like there is a way to temporarily lock the direction.

    So, attempt number 2. I tried creating an object with the character's walking up stairs animation and then setting the character's visibility to 0 before showing the animation, then setting the character's position to the destination, hiding the object's animation, and resetting the character's visibility to 100. The problem with this is that I cannot set the tint of objects, so while walking up/down stairs the character pops into their original color and then back to having the appropriate tint. Although noticeable, this doesn't look horrible for the particular scenes I'm working on, however it definitely will look bad on later scenes where there is a more extreme tint.

    Ok, now I'm on my third attempt. I made the animations character animations, used the "displacement of current frame" to make the image move within the animation, then made a script that executes on the last frame to set the character's position based on the displacement of the last frame. Well, the problem with this is that doesn't account for the character's scale, so when the animation restarts the character doesn't exactly get set to the right position.

    My questions then are: Is there a way to temporarily lock the character's direction? Or is there a way to move the character while they are displaying a different animation than their walk animation? I am completely out of ideas at this point so any advice is welcome!

    Newbie

    24 Posts


  • #2, by sebastianFriday, 22. January 2016, 06:03 4 years ago
    Uhm i think your First attempt is quite good. Just makr the diaginal walk animations look like the right/left walking Animation

    Thread Captain

    2334 Posts

  • #3, by HelixAbyssFriday, 22. January 2016, 06:10 4 years ago
    If I did that, then what would I do for the stairs that need the diagonal movements? I suppose I could make even more outfits. Hmm... well it's late here, I guess I'll get working on it some more tomorrow.

    edit: well I ended up doing just that (creating more outfits to handle left/right or diagonal movement) and it works well.

    Newbie

    24 Posts

Write post