The official VisuStella notetag help thread

Weremole

Veteran
Veteran
Joined
Jan 22, 2016
Messages
365
Reaction score
330
First Language
Swedish
Primarily Uses
You could create a text code replacement for it and add your conditional to the code there.
I've considered it and it seems possible now that I looked at this more closely, like you can split a number input in the textcode tag. Just need to look how the default MZ textcodes draw icons I guess. The rest is setting the actor and skill variables and putting them in the If branch.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,005
Reaction score
5,962
First Language
English
Primarily Uses
RMMZ
I've considered it and it seems possible now that I looked at this more closely, like you can split a number input in the textcode tag. Just need to look how the default MZ textcodes draw icons I guess. The rest is setting the actor and skill variables and putting them in the If branch.
Hrm, yeah. I tried returning '\i76]' in the text code text but it just shows as-is (tried with 2 slashes as well) so doesn't look like they support using codes themselves. Which makes sense I guess.

All the other ones that show icons call existing functions which just take a boolean parameter for whether to display the icon or not.
 

Onox

Villager
Member
Joined
Apr 17, 2020
Messages
10
Reaction score
3
First Language
French
Primarily Uses
RMMZ
Hi ! As a total noob in JS I desperately try to port some Yanfly Tips and Tricks to MZ. Can you help me with this one? : "Cleric Stance"
<Custom Confirm Effect>
// Check if the action is magical and deals HP damage.
if (this.isMagical () && this.isHpEffect () && value> 0) {
// Then increase the damage dealt to 120%.
value = Math.ceil (value * 1.20);
// Chec if the action is magical and heals HP.
} else if (this.isMagical () && this.isHpEffect () && value <0) {
// Then decrease the healing done to 80%.
value = Math.ceil (value * 0.80);
}
</ Custom Confirm Effect>


For the state, and for the skill :

<Before Eval>
// The State ID of the Cleric Stance.
var clericStanceId = 155;
// Check if the user is affected by the state.
if (user.isStateAffected (clericStanceId)) {
// If the user is, then remove the state.
user.removeState (clericStanceId);
// If the user isn't ...
} else {
// Then add the state.
user.addState (clericStanceId);
}
</ Before Eval>

Thank you very much !
 
Last edited:

Junane

Veteran
Veteran
Joined
Feb 10, 2018
Messages
103
Reaction score
17
First Language
English
Primarily Uses
RMMV
Hi ! As a total noob in JS I desperately try to port some Yanfly Tips and Tricks to MZ. Can you help me with this one? : "Cleric Stance"



For the state, and for the skill :



Thank you very much !

Below code goes into the State:
<JS Pre-Damage as User>
if (this.isHpEffect() && this.isMagical() && value > 0){
value = Math.ceil(value * 1.2);
} else if (this.isHpEffect() && value < 0){
value = Math.floor(value * 0.8);
}
</JS Pre-Damage as User>

And this into the skill itself:
<JS Post-Apply>
if (user.isStateAffected(x)){
user.removeState(x);
} else {
user.addState(x);
}
</JS Post-Apply>
changing x into your state's ID.
 

Onox

Villager
Member
Joined
Apr 17, 2020
Messages
10
Reaction score
3
First Language
French
Primarily Uses
RMMZ
Below code goes into the State:
<JS Pre-Damage as User>
if (this.isHpEffect() && this.isMagical() && value > 0){
value = Math.ceil(value * 1.2);
} else if (this.isHpEffect() && value < 0){
value = Math.floor(value * 0.8);
}
</JS Pre-Damage as User>

And this into the skill itself:
<JS Post-Apply>
if (user.isStateAffected(x)){
user.removeState(x);
} else {
user.addState(x);
}
</JS Post-Apply>
changing x into your state's ID.
Many thanks ! I reread each page of this thread 10 times to find the solution without success ^^ "

If anyone has a little time I also have problems reproducing this effect:
<Custom Turn End Effect>
if (user.mp == 0) {user.removeState (16)};
</ Custom Turn End Effect>

I also have a few questions, I can't find a solution to reproduce this: <Target: All Allies But User> is this not possible at the moment?

And I suppose that to reproduce everything related to "auras" we will have to wait for a dedicated plugin ?

Is there a solution to transpose all: <Custom Apply Effect>
or should they be changed on a case-by-case basis depending on their effect?

Once again thank you for your answers :)
 
Last edited:

Junane

Veteran
Veteran
Joined
Feb 10, 2018
Messages
103
Reaction score
17
First Language
English
Primarily Uses
RMMV
Many thanks ! I reread each page of this thread 10 times to find the solution without success ^^ "
If anyone has a little time I also have problems reproducing this effect:
<Custom Turn End Effect>
if (user.mp == 0) {user.removeState (16)};
</ Custom Turn End Effect>
I also have a few questions, I can't find a solution to reproduce this: <Target: All Allies But User> is this not possible at the moment?
And I suppose that to reproduce everything related to "auras" you will have to wait for a dedicated plugin ?
Is there a solution to transpose all: <Custom Apply Effect>
or should they be changed on a case-by-case basis depending on their effect?
Once again thank you for your answers :)
You can change <Custom Turn End Effect> into "<JS Pre-End Turn>"* and <Custom Apply Effect> is turned into "<JS On Add State>"; <Target: All Allies But User> goes into the skill or item and overwrites the original scope to affect the party even if it targets an enemy.

*This also has <JS Post-End Turn> as another alternative.
 

Onox

Villager
Member
Joined
Apr 17, 2020
Messages
10
Reaction score
3
First Language
French
Primarily Uses
RMMZ
You can change <Custom Turn End Effect> into "<JS Pre-End Turn>"* and <Custom Apply Effect> is turned into "<JS On Add State>"; <Target: All Allies But User> goes into the skill or item and overwrites the original scope to affect the party even if it targets an enemy.

