Player Movement
Assignment 3 - Week 8 - Player Movement
Player Movement
Currently the only form of movement in "Sir Axelot" is using the players axe (or what's left of it) to navigate themselves upwards and progress though the long level. This was the main idea and is the main type of movement involved when playing the game.
Implementation
The current implementation for the movement is quite simple. A hinge motors speed is determined based on the arrow/mouse button being pressed by the player. There are also some custom features I coded such as acceleration time and torque of the motor which help give it a better feel. Using trial and error was the key to making this movement feel better and better.
However this implementation was not the only thing I attempted to do. The first was a follow mouse script, this aimed to direct the axe in relation to where the mouse was. This, for many reasons, did not work. I ran into many problems and struggled to fix them. One was a warping of the actual sprite and collider of the axe and another was a terrible clipping bug that made the axe fall through the floor. These things and a few others, drove me to change my thinking and led to the current implementation.
Controls
Swing Axe Left: Left Arrow | L-Mouse Button
Swing Axe Right: Right Arrow | R-Mouse Button
Basic movement example using arrow keys to swing axe in both directions
Feedback on Player Movement
Feels good and fun to frolic around, will need some refinement to allow for precise control...
Currently I am trying to implement a simple walking mechanic that will use keys A and D to slowly walk left and right. This will enable the player to have the more precise movement required for a precision platformer.
The gameplay loop though is both frustrating and addictive... ..Really keen to see how it grows!
I worked hard on trying to make the movement feel as best it can. My aim was for it to be possible to make manoeuvres, yet not so easy that it defeats the main difficulty aspect of the game.
Player Animation
When I first implemented the movement my first reaction was YAY! then straight afterwards quit my game in disgust at how stiff and gross the player looks whilst standing and falling through the air. This is what led me to implementing different animations so soon. Any time the player is falling or moving through the air, the players animation is:
Falling animation
Similarly, whenever the player is standing idle or not too far from the ground, the players animation is:
Idle animation
I also have future plans to create two more animations. The first for when I implement the walking mentioned above, the player will need a walking animation. And the second being if the player has fallen far enough for the players velocity to exceed x amount, a new animation of a different falling animation will play. During this, the player will not be able to continue moving the axe until their velocity has dropped below the set threshold.
Overall, I am very happy with the progression so far and with how things have turned out. Thanks to the feedback I have new ideas as to what should come next for the movement and ways for it to improve.
Lastly, this is a GIF of an earlier version of player movement before animations and even basic player/axe sprites:
Files
Sir Axelot
Status | In development |
Author | Leo Headley |
Genre | Platformer |
Tags | 2D |
More posts
- Documentation and User GuideOct 17, 2021
- Polish and UIOct 10, 2021
- Game TestingOct 07, 2021
- Presentation / GraphicsOct 03, 2021
- Enemies, Interaction and PuzzlesSep 26, 2021
- Level BlockingSep 19, 2021
- Game ConceptAug 29, 2021
Leave a comment
Log in with itch.io to leave a comment.