HAVING MOVEMENT TROUBLE? Try these scripts!

MistSonata

Moderator
The movement scripts that came with NESmaker 4.0 are unfortunately missing some things that are giving people errors. I've gone in and fixed all the problems I could find in these scripts, so all you need to do is put this .rar file in GameEngineData\Routines\UserScripts\BasicScripts\MovementScripts\ and export.

Make sure to go into "Scripts" in the sidebar and load these into your project before trying to access them in your "Input Manager"!
 

Attachments

  • MovementScripts.rar
    1.4 KB · Views: 355

TurtleRescueNES

Active member
Thanks MistSonata!

While I'm fine for now, there may be some continued issues with these movement scripts. When I imported these new scripts, my hero character would revert to some wild animations upon movement, even when his state or direction even called for animations. This would somehow be reset when the hero bumped into a monster. I played around with the hero animations and I think that is what reset the game to a proper state. But I just wanted to note my experience if someone else runs into it as well.
 

TurtleRescueNES

Active member
Yeah, I'm back to a weirdly animated turtle. I've attached a zip file with a video.

I also have an issue applying the movement scripts to the controls. I only have UP in place. If I add any more, then I get compile errors. This might be related to the maxed out memory that's also effecting the HUD.

So the turtle only starts animating after Up is pressed, which is to be expected, but then he randomly starts flaking out, including even the palettes, which is very odd. A monster bump resets him, but movement triggers it again.
 

Attachments

  • game812.rar
    119.3 KB · Views: 152

MistSonata

Moderator
Try making all the turtle animations the same number of frames. Sometimes it gets buggy when the amount of frames in the animation it's switching to are too different.
 

bakerguy85

New member
Thank you for these scripts. I put them in but when I hit an enemy, I will bounce back like should, but my sprite will face the opposite direction. This only happens if I just continuously walk into the enemy.
 

TurtleRescueNES

Active member
MistSonata said:
Try making all the turtle animations the same number of frames. Sometimes it gets buggy when the amount of frames in the animation it's switching to are too different.

Wow! Thanks, MistSonata! That appears to have worked! My "up" movement had 6 frames, while the other animations had only 2. So I just padded the rest to 6 and I haven't been able to replicate the quirk.
 

RadJunk

Administrator
Staff member
This is...simply amazing to see. Obviously we're overwhelmed over here, so to see the community continuing to step up and offer solutions is...I mean....wow.

:)
 
So just in case its helpful to anyone else, I ran into an issue getting my directional/movement animations to play. The scripts in OP were part of the issue. On top of replacing the scripts here I had to add the press and release input scripts to the "ChangeToIdleAnimation" and "ChangeToWalking" to the respective button events. At that point my animations would play but were stuck on walking (except for release Left, that one worked?)... anyway I noticed that the player load operand (LDX) wasn't in the script so I added that to the idel script so changeObjectState knows what to effect... Anyway my ChangeToIdelAnimation script now looks like this;

LDA gamepad
AND #%11110000
BNE +
LDX player1_object ;;Load player object operand before change state
ChangeObjectState #$00, #$02
+
RTS

Hope this helps anyone else with a similar issue!
 

Imagaryboy

New member
I am having trouble with implementing two things:

1) Diagonal movement. I assumed that in the input editor, I simply have to add the start/stopMovingPlayer for pressing both up and down buttons. But that didn't work :/
2) For moving up and down, I would like the player animation to don't change. For example: The player is facing left (Left idle animation). If I move up now, the player should stay facing left. But when I test my game, the player faces right again while moving up.

Hope you can help me out here :D
 

MistSonata

Moderator
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.
 
Top Bottom