Great thinking! But the shift button doesn't always work here since silly people like me set their "options" on the title screen to "always dash" - that means I have to hold shift if I don't want to dash!
This gets trickier and trickier...
Well, that means if you don't hold Shift you are dashing.
Which is the same as my example, but simply the opposite.
😀
Simply reverse the conditions.
😀
Spoiler: code
Code:
◆Loop
◆Control variables:#0018 Player Pos X = Map X Player
◆Control variables:#0019 Player Pos Y = Map Y Player
◆If:Button [Shift] is pressed
◆Control switches:#0009 PlayerRunning = OFF
◆Break Loop
◆
:Else
◆If:Player Pos X ≠ Previous Pos X
◆Control switches:#0009 PlayerRunning = ON
◆
:Else
◆If:Player Pos Y ≠ Previous Pos Y
◆Control switches:#0009 PlayerRunning = ON
◆
:Else
◆Control switches:#0009 PlayerRunning = OFF
◆Break Loop
◆
:End
◆
:End
◆
:End
◆Wait:1 trame
◆
:Repeat Loop
◆Control variables:#0009 Previous Pos X = Map X Player
◆Control variables:#0010 Previous Pos Y = Map Y Player
Same result, only this time if you hold shift, you are not dashing anymore.
😀
Edit : Oops, you meant you "as player".
My bad
😅
Double edit, with the script instead of the shift button, it covers all options.
🙂
So you get something like this :
Spoiler: Updated code
Code:
◆Loop
◆Control variables:#0018 Player Pos X = Map X Player
◆Control variables:#0019 Player Pos Y = Map Y Player
◆If:Script : $gamePlayer.isDashing()
◆If:Player Pos X ≠ Previous Pos X
◆Control switches:#0009 PlayerRunning = ON
◆
:Else
◆If:Player Pos Y ≠ Previous Pos Y
◆Control switches:#0009 PlayerRunning = ON
◆
:Else
◆Control switches:#0009 PlayerRunning = OFF
◆Break Loop
◆
:End
◆
:End
◆
:Else
◆Control switches:#0009 PlayerRunning = OFF
◆Break Loop
◆
:End
◆Wait:1 trame
◆
:Repeat Loop
◆Control variables:#0009 Previous Pos X = Map X Player
◆Control variables:#0010 Previous Pos Y = Map Y Player
This way, however you're option is set (auto or not) the event will work the same.
If you don't autorun, you need to hold shift to activate the switch,
If you autorun, you need to have nothing pressed to activate the switch.