The official VisuStella notetag help thread

Cyberhawk

Bravelion Leader
Veteran
Joined
Jan 9, 2019
Messages
138
Reaction score
100
First Language
English
Primarily Uses
RMMZ
On a skill, you can make said skill add a state to the affected unit via notetag, so, is there a way for said state to be affected by enemy state resist.
It should. Changed my Archer char to have added effects for when she uses a bow skill w/ the Hidden state.
So if an enemy resists Slow or Stun, It will respect those state resists.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,700
Reaction score
2,801
First Language
English
Primarily Uses
RMMZ
Oh, yeah. If you're doing it via a post-damage notetag or whatever, you can add in an if statement which checks the enemy's state resist before calling addState.
 

Cyberhawk

Bravelion Leader
Veteran
Joined
Jan 9, 2019
Messages
138
Reaction score
100
First Language
English
Primarily Uses
RMMZ
Actually what would be the conversion for Thornmail from MV tips and tricks?
I'm having trouble trying to learn this one. Along with a Heighten Magic.
Though Highten Magic might be easier.

<Custom React Effect>
// Check to see if any physical damage is dealt.
if (value > 0 && this.isPhysical()) {
// Sets the Recoil Rate to 15%.
var rate = 0.15;
// Determines the amount of recoil damage dealt.
var recoil = value * rate;
// Sets the DEF bonus rate to 25%.
var rate = 0.25;
// Determines the amount of bonus damage dealt.
var bonus = target.def * rate;
// Rounds up the bonus damage and recoil damage.
var dmg = Math.ceil(bonus + recoil);
// Makes the attacker lose damage equal to the dmg variable.
user.gainHp(-1 * dmg);
// Check to see if the attacker is dead.
if (user.isDead()) {
// If the attacker is dead, make it collapse.
user.performCollapse();
}
}
</Custom React Effect>


<Custom Confirm Effect>
if (this.isMagical() && value !== 0) {
value = Math.ceil(value * 1.50);
}
</Custom Confirm Effect>
 

TrentL111

Archmage
Veteran
Joined
Oct 13, 2018
Messages
67
Reaction score
29
First Language
English
Primarily Uses
RMMV
Visustella, thank you so much for allowing breathing animations for the heroes as well. Super cool and a most welcome feature.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,700
Reaction score
2,801
First Language
English
Primarily Uses
RMMZ
Actually what would be the conversion for Thornmail from MV tips and tricks?
I'm having trouble trying to learn this one. Along with a Heighten Magic.
Though Highten Magic might be easier.

<Custom React Effect>
// Check to see if any physical damage is dealt.
if (value > 0 && this.isPhysical()) {
// Sets the Recoil Rate to 15%.
var rate = 0.15;
// Determines the amount of recoil damage dealt.
var recoil = value * rate;
// Sets the DEF bonus rate to 25%.
var rate = 0.25;
// Determines the amount of bonus damage dealt.
var bonus = target.def * rate;
// Rounds up the bonus damage and recoil damage.
var dmg = Math.ceil(bonus + recoil);
// Makes the attacker lose damage equal to the dmg variable.
user.gainHp(-1 * dmg);
// Check to see if the attacker is dead.
if (user.isDead()) {
// If the attacker is dead, make it collapse.
user.performCollapse();
}
}
</Custom React Effect>


<Custom Confirm Effect>
if (this.isMagical() && value !== 0) {
value = Math.ceil(value * 1.50);
}
</Custom Confirm Effect>
Thornmail (note that you can put this notetag directly on the armour, you don't need a passive state any more):

JavaScript:
<JS Post-Damage As Target>
  if (value > 0 && this.isPhysical()) {
    const rate = 0.1;
    const recoil = value * rate;
    const defRate = 0.25;
    const bonus = target.def * defRate;
    const damage = Math.ceil(bonus + recoil);
    user.gainHp(-damage);
    if (user.isDead()) {
      user.performCollapse();
    }
  }
</JS Post-Damage As Target>

Heighten Magic:

JavaScript:
<JS Pre-Damage As User>
  if (this.isMagical() && value !== 0) {
    value = Math.ceil(value * 1.5);
  }
</JS Pre-Damage As User>
 

WilsonE7

Veteran
Veteran
Joined
Oct 12, 2019
Messages
92
Reaction score
40
First Language
English
Primarily Uses
RMMZ
Good afternoon. Back in MV's Tips and Tricks, there was a video on how to let enemies steal items from the party. Can that be done with VisuStella MZ?
 

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Question, for Battle Core Plugin:
Action Sequence plugin command VisuMZ_1_BattleCore, MECH: Multipliers
My understanding of Rate vs. Flat seem to not work out and I've been trying to find a search on the topic.
Example for damage:

(Rate, default at 1.00, if I set it to 1.50 before the action effect, the hit will deal 1.5 times the damage)
(Flat, default at +0.00, if I set it to +0.50 before the action effect, I expect the hit to do 1.5 damage as well but it doesn't)

I guess I'm just confused on the difference of Rate vs. Flat for the multipliers. I prefer using Flat because it works additively and can stack with other multipliers that I have planned where as rate just gets set to a set value.

I've verified in game with no variance applied that Flat does not work like I thought it did and was wondering if anyone knew how it worked?
Thanks!

EDIT: Ok so I tested the Rate vs Flat for Crit %, Crit damage, Damage, and Hit % in battle. The Crit % and hit % rate apply a multiplier to your current crit % and hit % where as Flat adds % to your current crit % and hit %. So Flat +0.05 for crit/hit % adds 5% crit/hit chance which is great!
The same does not apply to crit damage and damage though. Rate works as expected but Flat is literally just like it sounds. +0.50 adds 0.5 damage to the end of the calculation. It does say in the plugin command notes that you can use JS code for any of the multipliers and now I'm trying to find a way to make:
Damage/Crit Damage Flat add a percentage of the overall damage at the end of the damage calculation instead of just a Flat number.
 
Last edited:

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,700
Reaction score
2,801
First Language
English
Primarily Uses
RMMZ
Good afternoon. Back in MV's Tips and Tricks, there was a video on how to let enemies steal items from the party. Can that be done with VisuStella MZ?
It sure can!

JavaScript:
<JS Post-Apply>
  if (user.isEnemy()) {
    const successRate = 0.5;
    if (Math.random() < successRate) {
      let items = [];
      const total = $gameParty.items().length;
      for (let i = 0; i < total; ++i) {
        const item = $gameParty.items()[i];
        if (item.itypeId !== 2) {
          items.push(item);
        }
      }
      if (items.length > 0) {
        const random = Math.randomInt(items.length);
        const item = items[random];
        $gameParty.loseItem(item, 1);
        var text = user.name() + ' stole ' + item.name + ' from the party!';
        SoundManager.playEquip();
      }
    } else {
      var text = user.name() + ' failed to steal an item!';
      SoundManager.playBuzzer();
    }
    const window = SceneManager._scene._logWindow;
    if (text) {
      window.addStealText(text + '<CENTER>');
    }
  }
</JS Post-Apply>

@Novam4a1 I think the documentation might have been a mispaste; rate is percentage, flat is just a flat value. I *think* for things like crit chance, rate adds a percentage of the current while flat adds an actual percentage.
 

Jrrkein

Drago Royale
Veteran
Joined
Apr 20, 2014
Messages
294
Reaction score
118
First Language
Indonesian
Primarily Uses
RMMZ
I was wondering if you can replicate toxic effect from MV tips and tricks if you know the poison status worsen every turn unless cured. I don't know if that code would work in MZ because there is JS slip damage but i'm no javascript genius
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,700
Reaction score
2,801
First Language
English
Primarily Uses
RMMZ
I was wondering if you can replicate toxic effect from MV tips and tricks if you know the poison status worsen every turn unless cured. I don't know if that code would work in MZ because there is JS slip damage but i'm no javascript genius
JavaScript:
<JS On Add State>
  this._toxicCounter = 1;
</JS On Add State>
<JS Pre-Regenerate>
  const n = this._toxicCounter / 16;
  const value = Math.floor(n * target.mhp);
  this._toxicCounter++;
  target.gainHp(-value);
</JS Pre-Regenerate>
 

Jrrkein

Drago Royale
Veteran
Joined
Apr 20, 2014
Messages
294
Reaction score
118
First Language
Indonesian
Primarily Uses
RMMZ
Thanks man that worked :hswt:
 

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ
@Novam4a1 I think the documentation might have been a mispaste; rate is percentage, flat is just a flat value. I *think* for things like crit chance, rate adds a percentage of the current while flat adds an actual percentage.
Thanks Trihan. That’s what I’ve found too. I think probably the easiest way for me to get what I need is to do states and plug them in action sequences. Thanks for the help!
 

Austrian

Veteran
Veteran
Joined
Jan 17, 2016
Messages
38
Reaction score
22
First Language
English
Primarily Uses
RMMZ
Hello, is there a way to use allow a skill to only target an enemy with a certain state?
 

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Alright thanks, I'll give it a shot!
With that plugin, try this notetag in the skill and see if it works for you:

<target filter: return target.isStateAffected(putyour state id here);>

then see if your skill will not only let you target an enemy with that state ID
 

Austrian

Veteran
Veteran
Joined
Jan 17, 2016
Messages
38
Reaction score
22
First Language
English
Primarily Uses
RMMZ
With that plugin, try this notetag in the skill and see if it works for you:

<target filter: return target.isStateAffected(putyour state id here);>

then see if your skill will not only let you target an enemy with that state ID
Trying it out, but the skill is un-selectable even if there's an enemy with the state ID in the field.

Edit: I forgot, .isStateAffected(x) doesn't work for passive states. Forgot I had to use target.states().includes($dataStates[x]) instead. So the skill now works as intended :). Thanks for the tip!
 
Last edited:

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Trying it out, but the skill is un-selectable even if there's an enemy with the state ID in the field.

Edit: I forgot, .isStateAffected(x) doesn't work for passive states. Forgot I had to use target.states().includes($dataStates[x]) instead. So the skill now works as intended :). Thanks for the tip!
Awesome! Glad it worked out!
 

Novam4a1

Veteran
Veteran
Joined
Nov 2, 2020
Messages
35
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Hello, I want to create a state that adds Actor01's ATK number to his MAT number in RMMZ.
This is the VisuStella CoreEngine notetag I'm using but when the state is applied, it displays "NaN" for the MAT stat.

<JS MAT Flat: +$gameActors.actor(01).param[2]>

EDIT: solved using

<JS MAT Flat: +($gameActors.actor(01).atk)>
 
Last edited:

logite

Villager
Member
Joined
Jun 18, 2012
Messages
8
Reaction score
5
First Language
Spanish
Primarily Uses
Hi, i see you can level cap from notetags using <Max Level: x>
But there any form, that you can levelcap from an event or scriptcall?

My character max level is 10, but i want add you can levelcap from 10 to 15 after an event.
 

Latest Threads

Latest Posts

Latest Profile Posts

finished the draft of some of this dude's motions!

mc0xoB4.gif


gonna work on the drafts of the other 3 now before i put detail, need to position these rather tall sprites well on the field

waiting for the term to end so i can get more time w this :kaodes:
Vaguely toying with demon/tiefling type parts but will probably work on something else first because eventually I'm going to have to make wings and I don't feel up to it yet. In the meantime, this guy:

TestChara-15.gif

I ended up reworking the interface, and Poppet's animations so she has a wand now and waves it to fire a shot. Also I gave her a shadow. Still have to rerender other stuff with shadows but eh.... I like her new "pew pew" wand. :LZSexcite:
PSA: please stop putting the word 'Eternal' in your game titles.
RMMZ: "Simple enough for a child!"
also RMMZ: "What, you're trying to make an RPG and you didn't know about Euler angles?"

Forum statistics

Threads
113,634
Messages
1,076,320
Members
147,643
Latest member
Sataesim
Top