Skill order in-game by ID

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
Hello everyone !
It might be a silly question but how do you set the order of the skills in battle by their IDs ?
Everytime a character learns a new skill, it is placed first in the skill selection, which is an issue because I want the skills to remain in a certain order.
I use Yanfly for a lot of things so if there is an answer on a plug-in, I am taking it.
Thanks in advance for anyone who knows how to solve this :)
 

Silva

Scoobityboo
Veteran
Joined
Nov 5, 2018
Messages
399
Reaction score
221
First Language
English
Primarily Uses
RMMV
The engine sorts any learned skills by id by default. How are you giving your actors skills? If you're using normal methods (levelling/event commands) one of your plugins is changing the behaviour. It would be easy to fix if we knew what plugin was causing the issue.
 

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
Hello Silva,
Thank you for your answer.
I tried deactivating all my pluggins, but the problem is still occuring.
However, I might not be using a conventional method :

Thing is, a skill activate common event Number 221, which adds the skill to "Tenpachi" : "Danse du Chevalier".
This skill is the latest ID there is within "Tenpachi's" command, but is still proposed first in battle.
I could unlearn all skills, then add them in order, but it's not only an issue for this specific situation.

If you have any insights, please let me know :) Knowing that I am looking for a trigger (done by a skill) that activates the possible use of a new ability.

Thank you in advance :D

Skill ID not in order.png
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,367
Reaction score
7,676
First Language
German
Primarily Uses
RMMV
I tried deactivating all my pluggins, but the problem is still occuring.
have you started a new game after deactivating the plugins, or did you load a saved game?
part of plugin data is stored inside savefiles, so after any change in the plugin manager you cannot continue older saves.

that said, give us a screenshot of your plugin manager - and please use [alt]-[prtscrn] instead of only [prtscrn] to make your screenshots, that makes them better readable.
 

Silva

Scoobityboo
Veteran
Joined
Nov 5, 2018
Messages
399
Reaction score
221
First Language
English
Primarily Uses
RMMV
This is a normal method and should be sorting your skills by id. When you were testing with all plugins disabled did you create a new game? Though I doubt it's likely to cause issues here, loading a save after changing plugins can result in unexpected behaviour so always best to make sure.

If it's not plugins that are changing the game it may be that you've inadvertently edited the games rpg_objects file. You can check that the games code is normal by using the console in a playtest with no plugins loaded (press F8 in a playtest, navigate to the console tab) and inserting

Code:
$gameActor.actor(1).learnSkill
The console should show the original MV function for actors learning skills (see image).

upload_2019-6-11_20-13-53.png

If you don't get the same result please upload an image of what you do get.
 

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
Thanks for the update Andar and Silva !
I tried launching a new game but same problem occured. Skill is still added first.

I then used the console, and got the same message you get Silva (I added the "s" to "Actors" like in the screenshot.)

Here are my pluggins Andar :

Pluggins (1).png Pluggins (2).png

Just a question since I intend to continue adding game content to a previous version I would send to people :
If there is a change in the pluggins, they are not taken into account for loaded games ? Does that work too for added pluggins or only already existant pluggins ? It seemed to me that I could change stuff to loaded game and it would work right on spot.

EDIT : Wait, this is what I got when I actually loaded my game with pluggins on :

Console.png
 

Silva

Scoobityboo
Veteran
Joined
Nov 5, 2018
Messages
399
Reaction score
221
First Language
English
Primarily Uses
RMMV
Yeah, that was my bad. Glad you figured it out though. :guffaw:

It's strange though. If the code is correct and there are no plugins altering anything I can't see why it wouldn't work. The line that says ".sort(function"... etc should be sorting them.

There aren't any script calls in the event your running to add the skills, is there?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,367
Reaction score
7,676
First Language
German
Primarily Uses
RMMV
@JarexD
three questions:
1) go to help-about of the editor and tell us which version number is displayed there
2) go to your project folder, open the js folder and then open the rpg_core.js folder with a text editor (do NOT doubleclick it). There should be a number after the title (second line of the text), which one is it?
3) go to your project folder and check: is there a folder WWW inside your project folder?
 

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
Thank you guys for the updates !

@Silva : no there is no script calls. However, I got the last message I edited afterwards, which is not the same as you got : it doesn't seem to add the skills the good way.

@Andar : - Version 1.6.2
- Version 1.6.0
- Nope, no www folder inside my project folder, I tried with a new Project, and it doesn't appear either.

Infasia.png
 

Aesica

