Slow player's movement speed while standing in an event (without using regions)?

Hello all!

I would like my player to have their movement speed cut in half while they're moving through "slime." As shown in the video below, my character is recognized as standing "in the slime" while her red rectangular collider (at her feet) is in contact with any of the red circular colliders (this is via QMovement).



While I find it relevant to mention the QMovement plugin, this is probably an eventing problem. I'm just explaining that while the red rectangle (at the player's feet) and red circles are in contact, you can think of the player as standing inside the event, much how a player would normally be standing on top of an evented tile in normal RPGmaker. Each red circle is a separate event.

With that out of the way, while the player is standing inside the event, I would like to slow down the player's movement speed. Many of the solutions I've seen posted for this issue involve player coordinates and regions which doesn't seem viable due to my pixel-based movement setup.

This here is an example of one such event which is supposed to slow down the player while she is standing inside of it (the notetag section is just for setting the dimensions of each circle hitbox.

Help1.png


As you can see, it is triggered by player touch and simply uses a Set Movement Route - Player Speed 3 to try and change the player's movement speed. Evidently, this is the wrong way to do it since:

1. I get a weird "stutter" effect while walking through the event
2. The player is slowed down WAY more than x2 while moving through the event, almost as if the "set move route player speed 3" commands are stacking (which is probably what's happening?)
3. Once I move out of the event, the player's movement speed remains slow

What would be the best way that I should approach this? And of course, please let me know if I can give any other information that would be helpful.

Thank you for your time!

EDIT: Solved - Use a script call for set player movespeed instead of set movement route event command.
I fear that the “weird stutter effect” is a by product of changing your players speed with a pixel movement plugin. As for setting the players movment speed back to normal, there are many solutions. You could just surround your slime event with another event that changes your movement speed to normal in the same way that the slime event slows it.
I misread your post. If the stutter effect is only occurring inside the slime zone, it may be because the event is constantly trying to change the players speed. Try setting a switch to turn off the event after the players movement speed is changed. You can use the surrounding event I was talking about to reset that switch.
I misread your post. If the stutter effect is only occurring inside the slime zone, it may be because the event is constantly trying to change the players speed. Try setting a switch to turn off the event after the players movement speed is changed. You can use the surrounding event I was talking about to reset that switch.

Yeah it looks like every pixel I move inside the event counts as "touching the event" again. So the game is basically changing the player's movement speed a billion times a second while walking through.

Setting a switch also simply stops the player from moving as if the game is crashing.

Funny enough, variables seem to work. Just as a test, I set the event to add +1 to a variable based on player touch. Walking through the event raises the variable to like 60. So yeah, the event is simply spamming the event commands over and over.
Than you allready tryed this:

◆If:Switch1 XXX is OFF
◆Control Switches:#0001 Switch1 XXX = ON
◆Set Movement Route:Player
: :◇Speed:3
◆
:End
Than you allready tryed this:

◆If:Switch1 XXX is OFF
◆Control Switches:#0001 Switch1 XXX = ON
◆Set Movement Route:Player
: :◇Speed:3
◆
:End
That did do the trick. I had previously had the set movement route - speed 3 command in an external parallel event (triggered by the switch) but putting the set movement route command inside the slime event itself seems to work.

I'm now having trouble swapping the speed back to normal when they exit the event though.

Halp.png


So alongside the event command you posted, I've set up a parallel event which is meant to check every 1 second to see if the player is still inside the slime. If they are not, then it swaps their speed back to normal and switches the "Slow" switch off.

This works except the stutter effect is still triggering every time the player speed swaps (which is every 1 second). It seems that this stutter is occuring because the set movement route event command is resetting the walk cycle animation every time.



Is there any way to stop the stutter effect? (i.e. slow down the player movement speed without an event command that resets the walk cycle)
Not sure... but did you make sure to set the Eventpages and Conditions into the right order?
Highest Eventpage ID that fullfills the Page Conditions is getting used.

Edit:
The stutter should not come from this...not sure... strange...
Did you make sure no other Common Events or other parallel Events are running?
You mean the slight blink stutter while moving over the red zones correct? strange...

Edit2:
I rebuild it in rpg maker mv, here is what the possible code could look like for the parallel Event:

◆Get Location Info:playerRegionID, Region ID, ({playerX},{playerY})
◆If:playerRegionID = 1
◆If:Switch1 XXX is OFF
◆Control Switches:#0001 Switch1 XXX = ON
◆Set Movement Route:Player
: :◇Speed:3
◆
:End
◆
:Else (Not on Region1)
◆If:Switch1 XXX is ON
◆Control Switches:#0001 Switch1 XXX = OFF
◆Set Movement Route:Player
: :◇Speed:4
◆
:End
◆
:End
Not sure... but did you make sure to set the Eventpages and Conditions into the right order?
Highest Eventpage ID that fullfills the Page Conditions is getting used.

Edit:
The stutter should not come from this...not sure... strange...
Did you make sure no other Common Events or other parallel Events are running?
You mean the slight blink stutter while moving over the red zones correct? strange...

Edit2:
I rebuild it in rpg maker mv, here is what the possible code could look like for the parallel Event:

◆Get Location Info:playerRegionID, Region ID, ({playerX},{playerY})
◆If:playerRegionID = 1
◆If:Switch1 XXX is OFF
◆Control Switches:#0001 Switch1 XXX = ON
◆Set Movement Route:Player
: :◇Speed:3
◆
:End
◆
:Else (Not on Region1)
◆If:Switch1 XXX is ON
◆Control Switches:#0001 Switch1 XXX = OFF
◆Set Movement Route:Player
: :◇Speed:4
◆
:End
◆
:End

Thank you so much for your help! In the end, I ended up using a script call for set player movespeed which bypassed the set movement route event command completely. It's now working perfectly (your advice is what got me to a point where it was working at all though!)

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/slow-players-movement-speed-while-standing-in-an-event-without-using-regions.133149/