How to make a state not applicable outside of battle?

pedrocarsamar

Villager
Member
Joined
Jun 19, 2017
Messages
23
Reaction score
12
First Language
portuguese
Primarily Uses
RMVXA
Hello. One of my characters has this skill which removes negative conditions and, additionally, applies a "prevention state" to the target, so that his ally not only gets health, but prevents further negative states by a certain number of turns. (Hylics' players know precisely what it means) I want this skill to work both on battle and on menu, but differently.

* On battle, I want the skill to heal negative conditions AND apply the "prevention state";
* But on the menu, I want the same skill to heal negative conditions, but not to apply the "prevention state", since the player could do this before every battle to get advantage.

The lazy way to get around with this issue is to create two skills: one usable on battles and one usable on menus. But I particularly think this would pollute the skill repertoire.

Is there a way to do what I'm planning?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
36,258
Reaction score
9,691
First Language
German
Primarily Uses
RMMV
That method isn't "lazy", it's basically the only one that works in the default engine of VXA.

the only alternative would be with using scripts that add new options to the engine - yanfly's lunatic states might contain a solution or something similar.
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
4,512
Reaction score
2,877
First Language
English
Primarily Uses
RMMV
But on the menu, I want the same skill to heal negative conditions, but not to apply the "prevention state", since the player could do this before every battle to get advantage.
The other easy thing to do is add a Turn 0 troop event to your troops that checks for any party members to have the preventative state and remove it.
 

pedrocarsamar

Villager
Member
Joined
Jun 19, 2017
Messages
23
Reaction score
12
First Language
portuguese
Primarily Uses
RMVXA
Thank you for your contributions. I took a sight over the Lunatic States before making this thread, but I'm too dumb to make it work. For the time being, Turan's suggestion seems to be the best thing I could right now. So I'll just stick to it, unless I find another solution.
 

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
4,127
Reaction score
1,108
First Language
English
Primarily Uses
RMVXA
Could you not have the skill call a common event and then have the common event check if the player is in battle, then apply the state if true.
You can do a conditional branch script check in the CE
if SceneManager.scene_is?(Scene_Battle)
add state
end branch
 
Last edited:

pedrocarsamar

Villager
Member
Joined
Jun 19, 2017
Messages
23
Reaction score
12
First Language
portuguese
Primarily Uses
RMVXA
Could you not have the skill call a common event and then have the common event check if the player is in battle, then apply the state if true.
You can so a conditional branch script check in the CE
if SceneManager.scene_is?(Scene_Battle)
add state
end branch
That's actually a great idea, thx. But as I was trying to implement it, I've just got a new insight. Since I'm using Yanfly's follow up skill script, I can make the healing skill be followed by another that adds the state, but only if "SceneManager.scene_is?(Scene_Battle)" is true. And it surprisingly worked
 
Last edited:

Latest Threads

Latest Profile Posts

Mixing different pixi filters over a picture. :MV3:

lumina_in_space.jpg

I don't know if my game dev skills are improving... But my waifu making ones sure are. :LZSwink:
Who wants to solve a riddle from my game?
"I prayed for her to lay down her worldly habit and accept the invitation to change her life forever." From lost to found. From past to present, From frown to smile. From the way people treat her as nothing but something to say wow about. From faithless to faithful. From something no one wants to something valuable, someone will respect and love. Thank you, Jesus.
Two new amazing plugins from @NhatNguyen! Footsteps & Stamina. Video on Twitter showcasing:

Forum statistics

Threads
123,096
Messages
1,153,942
Members
161,424
Latest member
kiamat
Top