Help - Search - Members - Calendar
Full Version: Set Skill MP Cost to Varable
RPG RPG Revolution Forums > Game Engines > RPG Maker 2000 / 2003
Dart00
Is there a way to set a Skills MP cost to a Variable? I cant seem to find a way to do it and googles not really helping...
Essenceblade
QUOTE (Dart00 @ Oct 11 2011, 08:29 AM) *
Is there a way to set a Skills MP cost to a Variable? I cant seem to find a way to do it and googles not really helping...


That sounds pretty straight forward, but here's my guess:

You need to make a Variable firstly, that is called "MP cost". I figure this is for a custom battle system, so you'll need to SET the MP Cost Variable equal to the MP that character has. Then simply subtract the amount required. so for example...

Ryan: 50 MP
Fire: 5 MP
This would be the coding:

Variable Operations: MP Cost: Set Equal Ryan's MP
Variable Operations: MP Cost Subtract 5
Change Character MP > Decrease > Ryan > And then Amount: Equal to the MP Cost Variable.
Optional: Variable Operations: MP Amount: Set Variable MP Cost value.
All in all, this should reduce Ryan's 50 MP, by 5, resulting in 45.

As for the last instruction, ^ if you have an "MP Amount" Variable, simply set that Variable to the same amount as the MP Cost variable to neaten things up. This isn't needed, but it reduces confusion.

There's my two cents in the say. I hope this is of use somehow.
Dart00
Thats for the feedback..you confirmed a idea i was thinking as a alternative which i may have to do.

I was hopeing to avoid doing "MP Cost" = "x"....

I would "like" to be able to make a skill in the "Skills Tab", set its MP there, then assign it to a variable in a common event.

I guess i may just have to control it all for variable in a common event like you suggested.
Night5h4d3
If you wanted it to be a certain percentage, like it will always use 10% of the player's MP, that's already built in. But if you wanted it to be like the skill costs 5 extra MP every time you use it, then you'd have to do it Essenceblade's way I believe.
Dart00
QUOTE (Night5h4d3 @ Oct 12 2011, 07:26 AM) *
If you wanted it to be a certain percentage, like it will always use 10% of the player's MP, that's already built in. But if you wanted it to be like the skill costs 5 extra MP every time you use it, then you'd have to do it Essenceblade's way I believe.


Ok thanks...thats what i figured.

Thanks for the help. smile.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2013 Invision Power Services, Inc.