Senior_Muffin
Jun 17 2011, 09:34 AM
So, I was thinking. In an earlier topic I asked how to get your character to jump. Instead of the hero being able to jump all the time I was wanting to do something like the ring of disinigration in star ocean 3, as in I want a pair of boots the the hero will receive and is able to hit the shift button to jump but only can jump a set number of times. And I would then like the hero to have to "report" to an NPC to "re-charge" the item.
Does anyone have any thoughts or ideas? Is this even possible to do in rm2k3?
Essenceblade
Jun 22 2011, 04:18 PM
Ahh, yes it certianlly is, This is where you'll need Variables. Firstly, make a common event called shoe jump. Then make a switch called Shoe jump. Inside that common event, make it a parallel proccess and tick the trigger switch box and add the switch Shoe Jump in it. Now make a key input proccecing (Event page 3) and store it in a new variable which you will name Jump Button. Next, make a variable which will be called Shoe jump. now under that, add a conditional branch. which will be like this, "Branch if VAR Shoe Jump is: 0" (make it execute a custom handler) (Which will be always active as RPG Maker sets all variables to 0 automatically. anyhow, inside that conditional branch, add the move command "Move Event: Hero, Begin Jump, Move Forward, End Jump" (Make sure to tick the ignore impossible moves and untick the repeat proccess box) You can also add sound effects and alter the distance the character jumps within that move command, i just set it to move across one space. under that move command you'll need to make another Variable and call it "Jump Amount". once you've done that, make it look like this: Variable Oper: [Jump Amount] + , 1. after you've done that, make a conditional branch, "Branch if VAR Jump Amount is 3" (No handler) and under that, make a variable operation. "Variable Oper: Shoe Jump Set, 1. that's the first half done. Now go down a little until you go under the Else Handler branch. under that, add any message you want to indicate the person has no more uses from their shoes left, a.k.a "the boots are out of power, you need to recharge them." After the message, make a Variable Operation. "Variable Oper: Shoe Jump Set, 1" after that, make a "Jump To Label". make it jump to label number 2. after you've done that. bo down to the bottom where it says "End" and label it the number 2.
---------------------------
that is the boots jump amount system covered. if you want to make the jump amount higher than 3, simply go to: Branch if Var [Jump Amount is 3] and change it to any digit you like.
Now for the recharge section, which is slightly easier.
Simply make an NPC with the following:
<>Branch if VAR Shoe Jump is 1 or more
Memorize BGM
<>Message: (Shop Keeper)
: I see your shoes are out of power. do you wish to recharge them? (You can change the actual text to any thing you like informing the player that they're out of jumps on the shoes)
<>Message: It will cost you (xxx) gold to do so. (Change the xxx to any amount of money you like.)
Show Choices: Yes/No
[Yes] Handler
Conditional Branch if money is (xxx) or more: (Change the xxx to the amount of money the shopkeeper asked for)
<>Ok here you go.
Variable Oper: Shoe Jump: Set, 0
Variable Oper: Jump amount: Set, 0
Variable Oper: Jump Button: Set, 0
Change Money: (xxx) Remove (Change the xxx to the respectable number)
Play BGM: Fanfare 3
<>Message: (Your boots have been fully charged!)
Play Memorized BGM
<> Else Handler
<> Message: Hmm, you don't seem to have the right amount of money, come back when you do.
Jump to label: 1
<>
[No Handler]
<> Message (Ok, have a nice day.)
Jump to label: 1
<>
:End
<>[Else Handler]
Message: Your boots are already fully charged, please come back only when your boots
are powered out.
Jump to label: 1
<>
: End
Label 1
--------------
And that's it, then all you need to do is make the item in the database and make it a switch. depending on the shoes, you can make them an unlimited use or 1 use or whatever, its up to you, switching the switch "Shoe Jump" on. (All the messages by the shop clerk can be edited to your tastes. i conjured this up quickly so its pretty bland)
Hope this helps, if there's anything you don't understand or find glitched, post a reply and i'll try and get back to you asap.
shinyjiggly
Jun 30 2011, 09:16 AM
First of all, a couple nitpicks:
1. Have a handler for if you don't have enough money.
2. Capitalize the i in that message!
3. That branch that says "if jump mount is 3" should probably be a greater than or equal to for just a little bit more stability.
4. Make the item have unlimited uses so that you don't lose them when you have to recharge them.
Your problem is that you forgot to turn the switch off at label 2. Common events tend to loop when they reach the end.
I'm sorry about the nitpicks but I just don't want your eventing to have an unknown mess-up due to sloppy instructions.
Essenceblade
Jun 30 2011, 04:52 PM
To make the shoes an item, Make it an Accecory. Then in the common event, under Key Input Proc, add the event command: Branch If (Add Your Hero Here) Jumping Boots Equipped. Make it have a handler, But leave it blank. Then Cut the event command "Branch If VAR 0002 [Shoe Jump] Is 0" And Paste it under Branch If (Hero Name) Jumping Boots Equipped.. Also now that the item itself is no longer a switch, You'll have to toggle it in another event(This allows you to trigger it on or off at any time E.G in places you don't want the character to jump ect). or untick the Trigger Switch box and make the Common Event Itself a Parralel Proccess.
I apologize about the sloppy instructions. And I see your problem buddy

You have Branch If VAR: [0002:Shoe Jump] is 1 greater. It should be Branch If VAR: [0002: Shoe Jump] is 1. So basically just change the Variable method to Equal To, Instead of Greater Than. Also, In the Common Event Itself, Delete "Variable Oper: [Show Jump] Set 0. because then it will give you limitless "Jumping Ammo". That should do the trick, Again, I apologize for the lack of information on certian parts of the instructions.
-Hope this helps.