Tile Passable Only by Dashing?

Hello,

I have a bit of an unusual question- I want to make a tile that is passable only when the player is dashing. Is there any way to do this?

Thank you in advance for your help.
Well, I do have a simple plugin free trick; the only downside it has is using too many instances of it might slow the game down on that particular map, but it should work if used sparsely.

I'm assuming you are using the shift key to dash.

Create an event, set it to same as character priority and make it parallel. Put this in the first page:

◆Wait:5 frames
◆If:Button [Shift] is pressed down
◆Control Self Switch:A = ON
◆
:End

Now for the second page. Check self switch A, make it parallel too and set the priority to below characters. Put this in it:

◆Wait:5 frames
◆If:Button [Shift] is pressed down
◆
:Else
◆Control Self Switch:A = OFF
◆
:End

As long as the player is dashing with the shift key they'll be able to cross. As soon as they stop dashing, invisible wall! Hope it helps, I'm sure that this could be cleaner with some script usage but it's perfectly functional as it is.
Well, I do have a simple plugin free trick; the only downside it has is using too many instances of it might slow the game down on that particular map, but it should work if used sparsely.

I'm assuming you are using the shift key to dash.

Create an event, set it to same as character priority and make it parallel. Put this in the first page:

◆Wait:5 frames
◆If:Button [Shift] is pressed down
◆Control Self Switch:A = ON
◆
:End

Now for the second page. Check self switch A, make it parallel too and set the priority to below characters. Put this in it:

◆Wait:5 frames
◆If:Button [Shift] is pressed down
◆
:Else
◆Control Self Switch:A = OFF
◆
:End

As long as the player is dashing with the shift key they'll be able to cross. As soon as they stop dashing, invisible wall! Hope it helps, I'm sure that this could be cleaner with some script usage but it's perfectly functional as it is.

This works phenomenally- thank you so much! I never would have thought of it.

I experimented with the code- is it possible for the player to be transferred to a specific spot on the map rather than being stopped? When I try to add a transfer event after the turning off of Self Switch A, the player is transferred even if they cleared the tiles. I should have been more clear- I'm using this as a Mega Man X- esque air dash system. The player pushes a button and moves in a certain direction, bypassing certain obstacles. If they were to release the button early, what's to stop them from just pushing it again? I was hoping to have them transferred back to where they started.

Is this possible? If not, I'll deal with it- you have been tremendously helpful already. Thank you- I've added your name to my game's credits. 🙂
I get the feeling that might not work with controllers, and it definitely won't work if the player has the option to enable auto-dash.

You can use
Code:
$gamePlayer.isDashing()
to determine whether a player is dashing or not, so try that in your conditional instead of the shift check
I get the feeling that might not work with controllers, and it definitely won't work if the player has the option to enable auto-dash.

You can use
Code:
$gamePlayer.isDashing()
to determine whether a player is dashing or not, so try that in your conditional instead of the shift check

This works even better- thank you so much. There's only one thing- if the player dashes, then stops on a tile, they're able to stay on the tile.

If I limit the number of dashes the player is allowed to do per unit of time, this could be used to essentially cheat. Wait for their dash to recharge and continue. Is there a fix for that.

I'd add you to my credits as well, but you're already in them. 🤣 Thank you for your continued help. 🙂
You could always add something to the parallel process event that checks for whatever region the player is standing on, and if it's a certain number (whatever you paint over the dash-only tiles) they could be teleported back once isDashing turns up false.
You could always add something to the parallel process event that checks for whatever region the player is standing on, and if it's a certain number (whatever you paint over the dash-only tiles) they could be teleported back once isDashing turns up false.

I...didn't actually have it in a parallel process with Region IDs. I had it in an event touch. That was... a mistake I should not have made, considering I have done collisions before.

Thank you, that worked perfectly!
@Aesica comes through as always 😂
I knew there was going to be a script solution, I'm not very good with code and never know how to reference them 😅

Glad my thingy worked and I have to check mechscape, it looks extremely cool. Best of luck with it!
@Aesica comes through as always 😂
I knew there was going to be a script solution, I'm not very good with code and never know how to reference them 😅

Glad my thingy worked and I have to check mechscape, it looks extremely cool. Best of luck with it!

It worked perfectly, thank you! The functionality just didn't fit what I wanted to do- it was my fault that I wasn't clear enough. I still feel like I might use your "wall" code for another obstacle- as I said, I've added you to the credits.

Thank you for the well wishes! I'm glad my game looks interesting. 🙂

Original thread: https://forums.rpgmakerweb.com/threads/tile-passable-only-by-dashing.114439/