HAVING MOVEMENT TROUBLE? Try these scripts!

Imagaryboy

New member
MistSonata said:
Unfortunately these are 4-direction movement only. I'm working on a new 8-direction movement script, though. I don't know exactly what you're asking for in the second point.

hehe sorry, that was some bad explanation :roll:
I am working on a platformer and at some point in the game, the player will be able to fly around. My problem is that if the player is facing left and wants to simply fly up or down, the player sprite goes back to facing right. But I want the sprite to keep facing left of course. Guess I have to change something in the code and I already tried to but wasn't able to find the solution...
 

Dr. Van Hauten

New member
On my hand, I have some problems with my walking animations on a platformer-style game. When I hold a direction, the animation won't loop and showsn only 1 frame out of 4, but if I slighty touch the direction, the animation will loop without stoping. When releasing any directions, the idle animation does connect properly though. The jumping animation seems fine too.
I try loading your scripts as well, but the the problem still occurs...

The weird thing is I followed the tutorial and the first time everything worked fine, until I tried to add a jumping command which resulted in an error somehow. I fixed the error but now my animations are the problem.

Another question about movement as well. Is there a way to have a down animation facing the same way as the character. I saw that you can set animations on down/left and down/right, but what about if you just push down?
 

dale_coop

Moderator
Staff member
Those scripts was made for an older version, which had an issue.
The 4.0.6 and later have no more the problem of movements.
If you still have, it means you diverged from the tutorial at some point.

Heck again your animations, your action steps and your input editor. You may have something different than the tutorial.

And if you are making a adventure game you can’t add jump (this script doesn’t exist for that module)... or maybe you are making a platformer ? In that case, why you would need down and up facing animations?
 

Dirk

Member
dale_coop said:
or maybe you are making a platformer ? In that case, why you would need down and up facing animations?

An example: I would like to have a crouching animation when pressing down with my character looking in the right direction.
 

Dirk

Member
Since the hitbox has a fixed size at the moment crouching wouldn't do anything anyways. I couldn't pass narrow gaps or dodge projectiles.
Well, I could probably set a flag isCrouching and have projectiles check if the flag is set. However this should only work with projectiles that fly horizontally and in a certain hight. Getting hit from above should of course still hurt you.

So, maybe dodging can be achieved this way for carefully setup projectiles, this still leaves the problem of crouching and crawling.

I wonder if it is possible to replace the player with a new crouching player with a smaller hitbox when the down button is being pressed. Basically replacing him with a monster you could control in this position. My coding knowledge isn't advanced enough for that yet ^^
 

dale_coop

Moderator
Staff member
The solution would be to modify the bounding box when your player is crouching or crawling.
I think jorotroid worked on that http://nesmakers.com/viewtopic.php?f=23&t=1038 for his Witch City (http://nesmakers.com/viewtopic.php?p=7006#p7006)

Or having Bounding Boxes related to Action Steps would be great but not possible... http://nesmakers.com/viewtopic.php?f=24&t=611
 
Top Bottom