Status
Not open for further replies.

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
Hello,

i'm kind of new on making rpg games, but i was trying to create something like a state that isn't always active, but activate itself at the start of a battle, also that same state showing as a passive skill on the character's abilities tab, and when you reach at certain level that you learn an upgrade of that ability, the weaker skill is deleted/unlearned. (I mean upgrade of the ability just like in final fantasy that you have thundaga being a stronger version of thundara)

Someone could help me on how to do this?
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,117
Reaction score
14,639
First Language
English
Primarily Uses
RMMV
Hi, can you please edit your post and put in a more meaningful title? Given that you've posted in the MV forum, every post here is about RMMV ;)
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
Sorry, forgot to change that before posting, changed
 

coucassi

Veteran
Veteran
Joined
Sep 23, 2019
Messages
76
Reaction score
100
First Language
German
Primarily Uses
RMMV
I would recommend using plugins to do that. Yanfly has made one called Auto Passive States which should do the trick for the first issue, while for upgrading skills there are several plugins you could check out too.

If you don't want to do this however you could create a battle event that runs at the start of every battle and inflicts the state on your actor. You would set the state to wear off after battle then and just copy the event every time you design a new troop.

Then for the state to show as a skill in the actors profile you just need to create an unusable skill that does nothing with that name.
I'm not sure how to replace that skill without using plugins though, at least not via level up. You sure could use a parallel event that checks if your actor learned the new skill and if so deletes the old one, but since you can't know when exactly his happens you would need to place this event on every map ...
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
I would recommend using plugins to do that. Yanfly has made one called Auto Passive States which should do the trick for the first issue, while for upgrading skills there are several plugins you could check out too.

If you don't want to do this however you could create a battle event that runs at the start of every battle and inflicts the state on your actor. You would set the state to wear off after battle then and just copy the event every time you design a new troop.

Then for the state to show as a skill in the actors profile you just need to create an unusable skill that does nothing with that name.
I'm not sure how to replace that skill without using plugins though, at least not via level up. You sure could use a parallel event that checks if your actor learned the new skill and if so deletes the old one, but since you can't know when exactly his happens you would need to place this event on every map ...
Yeah i've seen Yanfly's Auto Passive plugin, but it sets the state on the the character to always active, the thing i needed would be active only during the battle and removed in the end or when the character/party gets out of battle.

Also the problem with creating a battle event would be that i would have to add it in every troop in the game and this might lead to bugs anywhere in the middle of the game.

I wouldn't mind at all to use plugins if anyone knows one that does the trick (besides the auto passive). If it is of any help i have a character selection at the intro and i was trying to mix a common event with maybe a simpler script to start after the selection of the character and keep it running through the game so it can check if the hero learned one skill it can remove the weakest one of that type or the previous version of it, but couldn't find the right way to code the whole idea since i have barely no knowledge about javascript.
 

JGreene

Veteran
Veteran
Joined
Oct 24, 2015
Messages
452
Reaction score
360
First Language
English
Primarily Uses
RMMV
You can add new skills and seal other skills, when affected by a state, through the editor. Removing skills would need a line of script to be run through a method available via Yanfly's Auto Passive States.
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
You can add new skills and seal other skills, when affected by a state, through the editor. Removing skills would need a line of script to be run through a method available via Yanfly's Auto Passive States.
The idea is the skill to being shown in the ability tab, would be only for informational purposes (like show the player what the skill does), don't know if it's exactly what'd you meant, but the skill is not activated ever so it can't seal other skills, otherwise i would need to use it on battle or on the map to seal the other skill isn't it? Please correct me if i'm thinking it the wrong way.
 

JGreene

Veteran
Veteran
Joined
Oct 24, 2015
Messages
452
Reaction score
360
First Language
English
Primarily Uses
RMMV
Honestly, I didn't entirely understand the context of your post. However, I do know the general mechanics of the spells in Final Fantasy.

If you're using a powerup method: Use Thunder > Learn Thundara > Use Thundara > Learn Thundaga > Reset back to Thunder at the end of battle... this can be done with YEP Auto Passive States and Buffs and States Core (both are still free). Bear with me on the syntaxes. I'm at work but I'll help as much as I can to get it right.

Add the passive state to the actor or class and then add this note in the state:

<Custom Battle Effect>
user.forgetSkill(x) //Thundara ID
user.forgetSkill(x) //Thundaga ID
</Custom Battle Effect>

On casting Thunder add another state to the actor that lasts the whole battle "Learn Thundara"

