State that increases elemental damage.

RPGIcon

Villager
Member
Joined
Sep 27, 2013
Messages
13
Reaction score
0
First Language
English.
Primarily Uses
As the title says, I need a script that makes it so states can increase the elemental damage output of the user. Any help would be much appreciated. :)
 

Shion Kreth

White Knight
Veteran
Joined
Jan 28, 2013
Messages
281
Reaction score
47
First Language
English
Primarily Uses
As the title says, I need a script that makes it so states can increase the elemental damage output of the user. Any help would be much appreciated. :)
Unless I'm misunderstanding what you're asking for.. the feature 'elemental rate' under the 'rate' tab in any state will do just that, just set it to whatever % over a hundred you want the bonus to be for, ie: 125 for a 25% increase in damage, 175 for a 75% increase, etc.
 

Tsukihime

Veteran
Veteran
Joined
Jun 30, 2012
Messages
8,564
Reaction score
3,846
First Language
English
Element rate affects how much damage you receive, not how much you inflict.


Adding 200% fire element rate doesn't mean you will deal double damage to enemies.
 
Last edited by a moderator:

RPGIcon

Villager
Member
Joined
Sep 27, 2013
Messages
13
Reaction score
0
First Language
English.
Primarily Uses
Element rate affects how much damage you receive, not how much you inflict.

Adding 200% fire element rate doesn't mean you will deal double damage to enemies. 
exactly, that's an example of what i want to happen but sadly increasing the element rate only increases the damage the user takes rather than the damage it deals. :(
 
Last edited by a moderator:

Shion Kreth

White Knight
Veteran
Joined
Jan 28, 2013
Messages
281
Reaction score
47
First Language
English
Primarily Uses
Element rate affects how much damage you receive, not how much you inflict.

Adding 200% fire element rate doesn't mean you will deal double damage to enemies.
That's embarrassing, I misunderstood it this whole time.  :headshake:

I'm now a little shocked that's not a default feature. 
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,359
Reaction score
7,672
First Language
German
Primarily Uses
RMMV
You'll have to give us more info to see what you really want, because the elemental attacks work a bit differently...


Basically, all weapons make a damage based on ATK and the skill damage formula - and that number can be set to be done by an element.


If the skill sets the element, then that element's damage rate of the target will be used.


If the skill doesn't set an element, then the weapon's element feature (if any) will set this.


Now it depends on what you want that state to do:


1) If you want to increase the damage of whatever element is set for the attacks, then you simply make a state that adds to the ATK - no script needed.


2) If you want the state to set the element and then increase that damage, make a state that adds the elemental feature and adds to ATK - no script needed.


3) If you want the state to check what damage is done by the skill/weapon, and only add to the ATK if the used element is the one that the state increases, then yes, you'll need a script (and no, I don't know one such script at the moment).


There are a few other cases how someone could interpret your request, and those might need scripts or not - but the cases above should show you that you need to give more info about when that state should do what.
 

Tsukihime

Veteran
Veteran
Joined
Jun 30, 2012
Messages
8,564
Reaction score
3,846
First Language
English
This script provides the basics for setting up attack elements


http://www.himeworks.com/2014/01/attack-element-modifiers/


From the way I've written the description, it looks like you can tag your weapon with fire element, and it will deal fire elemental damage. So for example you say it does 100% fire damage.


And if you add a state that also increases fire elemental damage by 100%, then you will suddenly deal 200% fire damage.


See if it does just that.
 
Last edited by a moderator:

RPGIcon

Villager
Member
Joined
Sep 27, 2013
Messages
13
Reaction score
0
First Language
English.
Primarily Uses
i'll try and explain things by using an example from a game.

let's say there's a mage with a fire spell that deals fire damage and a water spell that deals water damage.

when used, both of the spells deal 50 damage to an enemy.

the mage can cast a spell on itself that increases its own FIRE damage by a percentage, but just its fire damage.

after casting the spell, the mage's fire spell would go up to dealing 100 damage but the water spell would still deal 50 damage.

just making a state that increases the mage's MAG wouldn't work because it would also increase the water damage.

i also can't just make it so the spell reduces the enemy's magic resistance because the spell is actually a passive state that i got through neon black's passive skills script (http://forums.rpgmakerweb.com/index.php?/topic/4693-passive-skills/).

i hope i'm explaining this well enough, my apologies if not. :(
 

DoubleX

Just a nameless weakling
Veteran
Joined
Jan 2, 2014
Messages
1,787
Reaction score
939
First Language
Chinese
Primarily Uses
N/A
I've an rather ineffective and inefficient way requiring no custom scripts at all(it also works on skills having multiple elements although things would be much more complicated).

1. Make states with id s1, s2, s3, ..., sn dedicated to increase the damage of element with id e1, e2, e3, ..., en when skill users have those states.

2. Change the custom damage formulae of skills having Damage Element being element with id ei to something like this:

original_custom_damage_formula * (a.state?(si) ? ei_modifier : 1)or this:

original_custom_damage_plus * (a.state?(si) ? ei_modifier : 1) - original_custom_damage_minusWhere:

original_custom_damage_formula is the original custom damage formula of each of those skills

a.state?(si) checks if a has state with id si

ei_modifier is the damage modifier for element with id ei

original_custom_damage_plus is the positive part of the original custom damage formula

original_custom_damage_minus is the negative part of the original custom damage formula

For example:

Let's say a state with id 1 is dedicated to increase the damage of fire elemental skills(I call this Fire +) by 100%. Suppose there's a skill using fire as the damage element and its original custom damage formula is:

100 + a.mat * 2 - b.mdfThen Fire + can be used to this fire elemental damage skill to increase its damage, by changing its custom damage formula to something like any of the below:

100 * (a.state?(1) ? 2 : 1) + a.mat * 2 - b.mdf
Code:
100 + a.mat * (a.state?(1) ? 4 : 2) - b.mdf
Code:
(100 + a.mat * 2) * (a.state?(1) ? 2 : 1) - b.mdf
Code:
(100 + a.mat * 2 - b.mdf) * (a.state?(1) ? 2 : 1) # only this one increases the final damage output by 100%
Of course this non-scripting way will probably be tedious like hell(especially if you've lots of elements and skills) and any decent custom script will be much more effective and efficient, but sometimes custom scripts might end up being undesirable(like compatibility issues), so a non-scripting way might become what you want.
 
Last edited by a moderator:

RPGIcon

Villager
Member
Joined
Sep 27, 2013
Messages
13
Reaction score
0
First Language
English.
Primarily Uses
@DoubleX

while a good idea, it's sadly something i can't use in this case. but thank you anyway, as i will actually be able to use that for other stuff. :)

@Engr. Adiktuzmiko

it's funny you posted, i actually tried your script literally earlier today but i was slightly baffled about the notetags and wasn't sure if i was using it correctly. i was actually about to try again because i thought i might be doing something wrong but the pastebin link doesn't actually work which i find kinda weird because like i said, i tried the link literally earlier today and it worked. :?
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
try it out again maybe later, might just be some random problem... you could probably ask me if you have problems, though I cannot assure you that I can answer right away. :)
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c

Forum statistics

Threads
105,857
Messages
1,017,018
Members
137,563
Latest member
MinyakaAeon
Top