When I last worked on my project, I had "upgraded" from Yanfly's YERD Subclass Selection System to his new YEZ Job System: Classes for the sake of new features, such as support for his DEX and RES stats. However, what I didn't realize at the time was that some functionality was lost between the two scripts, namely the ability to restrict access to certain classes by Actor. Accessible classes were editable and designated in a line of script, and in order to gain access to these classes they would have to be "unlocked" via event or item.
With YEZ, however, there doesn't seem to be an item tag or a script call that can unlock classes. Rather, all available classes are designated within the setup portion of the script and become immediately available without any kind of restriction. I can go into reasons why I don't want this to be happening, but the point is that this is not exactly what I'm looking for.
Essentially, I'm looking for a way to create a restriction on accessible classes listed until a script call is used or an item is used. The unlocking of classes would be done on an individual actor basis.
I've included the YEZ Job Class script with this post, as well as the YERD Subclass Selection System script to see if anyone can translate the methods used to restrict/add in that system to the YEZ script.
Though I doubt compatibility would be an issue since this is just a script patch, the major script I need to worry about is GTBS, the rest of my major scripts being Yanfly scripted.
Both of the scripts are apparently way too big, so I'm linking to them externally.
http://shinobi_dan.webs.com/yanfly-YEZ_Job...tem-Classes.txt
http://shinobi_dan.webs.com/subclassselectionsystem.txt
Thanks for the help in advance!
EDIT (PROGRESS?): I was messing around and tried to see if I could make my own method for unlocking classes. I did a bit of research to see if I could figure it out, and came up with the following method, which I added to the Game_Party section:
#--------------------------------------------------------------------------
# new method: unlock_actorclass
# Call using $game_party.unlock_actorclass(actor, class)
#--------------------------------------------------------------------------
def unlock_actorclass(actor_id, class_id)
YEZ::JOB::UNLOCKED_1STCLASS_LIST[actor_id] << class_id
end
And this worked! Sort of. I'm not sure what would be causing this problem, but I can't make the script add classes if there is only one element listed in the array, and I also can't make the script work multiple times per character (for unlocking different classes). Can anyone give me a hand in figuring out what's wrong?
Further progress: Managed to eliminate the first problem by changing it to " += [class_id] ", but I still can't get it to perform addition into the array more than once.
SOLVED: Must initialize original class array at a larger size. I'm not sure why it isn't dynamic, but such is the case. If you know you're going to unlock 20 classes, initialize by having the array as [4,0,0,0,0,0,0,etc.]
With YEZ, however, there doesn't seem to be an item tag or a script call that can unlock classes. Rather, all available classes are designated within the setup portion of the script and become immediately available without any kind of restriction. I can go into reasons why I don't want this to be happening, but the point is that this is not exactly what I'm looking for.
Essentially, I'm looking for a way to create a restriction on accessible classes listed until a script call is used or an item is used. The unlocking of classes would be done on an individual actor basis.
I've included the YEZ Job Class script with this post, as well as the YERD Subclass Selection System script to see if anyone can translate the methods used to restrict/add in that system to the YEZ script.
Though I doubt compatibility would be an issue since this is just a script patch, the major script I need to worry about is GTBS, the rest of my major scripts being Yanfly scripted.
Both of the scripts are apparently way too big, so I'm linking to them externally.
http://shinobi_dan.webs.com/yanfly-YEZ_Job...tem-Classes.txt
http://shinobi_dan.webs.com/subclassselectionsystem.txt
Thanks for the help in advance!
EDIT (PROGRESS?): I was messing around and tried to see if I could make my own method for unlocking classes. I did a bit of research to see if I could figure it out, and came up with the following method, which I added to the Game_Party section:
#--------------------------------------------------------------------------
# new method: unlock_actorclass
# Call using $game_party.unlock_actorclass(actor, class)
#--------------------------------------------------------------------------
def unlock_actorclass(actor_id, class_id)
YEZ::JOB::UNLOCKED_1STCLASS_LIST[actor_id] << class_id
end
And this worked! Sort of. I'm not sure what would be causing this problem, but I can't make the script add classes if there is only one element listed in the array, and I also can't make the script work multiple times per character (for unlocking different classes). Can anyone give me a hand in figuring out what's wrong?
Further progress: Managed to eliminate the first problem by changing it to " += [class_id] ", but I still can't get it to perform addition into the array more than once.
SOLVED: Must initialize original class array at a larger size. I'm not sure why it isn't dynamic, but such is the case. If you know you're going to unlock 20 classes, initialize by having the array as [4,0,0,0,0,0,0,etc.]