How to make your player Run...Alright, so if you want to make running a feature in your game, just follow these instructions...
STEP #1: Creating The Item Needed for Running...First you need to make a decision; whether or not your character needs to be wearing a special accessory, or some other item in order to be able to run...Did you decide yet!? Good, then let's continue. If you decided that you wanted your character to have to be wearing a specific piece of Armor or an Accessory, then let's cover that part right now, shall we!? First off, I would like to recommend making the Item that is needed, some sort of Armor or Accessory, so that using the item becomes more practical...By this, I simply mean that by holding an item wouldn't really make you faster would it? But if you were wearing special shoes, then it would make more sense for your character to become faster, wouldn't it? I'll cover both styles in this TUT anyway, so that way you have options for your game, however I still recommend using the Equipable Item style...Also, if you're wearing armor, then you could add AGI and what not...)
How the Item/Accessory should look...ItemAccessorySTEP #2: Creating the Event System that allows your character to use that Item/Accessory to run!...Ok, we do this by creating a two NEW Common Events. Set them to Parallel Processes and make a common switch to turn them on. The Events should be Set-up like this:
Page #1's systemPage #2's system *Make sure that the switch being turned on in the previous page is one of this page's starting conditions!!*
STEP #3: Staying in ControlIn order to stay in control of this system, there are a few things that you need to do...First off, remember the switch that you made when you created the common events? To begin your running experience, simply call this event when your are able to run...Now you can use the event style you chose constantly until you reach certain areas of the game that you do not want to be able to run in. When you come to these parts of the game, just turn that switch OFF, but be sure to turn it back ON later...
WAYS TO EDIT THIS SYSTEM1)
Making the character run when the item is equipped, but without pressing buttons to activate:Under the conditional branch that's asking if the shoes are on, skip right to the set move route without adding the extra conditional that's checking if you're pressing the button...
2)
Using just one button to toggle the run OFF and ON, instead of two:You may have noticed that I used two different buttons when Speeding up and slowing down the main character. Avoid this by setting Page two to use the same button as the first page, however make sure to add a wait period of like 10 frames before turning the switch ON and OFF, after changing the character's speed. Reason being; because this event is a Parallel Process, it continues to repeat itself over and over. Because of this, as soon as the switch is turned OFF or ON, the other page automatically starts as I'm sure you already knew. This all happens so fast, that when you press the button, the new page starts, and it reads the button's prescence from the first time you pressed it. You need to add a wait period, so when the new page starts running, the previous button input has time to wear off.....
3)
Use an Item, not Equipment:In the TUT, my system uses equipment. To be able to run by having a Special Item in your inventory, replace the Conditional Branch that is asking for the Accessory to be equipped, with this:
@>Conditional Branch [Running Shoes] is in Inventory.....and the rest just follows after as is...
4)
Don't use an item to run, just run whenever you feel like it:Copy the event system as displayed, and simply remove the conditional branch determining whether or not your main character is wearing the equipment or not...
I believe that about sums it up guys! Hope you enjoyed this TUT, and I hope it will be of use to you all in your games!