*This also has <JS Post-End Turn> as another alternative.
Thank you for your quick reply !
I will try it !

PS : Sorry for "all allies except the user" I thought it was not working but I did not see well ...
 
Last edited:

Cyberhawk

Bravelion Leader
Veteran
Joined
Jan 9, 2019
Messages
150
Reaction score
109
First Language
English
Primarily Uses
RMMZ
WOuldn't it be easier if there was a list of the MV Tips and Tricks that work in MZ or the ones that were modified to work in MZ instead of scouring 15+ pages of text?
 

Weremole

Veteran
Veteran
Joined
Jan 22, 2016
Messages
365
Reaction score
330
First Language
Swedish
Primarily Uses
Hrm, yeah. I tried returning '\i76]' in the text code text but it just shows as-is (tried with 2 slashes as well) so doesn't look like they support using codes themselves. Which makes sense I guess.

All the other ones that show icons call existing functions which just take a boolean parameter for whether to display the icon or not.
I'm doing something terribly wrong here.

const textState = arguments[0];

const data = this.obtainEscapeString(textState).split(',');

if (textState.drawing) {

const actor = parseInt(data[0].trim());

const skill = parseInt(data[1] || '0');{

if $gameActors.actor(actor).skills().contains($dataSkills[skill]); {



const icon = 92

return this.drawIcon(icon);

}else{

const icon = 74

return this.drawIcon(icon);



}

}
 

Corygon

Storyteller
Veteran
Joined
Mar 20, 2019
Messages
34
Reaction score
46
First Language
English
Primarily Uses
RMMZ
WOuldn't it be easier if there was a list of the MV Tips and Tricks that work in MZ or the ones that were modified to work in MZ instead of scouring 15+ pages of text?
That'd be awesome.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,005
Reaction score
5,962
First Language
English
Primarily Uses
RMMZ
That'd be awesome.
Almost all of them do except the ones which use Selection Control or Target Core. I know this because I've recreated all of them in MZ for a client. :p

I am working on a document outlining the notetag changes required to make them compatible, but I'm not done yet.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,005
Reaction score
5,962
First Language
English
Primarily Uses
RMMZ
Did you remove the entire lines or just the word "return" from those lines? I meant the latter, in case that wasn't clear.
 

Weremole

Veteran
Veteran
Joined
Jan 22, 2016
Messages
365
Reaction score
330
First Language
Swedish
Primarily Uses
Did you remove the entire lines or just the word "return" from those lines? I meant the latter, in case that wasn't clear.
Just the word 'return'.
 

WilsonE7

Veteran
Veteran
Joined
Oct 12, 2019
Messages
139
Reaction score
68
First Language
English
Primarily Uses
RMMZ
Hey, @Trihan I was trying to figure out how to make an event shake or tremble, and I remembered that YEP's Event Sprite Offset plugin had move route script calls to offset the sprite by n pixels. I haven't seen anything like that in VisuStella's plugins, but I thought I'd ask. Is there any way to implement that, or are there any plans to bring that back?
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,005
Reaction score
5,962
First Language
English
Primarily Uses
RMMZ
Hey, @Trihan I was trying to figure out how to make an event shake or tremble, and I remembered that YEP's Event Sprite Offset plugin had move route script calls to offset the sprite by n pixels. I haven't seen anything like that in VisuStella's plugins, but I thought I'd ask. Is there any way to implement that, or are there any plans to bring that back?
The script calls are the same as in the MV plugin: this._spriteOffsetX = whatever and this._spriteOffsetY = whatever.
 
Last edited:

WilsonE7

Veteran
Veteran
Joined
Oct 12, 2019
Messages
139
Reaction score
68
First Language
English
Primarily Uses
RMMZ
The script calls are the same as in the MV plugin: this._spriteOffsetX = whatever and this._spriteOffsetY = whatever.
Thanks! I wish they put that in the documentation, though.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,005
Reaction score
5,962
First Language
English
Primarily Uses
RMMZ
Thanks! I wish they put that in the documentation, though.
As far as I was aware VisuStella was focusing on putting easy-to-use tools in the hands of developers who can't code their own; the focus was more on plugin commands and parameter functionality than documenting every script call. By all means stick that in the suggestion box if you want to, though.
 

Ys42

Veteran
Veteran
Joined
Nov 24, 2019
Messages
36
Reaction score
7
First Language
Ukrainian
Primarily Uses
RMMV
What do you mean by add state via notetags?
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.
 

Latest Threads

Latest Profile Posts

Has it really been 50 streams? At this point it's just guilting me into pushing out a prototype. :kaoswt:



I should probably just bite the bullet and send it out, then go with my original plan to provide weekly updates.
I know it's just other small RM devs, but it still always feels legitimizing to have folks email me in private with a steam key, requesting a review of their game.:kaoluv: Look ma, I've made it to the big leagues. small edit: another email just came in. :kaoback:
time and time again I enjoy dramatic remarks on how I should find a better job.
As it stands, I go to work for 10-14 days a month. At work, I have time for my private projects. I arrive home, my mind is clear.
So yes, the pay sucks. But I have what so many lose after graduation. Freedom.
Came back cuz of the sale. Got MZ. The System 2 advanced settings for UI are so frustrating, and I see we still hate pixel fonts. Marvelous.
Did another YouTube short. This one has like 1k views (or maybe 380? Analytics is being weird). Getting them zoomer views, yo!

Forum statistics

Threads
129,720
Messages
1,204,649
Members
170,803
Latest member
JimGTz
Top