<Custom Apply Effect>
user.learnSkill(x) //Thundara ID
user.forgetSkill(x) //Thunder ID
</Custom Apply Effect>

Then replicate this to forget Thundara and learn Thundaga. You'll have to figure out how you want to relearn Thunder, which there are a few ways to do that but it depends if this is even the right solution for you. Sealing skills would simplify the method above. If you want the states to last forever, keeping the higher level spells, just uncheck remove after battle. But be careful of the "Recover All" command as it removes all states unless protected by something like

<Bypass Recover All Removal> available with YEP X State Categories (which is now a paid plugin)
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
The final fantasy thing was just an example for a stronger skill, but not the exact mechanics i'm searching, let me try to explain better.

What i'm looking for is:
1 - Some way to add a state to a character at the start of any battle with any enemy (The removal can be done with the option to remove state after battle, but adding the state is the problem without having to add the condition in every troop in the game.
2 - That same state will be shown as an ability in the character ability tab, but the ability will not be able to be activated (on this item, it's after this bracket that i need help) and when the character reaches a certain level it will unlearn one skill and learn an upgraded version of it.
3 - The state that the hero starts the battle with, will have to change so it can match the skill the character has (example: if character have a lifesteal 1 skill at level 5 it starts the battle with lifesteal 1 state, if character learns lifesteal 2 at level 15, character unlearns lifesteal 1 and starts the battle with lifesteal 2).
 

JGreene

Veteran
Veteran
Joined
Oct 24, 2015
Messages
452
Reaction score
360
First Language
English
Primarily Uses
RMMV
So, is skill learning designed in a sense that a character might not learn a skill at a particular level? Like maybe level 16 instead of 15. Because if they do learn skills at set levels, then you should be able to program it through the default engine.

So for #1, that can be a passive state on the character. #2, the unusable skill can be added through the passive state (learn and seal simultaneously, the only way to keep it from ever being used but still shows help info). For #3, maybe this will work:

<Custom Battle Effect>
if (user.level >= 25)
{
user.learnSkill(7); // Level 3 Spell
user.forgetSkill(6); // Level 2 Spell
user.forgetSkill(5); // Level 1 Spell
} else if (user.level >= 15) {
user.learnSkill(6);
user.forgetSkill(5);
} else {
user.learnSkill(5); // Failsafe check
};
</Custom Battle Effect>
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
897
Reaction score
478
First Language
English
Primarily Uses
RMMV
Yeah i've seen Yanfly's Auto Passive plugin, but it sets the state on the the character to always active, the thing i needed would be active only during the battle and removed in the end or when the character/party gets out of battle.
No, it doesn't. If you read through the documentation, most of the notetags the plugin provides are different conditions for states to activate themselves.

Also...exactly what does the state do? Why would it matter if it's active when the party is out of battle? Most states provide some effect in battle, so if you're not fighting, it doesn't matter whether it's on or off.

But this would be trivial with Yanfly's Passive States. You give the skill a <Passive State: x> notetag, then in that state you give it a <Passive Condition: Switch x ON> notetag.

Give each of your troops a Turn 0 battle event that turns that switch on (or use Yanfly's Base Troop Events to save yourself time), and use SumRndmDde's Battle End Events to turn the switch back off.
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
The skill learn and unlearn i've been able to manage through common event mechanics, in the way that as soon as you select the character and the intro ends it turns on a permanent common event to identify the character's level (ex: if character lv is >= 2 it learns skill 1, if character lv is >= 10 it unlearns skill 1 and learns skill 2).

Now i need to figure out a way to make work the battle state to start and define wich state will be (when i say define wich state it's for me the one developing the game to set not the player)
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
No, it doesn't. If you read through the documentation, most of the notetags the plugin provides are different conditions for states to activate themselves.

Also...exactly what does the state do? Why would it matter if it's active when the party is out of battle? Most states provide some effect in battle, so if you're not fighting, it doesn't matter whether it's on or off.

But this would be trivial with Yanfly's Passive States. You give the skill a <Passive State: x> notetag, then in that state you give it a <Passive Condition: Switch x ON> notetag.

Give each of your troops a Turn 0 battle event that turns that switch on (or use Yanfly's Base Troop Events to save yourself time), and use SumRndmDde's Battle End Events to turn the switch back off.
Well, for as long as i have read Yanfly's Passive States he even says it in the description that the state would be always active, and haven't seen this part of the passive condition on his instructions to use the plugin, can i set like the passive condition to Battle Start or something like it? Otherwise i actually watched his video again now and he said something about adding a passive state to a skill, i think with that it would be possible to the skill give me the state when i have it learned just by starting the battle if the passive condition can be made to Battle Start.

But this Base Troop Events also looks interesting, i'm gonna take a look at it.
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
No, it doesn't. If you read through the documentation, most of the notetags the plugin provides are different conditions for states to activate themselves.

Also...exactly what does the state do? Why would it matter if it's active when the party is out of battle? Most states provide some effect in battle, so if you're not fighting, it doesn't matter whether it's on or off.

But this would be trivial with Yanfly's Passive States. You give the skill a <Passive State: x> notetag, then in that state you give it a <Passive Condition: Switch x ON> notetag.

Give each of your troops a Turn 0 battle event that turns that switch on (or use Yanfly's Base Troop Events to save yourself time), and use SumRndmDde's Battle End Events to turn the switch back off.
The thing about the passive not being active outside of battle is because it gives bonus stats like critical rate +, but it will consume mana overtime
 

JGreene

Veteran
Veteran
Joined
Oct 24, 2015
Messages
452
Reaction score
360
First Language
English
Primarily Uses
RMMV
The common event you described is the same as the passive condition note tag I just posted. And it triggers on battle start (turn 0).

The thing about the passive not being active outside of battle is because it gives bonus stats like critical rate +, but it will consume mana overtime
This adds more complexity. You didn't state this before. The notetag I posted only works in battle. If the skill simply being learned causes mana drain, that's something you could do in a common event as some kind of pseudo slip damage mechanic that loops on a set timer (for example 1 MP every 300 frames or 5 seconds).
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
The common event you described is the same as the passive condition note tag I just posted. And it triggers on battle start (turn 0).


This adds more complexity. You didn't state this before. The notetag I posted only works in battle. If the skill simply being learned causes mana drain, that's something you could do in a common event as some kind of pseudo slip damage mechanic that loops on a set timer (for example 1 MP every 300 frames or 5 seconds).
That's the thing, i don't want it to consume mana out of battle, the mana consumption over time i know how to make, but my problem is to make the state activate only in battle, although i'm testing now ATT_Turan's idea to use passive states condition combined with base troops
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
897
Reaction score
478
First Language
English
Primarily Uses
RMMV
Well, for as long as i have read Yanfly's Passive States he even says it in the description that the state would be always active, and haven't seen this part of the passive condition on his instructions
I don't want to come off as snarky, but if you read literally any farther than the Introduction, the entirety of the page is a huge lists of conditions to turn the states on and off.
can i set like the passive condition to Battle Start or something like it?
No, you can do what I gave you the instructions for.
Otherwise i actually watched his video again now and he said something about adding a passive state to a skill
Yes, again, as I said in my instructions. I feel like you're responding to me (and having opinions about the plugin) without actually reading my post or the plugin documentation.

Go through my prior post more carefully, reference the words I use against the plugin documentation:
Then let me know if it doesn't work correctly once you've set it up.
 

Neither

Villager
Member
Joined
Apr 10, 2021
Messages
10
Reaction score
0
First Language
Portuguese
Primarily Uses
RMMV
Tested here, and the auto passive states was bugging the learn/unlearn factor and also even with the passive condition the state was activated in and out of battle, so i did what ATT_Turan said about the base troop events and combined it with the common event and now it's working fine. Thanks everyone for the help
 

slimmmeiske2

Little Red Riding Hood
Global Mod
Joined
Sep 6, 2012
Messages
8,362
Reaction score
5,526
First Language
Dutch
Primarily Uses
RMXP

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

 
Status
Not open for further replies.

Latest Threads

Latest Posts

Latest Profile Posts

I'm very happy and I want everyone to be happy too, so I decided to share this song about the end of the world! :biggrin:
I just booked a spot for my COVID vaccine today. I am just waiting to see when they can get me in. I'll be so happy when I don't have to be paranoid about the virus anymore. I'm also thinking about moving to Atlanta, Georgia, Denver, Colorado, or Houston, Texas in the far future. Maybe once my channel gets off the ground.
Went to get a haircut today, and the lady cut my hair too short... Well I suppose with the pandemic I'm not going out a lot, but it still feels a bit uncomfortable.
For real, they didn't tell me anything about THAT dragon bomber before. It could be the greatest invention since sliced bread, that's for sure!
Random Thought: Team Visustella has become the Power Rangers of RPG Maker, and Yanfly is their Zordon.

Forum statistics

Threads
111,154
Messages
1,058,764
Members
144,393
Latest member
pantherman78
Top