undefined
Veteran
Joined
May 12, 2018
Messages
1,523
Reaction score
1,415
First Language
English
Primarily Uses
RMMV
Are you possibly learning some skills through equipped items or temporary states? If an equip or state grants use of a skill temporarily, it gets placed at the bottom of the list regardless of its index placement:



In this example. "Cure" is learned by equipping an item whereas the others were learned innately.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,367
Reaction score
7,676
First Language
German
Primarily Uses
RMMV
Version 1.6.0
- Nope, no www folder inside my project folder, I tried with a new Project, and it doesn't appear either.
Please update to version 1.6.2 - the 1.6.0 version was bad and bugridden, they even created the 1.5.2 after the 1.6.0 due to the problems caused by 1.6.0

it is good that there is no www folder - that one is only created on deployment and if you had one in your project, it would have been indication of a mistake on your side that would have damaged your project.
 

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
@Aesica : No, it's not learned this way : it is learned through the use of a skill in-battle that calls a common event. In this common event, a character learns a new skill, this skill is put first, while the ID of the skill should be last.

@Andar : I've updated right now the way people should update it : copied all rpg, libs and Index folders from new project to old. But then I have an issue for the future. I would like to deploy first part of my game now, and last part should be accessible in two years or so. How do I do to keep this version 1.6.2 no matter what so people can play right now and still have same version in two years (I've understood that core folders don't change when people use a saved gamer) ? I will deploy my game small by small since people can keep the saves updated, waiting for me to add a follow of the story. I tried using the bêta in properties to keep a previous version, but it doesn't work - the arrow doesn't lead to anything :

Bêtas.png


Also, concerning Silva's remark, I think the problem could be coming from here since I don't get what I was supposed to get :

Infasia skill Id.png

Thanks everyone for the help !
 

Aesica

undefined
Veteran
Joined
May 12, 2018
Messages
1,523
Reaction score
1,415
First Language
English
Primarily Uses
RMMV
@Aesica : No, it's not learned this way : it is learned through the use of a skill in-battle that calls a common event. In this common event, a character learns a new skill, this skill is put first, while the ID of the skill should be last.
No I meant for the other skills. If your other skills are learned via equips or states, then the skill being given in the way you described would behave exactly as you mentioned--it would appear at the top of the list regardless of index id.

Also, concerning Silva's remark, I think the problem could be coming from here since I don't get what I was supposed to get
The original function still appears to be referenced, so next, try copypasting the following into the console:

Code:
Yanfly.ETP.Game_Actor_learnSkill
If it doesn't match what Silva posted, post the results.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,367
Reaction score
7,676
First Language
German
Primarily Uses
RMMV
@JarexD projects are never updated automatically
you can update the editor if you want, that is no problem and will not autoupdate the project, but if you want the editor to stay at 1.6.2 then just select that instead of "no beta" at the place where you made the screenshot.
 

Silva

Scoobityboo
Veteran
Joined
Nov 5, 2018
Messages
399
Reaction score
221
First Language
English
Primarily Uses
RMMV
Like Aesica said, the original code appears to have been aliased and called within the code brought in by the plugin. This is extremely common in plugins and usually nothing to worry about. Also, skills gained from equipment typically appear after learned skills so if this is the actors only skill that is learned through levels/events it will appear first.
 

JarexD

Villager
Member
Joined
Jun 7, 2019
Messages
6
Reaction score
3
First Language
French
Primarily Uses
RMMV
@Aesica/Silva : You are right, once I write the yanfly code, it goes back to the initial text we were expecting.
@Andar : Well, all of a sudden, the 1.6.2 was available, I will leave it that way for the future, so all good :)

I think I managed to understand why it goes that way, so I will write it in case someone gets the same issue :
The game actually sort the skills whenever I am in the adventure map, but it doesn't reach to the game's files during a battle. So if ever a character learns a new skill DURING a battle (through a call of a common event), it will show first.
If you have the same issue I have and you really want to sort them out the way you want directly in fight, I recommend you do this (which is kind of lame, but works anyway) :

Skill Id order.png

You unlearn all the skills you don't want first, and then you add the new skills and the old ones by puting first the ones who will show last.
Here for example, "Danse du Chevalier" will show last among all of them.
("modifier les compétences" = "modify skills")

Thanks guys for the time you put there !
See you around.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

People3_5 and People3_8 added!

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.

Forum statistics

Threads
105,868
Messages
1,017,083
Members
137,583
Latest member
write2dgray
Top