New account registration is temporarily disabled.

TIMED HITS IN RM2K3 DBS?

Posts

Pages: 1
I was wondering today, is there any conceivable way that you can think of to incorporate timed hits (as in Super Mario RPG) in to the DBS in rm2k3?

For instance, your hero selects a skill attack, and you have a battle event start during that attack that waits X amount of frames and checks for input?

It seems like there would be some roundabout way of accomplishing this in the DBS. Any ideas?
LockeZ
I'd really like to get rid of LockeZ. His play style is way too unpredictable. He's always like this too. If he ran a country, he'd just kill and imprison people at random until crime stopped.
5958
This belongs in help and requests, as it is a question about how to use the RPG Maker editor.

Also: Hahahahahaha. No. You wish. RM2K3's battle events screen does not include an Input Processing command. It also doesn't include about 70% of the other commands you can do in events outside of battle. The answer is to not use the RM2K3 DBS.
No, you can't do this in RM2k/3.

You may be able to do it in RMXP/VX, but it would require some interesting stuff. I actually almost had it working at one point, by adding a method to the Animations that would return the flash value, and I would make a flash that was invisible with a specific value that could be used to reference when a timed hit should be hit, so when you hit input during a battle animation it would check the animation's flash value to see if it matched and produced a timed hit based on that. But I never got it to completely work and gave up.
Actually, you miiiiight be able to. You can call input processing in battle through a common event. I know that I've had it manage to work for some old modified dbs type system back in the the day, but there was no timing element involved in the way I used input processing. I don't know if you could get it to work right with a timing element.

I'm not making any guarantees, but here's what I'm thinking: make the skill a switch skill, and have the skill animation play out through an in-battle event when the switch is triggered. Make the animation play without wait, and then wait manually. You'll do 1 wait function until the desired input time, call a common event to handle the input processing. The animation is still playing during this time. Have another wait command until it finishes playing, and then check if the user input the right key. I think it should work, but it might not be accurate enough to get good functionality.
Craze
why would i heal when i could equip a morningstar
15170
http://wiki.pockethouse.com/index.php?title=Mini_Game:_Button_Mash

This isn't what you want, but it's the closest I know of.
Yes, that's possible. You can call a common event in order to get the "Key Input Processing" command to work. For visual feedback, you can use pictures (using the PicsInBattlePatch which allows pictures in battle).
What Cherry said. It's simple. :)

You can also cut your animation up into say, 3 different animation slots if you don't want to go the picture route. This way, you can implement your key inputs/code in between the playing of each animation in battle events. So for example, an animation with 75 frames would be split up into 3 animations, each being 25 frames with code in between where you want. The way the DBS works, you aren't able to notice the chopped up animation. It's smooth.

I've said too much...I must disappear.
So we went from
"Hahahahahaha. No. You wish."
to
"Hey, here's a well thought out idea that might work" ?

<3 RMN

Thanks for the replies guys.
Oh, I forgot: You can NOT use the "Wait until key press" function at the key input processing command! It will cause the game to hang. Use a loop or labels instead.
I have revised my coding please check my new post.
I'm just guessing here, but ...

It's probably because it checks for a split second button press, and then waits 2 seconds while idling.

You might want it to check constantly for the two seconds by doing the input following by a .1 wait, followed by an input, followed by .1 wait, so and so forth till 2 seconds. You might even have to go down to a ton of 0.0 waits to get it timed right (you might have to do this with a loop that breaks after so many repetitions because of the sheer number of repeats that would require, but then you run the chance of lag - rpgmaker doesn't love loops apparently)

Edit: Nevermind, I hadn't noticed the code below the text. I'm gonna have to give that a read and then reconsider my answer
Actually if you add a .1 sec wait then it only checks if you press the button every .2 seconds because you have it wait .1 second twice before it loops, which means it will only check if you pressed the button 5 times a second as opposed to the 60 times a second I have it as now. Also it is already a loop, just using labels instead of loop command to reduce/eliminate any lag. Also I figured out why it works when you spam the button. I will add the extra coding to my last post after this one.
@fredo
I revised the coding so you may want to check it again.
This is just an example of how you might create a timed hit system.

Monster Groups:
Page 1
Trigger = Player uses the Attacks command
<>Comment:This resets the variables, so it can work for more then one attack.
<>Variable Oper: 002:Ticks Set, 0
<>Variable Oper: 003:Animation Set, 0
<>Comment:This wait command is absolute if you want to use the action key for timed hits.
<>Wait: 0.0 Sec
<>Call Common Event: Timed_hit
<>

Page 2
Trigger = Switch 001:Timed_Hit ON
<>Comment:Shows the animation of a timed hit.
<>Show Battle Animation: Timed_Hit, Monster
<>Comment:This determines the damage dealt.
<>Variable Oper: 004:Damage Set, Player Attack
<>Variable Oper: 004:Damage *, 2
<>Change Monster HP: 1:Monster's HP 005:Damage Remove
<>Comment:Needed to reset the switch.
<>Switch Operation: 001:Timed_Hit OFF
<>


Common Event:
001:Timed_Hit
<>Comment:Label is for creating a loop since you can't use the wait option in key input.
<>Label: 1
<>Comment:Records your key presses.
<>Key Input Proc: 001:Key_Pressed
<>Comment:This wait command is important in order to determine the amount of time that has passed and to slow the loop.
<>Wait: 0.0 Sec
<>Comment:This determines how much time has passed.
<>Variable Oper: 002:Ticks +, 167
<>Comment:The X value is for you to determine. If you want the action key to be pressed at a certain frame then follow this formula. X = Frame*1000
<>Variable Oper: 002:Animation Set, X
<>Variable Oper: 003:Animation /, Var 002:Ticks 's Value
<>Branch if Var 003:Animation is 0
<>Jump to Label: 3
<>
:End
<>Comment:This determines if you pressed the action key at the right time.
<>Branch if Var 001:Key_Pressed is 5
<>Comment:This branch determines if you pressed the action key to soon. If you did then it will end the event. Change X to the same value you used for the previous X.
<>Branch if Var 002:Ticks is X Less
<>Jump to Label: 3
:Else Handler
<>Jump to Label: 2
<>
:End
<>Jump to Label: 1
<>Comment:Jumping to label 2 or 3 ends the loop.
<>Label: 2
<>Switch Operation: 001:Timed_Hit ON
<>Label: 3
<>
Pages: 1