[Yanfly] In notetags, how to apply an element to damage/healing?

Adorkbutt

Warper
Member
Joined
Mar 5, 2017
Messages
2
Reaction score
0
First Language
English
Primarily Uses
RMMV
The way I'm doing it is basically (not exactly) like this (I changed some syntax so it would show up in one screenshot):


It works if the target has higher/lower than 100% Physical Element, because of "user.atk * target.elementRate(1)"

However, this isn't a good solution for things that absorb 100% Physical Element, since "hp -variable 3: target, show" just literally subtracts HP by the number, totally disregarding what element is selected in the drop-down. And sometimes I want skills to change elements during the skills.

How do I accomplish this? I looked in RMMV Script Calls
but I can't find any instances of "element" or "physical".

Also, I have looked in all of the Yanfly documentations (his Elemental & Action Sequences), and I've even looked in "Action Sequences Guide A helping manual about Yanfly’s Action Sequences Plugins Written by Yoshifull". Best I've found was DamageCore having a reference to "this.calcElementRate(target)" but I haven't been able to make that work.

I also tried having 1 damage inside of "Formula" and then multiplying it by the player's Attack/Magic Attack, and then doing "Force Element: (element)" inside of the notetags... but that takes forever, and messes up a lot of pre-existing things (like multi-target skills attacking for 1 damage at the start of the turn, then doing the <Target Action> stuff...etc)

With that being said... am I missing something? How do I make my RPG Maker MV (or plugins, more specifically) apply an element to damage/healing in notetags?

Ultimately, my idea is that it should be as easy as "hp -variable 3: target, show, (element)" and you apply whatever element (in my case, Physical), but obviously this isn't a thing. And yes, I checked, because I updated all my plug-ins and still don't know how to fix this problem.

I want more than one damage formulae (due to having timed attacks) during the course of a skill, and that's easiest to do in notetags, with nothing written in anywhere else (having it set to "Type: None").

I am using yanfly plugins, and this is probably entirely a lack of tools/resources problem.

TL;DR: I want to apply elements to formulaes in notetags. Any easy way?
 
Last edited:

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
As I said in the Javascript support channel on Discord, you may have to loop through the attack object's attack elements property to make sure it's calculating all elements assigned to it instead of just physical. I'll take a look at this later.
 

Rivendark

Villager
Member
Joined
May 17, 2016
Messages
5
Reaction score
0
Primarily Uses
change variable 3 = Math.max(0, ($gameVariables.value(2) - target.def));
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
We figured out how to do it on Discord using states for each part of the skill and modifying the damage formula based on which part state the user has. :3
 

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

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
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'??

Forum statistics

Threads
105,862
Messages
1,017,049
Members
137,570
Latest member
fgfhdfg
Top