Animation not playing

Dirk

Member
Hi!

I want to change my player's state (05) if he collides with a certain tile. If he is already in the state the change gets skipped.
This is my tile code:

Code:
	CPX player1_object
	BNE +
	GetCurrentActionType player1_object
	CMP #$05 ; If already in state 05 skip state change
	BEQ +
	ChangeObjectState #$05, #$02
+

It works a bit, but the animation won't start. It stays at the first frame. Also there is one slight flicker of the second frame when I move the player.
It actually looks better when I skip the state check and simply set it to state 05. The animation still won't start.

While pressing up or down the animation gets displayed.
 

dale_coop

Moderator
Staff member
If it's a platformer, it might be caused by the Extra Controls Script... that does some ChangeObjectState depending of the player state (if idle, if in the air, if on a ladder, ...)
 

Dirk

Member
Yes, I did. I double checked, because it seems sometimes NESmaker doesn't save changes (or at least in older versions).
 

Dirk

Member
dale_coop said:
If it's a platformer, it might be caused by the Extra Controls Script... that does some ChangeObjectState depending of the player state (if idle, if in the air, if on a ladder, ...)

Yes, it is a platformer. Thank you, I'll have a look at it and poke around. If I remember correctly you had to add some code there too to fix the idle animation not starting.
 
Top Bottom