Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

 
Reply to this topicStart new topic
> Magic damage formula, It sucks. Can I tweak it?
Milton Monday
post Jan 20 2012, 07:09 PM
Post #1


Unassuming Local Guy
Group Icon

Group: Revolutionary
Posts: 634
Type: None
RM Skill: Beginner




Okay, so I decided to legitimize my project by moving it from 2K3 to XP. I spent money on XP and VX, so I figure I had better use them, and I decided on XP because the mapping is better and I love the equipment auto-state feature that's missing from VX. However, I almost immediately ran into a few sticking points.

My game's main character is a mage, and the whole point of her being a mage was...
1) Making magic something that can be used constantly rather than a "tactical nuke" to be saved for boss fights.
2) Making every spell stay unique and useful through the whole game, rather than something that gets chucked away when you learn it's more powerful cousin. In other words, there was just Fire, no Fire 2, but that single Fire spell would serve you reliably through the whole adventure, and grow along with you.

In RM2K and 2K3, by tweaking the damage rates of the attributes, it was possible to create spells that had 0 base damage, but naturally grew in power as the character's Intelligence increased, and kept pace with physical attacks perfectly. However, it doesn't seem possible to tweak elemental damage rates in RMXP without scripting, and the skill damage formula is completely out of whack. A mage with 100 intelligence, casting a spell with 0 base damage, but 100 INT-F and 0 MDEF-F deals 8-10 points of damage to an enemy with no magic defense and a weakness to the spell's element!? Insanity!

The intelligence stat seems, by default, to be completely worthless, and it's worse for me, not only because I intend to push constant magic use as the game's main feature, but I also prefer to work with small numbers so every single point is a visible improvement.

So, the question is, is there some simple tweak I can make to the main script, or pre-existing script I can plug in, to increase the amount of influence stats (especially intelligence) have over skill damage, or are these moronic damage formulas somehow hard coded into the engine itself?

This post has been edited by Milton Monday: Jan 20 2012, 07:10 PM


__________________________
"Game development is a very special job that requires a very special person. The high stress levels often drive our staff members to become...subhuman. They're violent and need to be caged. But we need them to make good games. This is the unfortunate truth of the game industry." - Segagaga
Go to the top of the page
 
+Quote Post
   
Knot
post Jan 21 2012, 02:08 PM
Post #2


Level 25
Group Icon

Group: Revolutionary
Posts: 555
Type: Artist
RM Skill: Skilled




You can go into the script editor and look at line 166 to 184 for how the actual skill damage is calculated.

basically:
user.(something) refers to the attacker's stats.
self.(something) is the defender's stats.
skill.(something_F) are the stats you set for the skill.

So on line 179 is where intelligence is taken into effect:
rate += (user.int * skill.int_f / 100)
What it does is finds what you've set INT-F as for the skill and turns that into a percentage and takes that percentage from the attacker's intelligence.
So if your character has 200 intelligence but you've only set the skill's INT-F to 80 then only 80% of the character's intelligence(160) will effect the skill's power.
So, if you want each point of intelligence to count for more you need to change that percentage. If instead of 100 you change that down to 50, instead of factoring in only 80% percent the game would factor in 160%. In effect meaning that while you are aesthetically only increasing your intelligence by 1, the damage will act as if it has been increased by 2. By further modifying the 100 you can make this even more.
So:
rate += (user.int * skill.int_f / 25)
would mean that intelligence is factoring in for 4 times what it usually does.

Note: This does not mean that the damage will be 4 times as much, only that each point of intelligence would count for 4 times the standard amount.

This all assumes that you like the standard damage calculation and only want each point of intelligence to count for more. If you want to completely do away with the system, I'd suggest going into Excel or something and finding the exact damage formula you want to implement. It's really very easy to implement new formulas; the trouble is developing a balanced one.

I spent forever finding one, so I wish you luck!


__________________________
Unclickable!


QUOTE (X-M-O)
Oh no! I've been quoted again! D=



Other cool stuffs to check out! Even if they arn't mine...





Go to the top of the page
 
+Quote Post
   
Milton Monday
post Jan 22 2012, 04:13 AM
Post #3


Unassuming Local Guy
Group Icon

Group: Revolutionary
Posts: 634
Type: None
RM Skill: Beginner




First of all, thanks. I appreciate the help.

I found the line you talked about and tried fiddling with it; but no dice. I don't know why, but even changing the divisor to 1 (which should, in theory, mean the spell is 100 times more effective) the damage output remained the same. Maybe I'm doing it wrong. No scratch that, I'm definitely doing it wrong. I hate math.

That's okay, though. While waiting for an answer I started playing around with the RPG Maker VX Ace trial and found it to be everything I've ever wanted from an RPG Maker and then some (Including defining your own damage algorithms on a skill by skill basis right from the database! Zam!) so I've resolved to wait a month or three for that to get an English release before restarting in earnest, while continuing to prototype things in 2K3 and the VX Ace trial.

This post has been edited by Milton Monday: Jan 22 2012, 04:14 AM


__________________________
"Game development is a very special job that requires a very special person. The high stress levels often drive our staff members to become...subhuman. They're violent and need to be caged. But we need them to make good games. This is the unfortunate truth of the game industry." - Segagaga
Go to the top of the page
 
+Quote Post
   
Knot
post Jan 22 2012, 07:27 AM
Post #4


Level 25
Group Icon

Group: Revolutionary
Posts: 555
Type: Artist
RM Skill: Skilled




I'm glad VXace is exactly what your looking for! Just so that you don't feal bad about your maths I think the problem is probably to do with the engine. Are you testing the changes in the Battle Tester? If you're doing it that way you need to Ctrl+S first to save the project first otherwise the Battle Tester won't register the changes.

Good Luck with whatever maker you choose!


__________________________
Unclickable!


QUOTE (X-M-O)
Oh no! I've been quoted again! D=



Other cool stuffs to check out! Even if they arn't mine...





Go to the top of the page
 
+Quote Post
   

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 25th May 2013 - 02:28 PM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker