The official VisuStella notetag help thread

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
I have tried that with:
Code:
<JS On Add State>
if (target.isHpRecover()) {
  value = -value;
}
</JS On Add State>
and
Code:
<JS sparam Flat: REC>
if (target.isHpRecover()) {
  value = -value;
}
</JS sparam Flat: REC>
It still doesn't work.
isHpRecover is a function of Game_Action, not Game_Battler. You need to check it for the action rather than the target.

@WilsonE7 Currently there aren't any notetags that duplicate the functionality of Equip Requirements, as far as I'm aware. It may be available in a future plugin.

@XVoid You can use a property and setStateDisplay for this. What have you already tried?

@PAC918 Yeah, you'd need to add a new type for each different type of arrow. Having the cost be dependent on the number of enemies attacked might be a tricky one, I'll have to play with it and see if I can come up with something. How are you handling arrows at the moment?

@Tsukari MZ added a new trait, "Attack skill ID", which you can use for this, no plugin needed.

@RufusB Is that your issue completely sorted now?

@Austrian You could use the plugin parameters in Core Engine to modify params based on level.

@stevenblanc As far as I'm aware Message Core has had a couple of updates since you posted this that fixed the issues you're describing.

@Weremole If that's only happening when actors are dead it may be a bug, would you mind submitting a bug report via the form?

@shaylina I haven't tested this but try:

Code:
<JS On Add State>
target._healing = 0;
</JS On Add State>

<JS Post-Damage as Target>
if (value < 0 && this.isHpEffect())
  target._healing += value;
</JS Post-Damage as Target>

<JS On Expire State>
$gameTemp.requestAnimation(target, 101);
const healing = Math.round(0.25 * target._healing);
target.gainHp(healing);
delete target._healing;
target.startDamagePopup();
target.clearResult();
</JS On Expire State>
@janussenpre This thread isn't for bug reports, there's an official form for that. :)

@TrentL111 There are a couple of ways you could do this:

Code:
<JS Post-Start Action>
  $gameMessage.setSpeakerName(user.name());
  $gameMessage.setFaceImage(user.faceName(), user.faceIndex());
  $gameMessage.add("<WordWrap>Out of the ground, raze all greenery and burn my foes with flames! Burninate!");
</JS Post-Start Action>
Alternatively you could use a <Custom Action Sequence> for the skill and just use a regular Show Text... command before the action effect.

@jkweath I don't think there's a built-in way to specify an element for slip damage at present, no. Howeeeeever, you can code your element check into the damage calculation using the target's element rate. Like if I wanted to apply fire weakness/resistance to it, I could do

Code:
<JS HP Slip Damage>
damage = Math.floor(20 * target.elementRate(2));
</JS HP Slip Damage>
I'll bring up the suggestion of putting in code examples to the team.

@Rexxon The forcing de-equip on apply isn't going to be hard, but preventing re-equipping while they have the state would be tricky with the current plugins I think as there aren't any which govern whether weapons or armour can be equipped or not. Leave that one with me.
 

Austrian

Villager
Member
Joined
Jan 17, 2016
Messages
27
Reaction score
10
First Language
English
I must not be understanding something in the documentation then? In the documentation, it says I can change the params for the enemy in the note tags. So I tried it with something simple as <MaxHP: 9999> and <EXP: 1000> none of which are occurring?

Also in the note tags, I don't see anything for characters other than initial and max level and learn this at level... But nothing about setting parameters for each actor?
 

shaylina

Villager
Member
Joined
Mar 26, 2015
Messages
16
Reaction score
2
First Language
French
Primarily Uses
@Trihan. I tried, it didn't work. I even tried in a new sample project to make sure nothing was interfering and it didn't work still. Thanks anyway Trihan. It's really appreciated that you help us out like that.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
@Trihan. I tried, it didn't work. I even tried in a new sample project to make sure nothing was interfering and it didn't work still. Thanks anyway Trihan. It's really appreciated that you help us out like that.
I've probably missed something in the syntax, I was writing that from memory. I'll figure it out when I can use RM proper and see where I went wrong.

Edit: Here you go!

Code:
<JS On Add State>
target._healing = target._healing || 0;
</JS On Add State>

<JS Post-Damage as Target>
if (value < 0 && this.isHpEffect())
  target._healing += -value;
</JS Post-Damage as Target>

<JS On Expire State>
$gameTemp.requestAnimation([target], 101);
const healing = Math.round(0.25 * target._healing);
target.gainHp(healing);
delete target._healing;
target.startDamagePopup();
target.clearResult();
</JS On Expire State>
 
Last edited:

shaylina

Villager
Member
Joined
Mar 26, 2015
Messages
16
Reaction score
2
First Language
French
Primarily Uses
<JS On Add State> target._healing = target._healing || 0; </JS On Add State> <JS Post-Damage as Target> if (value < 0 && this.isHpEffect()) target._healing += -value; </JS Post-Damage as Target> <JS On Expire State> $gameTemp.requestAnimation([target], 101); const healing = Math.round(0.25 * target._healing); target.gainHp(healing); delete target._healing; target.startDamagePopup(); target.clearResult(); </JS On Expire State>
Thanks! It worked perfectly!

New thing though. Sorry if I am annoying. ^^;
Is there a way to reproduce this in MZ

<Custom Regenerate Effect>
// Get the Darkness element.
var elementId = 10;
// Damage set to equal the origin's MAT.
var damage = origin.mat;
// Damage multiplier for weakness/resistance to Darkness element.
damage *= user.elementRate(elementId);
// Round down the damage.
damage = Math.floor(damage);
// Inflict damage to the user.
user.gainHp(-damage);
</Custom Regenerate Effect>

<Custom Remove Effect>
// Declare the dispeller.
var dispeller = BattleManager._subject;
// Check to see if the effect is a leave effect or removal.
var notLeaveEffect = !$gameTemp._customLeaveEffectEval;
// Check the conditions to see if they're met.
if (dispeller && notLeaveEffect) {
// Get the Silence status effect.
var stateId = 6;
// Get the Darkness element.
var elementId = 10;
// Damage set to equal the origin's MAT.
var damage = origin.mat;
// Multiply by 3 to give it the damage of a critical hit.
damage *= 3;
// Damage multiplier for weakness/resistance to Darkness element.
damage *= dispeller.elementRate(elementId);
// Play an animation on the dispeller.
dispeller.startAnimation(102);
// Add the Silence status effect to the dispeller.
dispeller.addState(stateId);
// Deal damage to the dispeller.
dispeller.gainHp(-damage);
// Start the damage popup for the dispeller.
dispeller.startDamagePopup();
// Check to see if the dispeller is dead.
if (dispeller.isDead()) {
// If the dispeller is dead, perform its collapse.
dispeller.performCollapse();
}
// Clear the dispeller's damage popup.
dispeller.clearResult();
}
</Custom Remove Effect>

I tried for he first part, but couldn't getthe JS HP slip damage to check the element weakness of the enemy.
 
Last edited:

XVoid

Conceptual Severance Mage
Member
Joined
Apr 22, 2016
Messages
28
Reaction score
4
First Language
English
Primarily Uses
RMMZ
@XVoid You can use a property and setStateDisplay for this. What have you already tried?
I didn't really know enough JS to even start. I couldn't even get the State Display to show in the console... I could probably edit an example to get it to work for me, but creating code from scratch myself is above my skill level.
 
Last edited:

noside28

Villager
Member
Joined
Jun 4, 2014
Messages
13
Reaction score
0
First Language
Filipino
Primarily Uses
does anyone know how to edit the url and picture for the homescreen in the sample project? It's supposed to be a function from the core engine. But I can't find where to edit it.
 

PauloHPBender

Delirious Storyteller
Veteran
Joined
Oct 16, 2015
Messages
92
Reaction score
23
First Language
Portuguese
Primarily Uses
N/A
Greetings, @Trihan !

Any ideas on how to create a state that negates HP damage from a certain element and converts the damage (that would be dealt) into TP gain? Or maybe something like a "Fire Eater" state, that converts Fire damage into MP gain? I looked into the states notetags but couldn't find any "on damage taken" triggers...
 

CrocPirate

Villager
Member
Joined
Sep 1, 2020
Messages
13
Reaction score
4
First Language
English
Primarily Uses
RMMZ
isHpRecover is a function of Game_Action, not Game_Battler. You need to check it for the action rather than the target.
Okay, thank you. I'm going to do more experimenting right now.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
@shaylina Just so I know I have it correct, what is this actually supposed to do? I get that it's doing dark-based damage and inflicting silence if dispelled, but I'm not sure who's meant to be getting damaged and when.

@XVoid Something like

Code:
<JS On State Apply>
target._stateStacks = target._stateStacks || 0;
target._stateStacks++;
target.setStateDisplay(id of state, target._stateStacks);
</JS On State Apply>
This would only handle the visual part; actually having it do different things depending on number of stacks would be separate, like

Code:
<JS HP Slip Damage>
target.gainHp(-(target._stateStacks * 10));
</JS HP Slip Damage>
That would cause the battler afflicted with the state to take 10 damage for each stack as a slip damage effect.

@noside28 Do you mean the social media buttons? They're under Menu Layout Settings -> Scene_Title -> Title Picture Buttons.

@PauloHPBender The one you want is <JS Pre-Damage as Target>. It sounded like the notetag was the main thing confusing you, but let me know if you need help with the state code itself.
 

TrentL111

Archmage
Veteran
Joined
Oct 13, 2018
Messages
33
Reaction score
12
First Language
English
Primarily Uses
RMMV
@Trihan

Thank you so much. I'll look into that for sure
 

shaylina

Villager
Member
Joined
Mar 26, 2015
Messages
16
Reaction score
2
First Language
French
Primarily Uses
@Trihan That was the origonal code taken from yanfly' tips and tricks in MV. Its the
Unstable Affliction one. The affected unit takes shadow damage over time. However, if it was dispelled, the dispeller takes shadow damage and is silenced.
 

PauloHPBender

Delirious Storyteller
Veteran
Joined
Oct 16, 2015
Messages
92
Reaction score
23
First Language
Portuguese
Primarily Uses
N/A
The one you want is <JS Pre-Damage as Target>. It sounded like the notetag was the main thing confusing you, but let me know if you need help with the state code itself.
Thanks a lot! Since this notetag is on Battle Core, and not in SkillState Core, I got a little confused. About the code, I'll look into old Yanfly's Tips and Tricks and try to adapt it myself, maybe this could be educational.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
@shaylina

Code:
<JS HP Slip Damage>
const elementId = 9;
damage = origin.mat;
damage *= target.elementRate(elementId);
damage = Math.floor(damage);
</JS HP Slip Damage>

<JS On Erase State>
const dispeller = BattleManager._subject;
if (dispeller) {
  var stateId = 6;
  var elementId = 9;
  let damage = origin.mat * 3;
  damage *= dispeller.elementRate(elementId);
  damage = Math.floor(damage);
  $gameTemp.requestAnimation([dispeller], 102);
  dispeller.addState(stateId);
  dispeller.gainHp(-damage);
  dispeller.startDamagePopup();
}
</JS On Erase State>
 

PauloHPBender

Delirious Storyteller
Veteran
Joined
Oct 16, 2015
Messages
92
Reaction score
23
First Language
Portuguese
Primarily Uses
N/A
Any ideas on how to make a "Hidden" State?

The character would use a skill called "Hide", where it leaves the battle field, becoming unreachable for enemies. While in this state, the character is only capable to use "Unhide" and "Shot" skills.
 

stevenblanc

Veteran
Veteran
Joined
Apr 11, 2020
Messages
42
Reaction score
11
First Language
English
Primarily Uses
RMMV
@Trihan ,

Thanks again for the help. Another question; not sure if you have the any of the paid plugins or not... but with the Party System, I would like to use it only for increasing the party size and the locking key party members, but cant figure out how i would disable the reserve system altogether or remove a character altogether from the party even if we leave the reserve in place.

EDIT: Just to clarify; Once a party member is added to the party even for a temporary battle; if they are removed later on, they go to the reserve list instead of leaving both the active and reserve parties. Story-wise, I would like to add actors to the party and then remove them until a much later date or altogether where the actors are temporary supporting actors.
 
Last edited:

RaverRouge

Warper
Member
Joined
Sep 10, 2020
Messages
3
Reaction score
2
First Language
English
Primarily Uses
RMMZ
I'll be honest—the use of JS to achieve some of the plugin's effects is daunting. I'm having difficulty wrapping my head around getting passive states to work. My goal is that whenever an actor learns a skill, the act of learning that skill applies the passive state to said actor. I've been looking at the code provided in the plugin:

<JS Passive Condition>
code
code
condition = code;

</JS Passive Condition>

... and am immediately stuck. I've been looking around to see if there are any lists of code used for RPG Maker MZ so that I might be able to try for myself, but the closest I've found was from MV's damage formulas [isLearnedSkill(skillId)]. The answer will likely be simple and I'll feel a fool for it, but I'd rather feel a fool with a working game mechanic than otherwise.

tldr; Want to make the act of learning a skill immediately apply the correlating state. Thank you for your time.
 

shaylina

Villager
Member
Joined
Mar 26, 2015
Messages
16
Reaction score
2
First Language
French
Primarily Uses
@shaylina

Code:
<JS HP Slip Damage>
const elementId = 9;
damage = origin.mat;
damage *= target.elementRate(elementId);
damage = Math.floor(damage);
</JS HP Slip Damage>

<JS On Erase State>
const dispeller = BattleManager._subject;
if (dispeller) {
  var stateId = 6;
  var elementId = 9;
  let damage = origin.mat * 3;
  damage *= dispeller.elementRate(elementId);
  damage = Math.floor(damage);
  $gameTemp.requestAnimation([dispeller], 102);
  dispeller.addState(stateId);
  dispeller.gainHp(-damage);
  dispeller.startDamagePopup();
}
</JS On Erase State>
Thank you again so much Trihan. :)
 

PauloHPBender

Delirious Storyteller
Veteran
Joined
Oct 16, 2015
Messages
92
Reaction score
23
First Language
Portuguese
Primarily Uses
N/A
I'll be honest—the use of JS to achieve some of the plugin's effects is daunting. I'm having difficulty wrapping my head around getting passive states to work. My goal is that whenever an actor learns a skill, the act of learning that skill applies the passive state to said actor. I've been looking at the code provided in the plugin:

<JS Passive Condition>
code
code
condition = code;

</JS Passive Condition>

... and am immediately stuck. I've been looking around to see if there are any lists of code used for RPG Maker MZ so that I might be able to try for myself, but the closest I've found was from MV's damage formulas [isLearnedSkill(skillId)]. The answer will likely be simple and I'll feel a fool for it, but I'd rather feel a fool with a working game mechanic than otherwise.

tldr; Want to make the act of learning a skill immediately apply the correlating state. Thank you for your time.
I tried to replicate what you're trying to achieve, and all you gotta do is to put the <Passive State: XX> notetag on your skill. As soon as your character learns the skill, it will also receive the passive state.

If you are trying to create "Passive Skills", that are not usable in any occasion and only serves as a means to get the passive state, set the "Occasion" field as "never". The skill will appear on your character's skill list, will grant the passive state, and won't be usable.

1599714402381.png
1599714451013.png
1599714468444.png
 

DigitalWF

Veteran
Veteran
Joined
Apr 13, 2020
Messages
214
Reaction score
57
First Language
English
Primarily Uses
RMMV
@Trihan HELP! really need help with the dragonbone plugin...
I'm using MZ Visustella Dragonbone Union plugin that I got from Aekashic's patron reward, and there are some problems:
1. Some of Aekashic's dragonbone battler will crash the game when I try using the certain attack (Like Attack A) command in battle (some works just fine)
2.I'm using only visu's core,battle and the dragonbone plugins.
3.I also want to edit and add animation inside the dragonbone editor,but when I export the files to MZ, it crashed with this error log
Public_0_Dragonbones.js:13 No armature data: Etest,
s.buildArmature @ Public_0_Dragonbones.js:13
rmmz_managers.js:1968 Uncaught TypeError: Cannot read property 'parent' of null
SceneManager.onError @ rmmz_managers.js:1968
rmmz_managers.js:1969 chrome-extension://njgcanhfjdabfmnlmpmdedalocpafnhl/js/libs/pixi.js 8068
SceneManager.onError @ rmmz_managers.js:1969
pixi.js:8068 Uncaught TypeError: Cannot read property 'parent' of null
at Sprite.addChild (pixi.js:8068)
at Sprite_Actor.Sprite_Battler.<computed>.<computed> [as onLoadDragonbones] (VisuMZ_2_DragonbonesUnion.js:2219)
at Function.DragonbonesManager.<computed> [as runQueuedCallbacks] (VisuMZ_2_DragonbonesUnion.js:2219)
at Function.DragonbonesManager.<computed> [as loadNextArmature] (VisuMZ_2_DragonbonesUnion.js:2219)
at Function.DragonbonesManager.<computed> [as loadComplete] (VisuMZ_2_DragonbonesUnion.js:2219)
at Loader.emit (pixi.js:1257)
at pixi.js:29269
at MiniSignal.dispatch (pixi.js:26746)
at Loader._onComplete (pixi.js:29053)
at pixi.js:29091
DevTools failed to parse SourceMap: chrome-extension://njgcanhfjdabfmnlmpmdedalocpafnhl/js/libs/pixi.js.map
 
Last edited:

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

Latest Threads

Latest Posts

Latest Profile Posts

Why is there so much month left at the end of money? D=
Hello humans! How goes your day in this journey of living? I hope it is good, for I am human like you, and I am feeling great! Worship the altar.
Sand is basically small rocks

Forum statistics

Threads
105,609
Messages
1,014,971
Members
137,273
Latest member
Parzival
Top