Charas-Project

Game Creation => Requests => RPG Maker Programming => Topic started by: DedlellyDeth on April 27, 2009, 01:44:23 AM

Title: How do I make damage increase MP?
Post by: DedlellyDeth on April 27, 2009, 01:44:23 AM
What do I do so that whenever a character is damaged, their MP increases by the amount of HP lost?
Title: Re: How do I make damage increase MP?
Post by: Rahl on April 27, 2009, 05:23:17 AM
Parallrl Process -Common Events

<varHP1=Current HP>
Wait 0.1 sec
<varHP2=Current HP>
<branch> If varHP1>varHP2
       then <varHP1-varHP2>
                   Add Hero MP from varHP1
<else>
Title: Re: How do I make damage increase MP?
Post by: DedlellyDeth on April 27, 2009, 11:04:49 PM
I thought Parallel Processes don't work in battle.
Title: Re: How do I make damage increase MP?
Post by: Rahl on April 28, 2009, 12:02:35 AM
Well they do, thier very dedicated workers as long as thier in Common events.
Title: Re: How do I make damage increase MP?
Post by: DedlellyDeth on April 28, 2009, 12:20:20 AM
They don't work in the default menu amirite?

Also, do test battles process Common Events?
Title: Re: How do I make damage increase MP?
Post by: Rahl on April 28, 2009, 12:28:13 AM
No, just on map and in battles.
Title: Re: How do I make damage increase MP?
Post by: DedlellyDeth on April 28, 2009, 12:59:44 AM
No, just on map and in battles.

What? I don't understand what you were answering.

Also, your code doesn't work for ****. I did it exactly as you said, went into a battle in my game, and nothing happened. I think you should test something before giving advice.
Title: Re: How do I make damage increase MP?
Post by: Hirochi-Zangus on April 28, 2009, 01:21:26 AM
He's starting to confuse me too, but I understand the coding he's getting at...

You need 3 variables  Hp-hero, hp-amount, & mp-restore

hp-hero = current hp.

Hero gets attack...  hp-amount = damage

hp-hero  -  hp-amount  =  mp-restore

Have an event in your battles that say...   mp-restore>0, then increase hero mp by var3 (mp-restore)

Do you get it? I hope i made it clear...
Title: Re: How do I make damage increase MP?
Post by: DedlellyDeth on April 28, 2009, 01:29:28 AM
I understand variables, OK? I just can't get it to work. What events should I use?
Title: Re: How do I make damage increase MP?
Post by: Rahl on April 28, 2009, 02:12:13 PM
Will I have to screenshot it for you?
Title: Re: How do I make damage increase MP?
Post by: DedlellyDeth on April 28, 2009, 10:08:19 PM
I did it exactly as you said, OK, dick?

I don't need help anymore because I figured it out with a different method.
Title: Re: How do I make damage increase MP?
Post by: DragonBlaze on April 28, 2009, 10:22:10 PM

Also, your code doesn't work for ****. I did it exactly as you said, went into a battle in my game, and nothing happened. I think you should test something before giving advice.

I did it exactly as you said, OK, dick?

These people are trying to help you. No one here is obligated to do that, so if you're going to be rude inconsiderate, no one is going to want to try and help you at all anymore.