Scripting Help Change Damage System

I know next to nothing about scripting, (particularly in Java), and was hoping I could get some help from here on the forums. I'm wanting to rework the damage and battle system used for my game, and I have no idea how to go about it. The idea I have in mind is twofold.....


1) I'm wanting to have it so that damage is based on a 1-1 formula. In other words, if an enemy is neutral to a damage type, a character attacking with 15 points in attack would deal 15 points of damage. I would like to allow for weaknesses and resistances though, so that if said character attacked with another skill that had a base damage of 20, but the enemy was weak to that skill type, the attack would do 30, (or 1.5x), damage. The current damage formula in the program however is multiplicative, which means that such a system can't be maintained against all enemies and attack values without adding a script. The problem is that I don't know enough about the basic scripting involved in relation to the program to make such a script.....


2) I'm wanting to have attacks that draw from three different stats. STR for physical, INT for magic, and DEX for ranged. I'm also wanting to have seperate defensive stats for these three variables. Right now the system only allows for "Physical" and "Magical", and I don't know how to alter this to add additional parameters.....


I have other things in mind, but these are the two primary ones that I need help on at the moment. Honestly, if someone can give me examples of scripts that are related to these, I could likely figure it out from there, but I'm having trouble finding what I'm looking for, or explanations that don't assume you already know java in it's entirety.....
For 1, that is damage formula. Use a.atk for the damage formula, and set all weaknesses to element rate * 150.


Not sure why it being multiplicative matters honestly. Maybe you can give an example of why that stops the system you propose from working? Usually changing the number used in * will get the same general result in 99% of all cases that will ever arise in a game.


2: Change the name of your unused stats. It sounds like you are not using DEF or MDF at all (otherwise what you propose for #1 is not possible), change those 2 to the stats you need.
For 1, that is damage formula. Use a.atk for the damage formula, and set all weaknesses to element rate * 150.


Not sure why it being multiplicative matters honestly. Maybe you can give an example of why that stops the system you propose from working? Usually changing the number used in * will get the same general result in 99% of all cases that will ever arise in a game.


2: Change the name of your unused stats. It sounds like you are not using DEF or MDF at all (otherwise what you propose for #1 is not possible), change those 2 to the stats you need.



How would I go about doing either of these things. Again. I have no familiarity with creating scripts in java.....


Also on 2, how would I go about having certain attacks to base their damage off of these new stats?
You don't use Java at all to do that. Its all in the damage formula, when you create the skill in the database. Use that.
You don't use Java at all to do that. Its all in the damage formula, when you create the skill in the database. Use that.

Well, I'm also wanting to change the damage formula for the basic attacks. Either that or simply remove the basic attacks entirely so that skills are the only way to preform attacks. Is there any way to do that?


EDIT: Ah. Upon looking at it, I realize that it seems to treat basic attacks as skills you can change. I've used VX, (basic VX, not Ace), before but just recently bought MV, so there are a few things that I'm still not familiar with, so please forgive my noobness on the subject matter.....
Not a problem, I think XP didn't have a damage formula either.


I will caution you of one thing though...if you want a different damage formula for certain weapons you will need a plug in to accomplish that. Thankfully, I think such a plug-in was released with MV, so you should already have it.
Alright. Another question. Is there a way to set it so that my characters regenerate a specific amount of MP at the end of every turn when in battle without having to set an event on every single enemy Troop I create? Additionally, is there a way to set it so that they recover a set amount of MP and HP with every step outside of battle without having to set an event on every map?
Please post unrelated questions in different threads.  That allows us to close a topic when it's resolved, which keeps the forum cleaner and makes it easier for people who have similar questions.  We don't have "here is my thread with every question I can think of" topics here.
Please post unrelated questions in different threads.  That allows us to close a topic when it's resolved, which keeps the forum cleaner and makes it easier for people who have similar questions.  We don't have "here is my thread with every question I can think of" topics here.



Fair enough. I'm used to other forums where people try to keep their questions in a single thread rather than making a dozen for each separate question......
yeah, we like people to search for a solution before posting, especially for very basic questions or if they're very new (which means they'll have a lot of very basic questions).  If you have one thread with 87 different questions over 30 pages, and someone searches and your thread is returned as one of the results, they won't want to go through all 30 pages to see if you actually have asked the same question, and then search for the solution.


Here, once a question has been answered, that's the end of the thread 🙂

Original thread: https://forums.rpgmakerweb.com/threads/scripting-help-change-damage-system.55363/