[XP] Unlearn Skills on Class Change ?

hey everyone, im using Legacy Class Change --> demo http://legacyblade.com/downloads/scripts/LSC/LegacyClassChangev1_68.zip

when i change my class to another it keeps the same skills from that class regardless of changing it to another class.

is there a way to modify this script, so the skills defer from one class to another ?

changeclassscript.txt a text file with the script

and finally heres a snippet of code :

 def actor_class_change(actor_id, class_id)
   
    #setup which actors' class needs to be changed.
    changed_actors = LBConf.linked_actors(actor_id)
    changed_actors.push actor_id
   
    #memorize which class specific skills the actor has learned for the current
    #class, then make the actor forget them
    LBConf.class_spells($game_actors[actor_id].class_id).each{|skill_id|
    $game_actors[actor_id].forget_skill(skill_id)}
   
    #change the actor(s) class.
    changed_actors.each{|actorz|
    $game_actors[actorz].class_id = class_id
   
    #remember any class specific spells the actor has forgotten forthe class
    #they're changing to.
    $game_actors[actorz].learned_class_skills.each{|skill_id|
    if LBConf.class_spells($game_actors[actorz].class_id).include?(skill_id)
      $game_actors[actorz].learn_skill(skill_id)
    end}
   
    #if graphic changing is enabled, change the actor's graphic.
    if LBConf::CLASS_GRAPHIC_CHANGE == true
      actor_graphics_change(actorz)
    end}
   
  end

i think the answer is in that part, but im not sure, any help would be greatly appreciated
I've moved this thread to RGSSx Script Support. Please be sure to post your threads in the correct forum next time. Thank you.
I took a quick look at the script and it seems like it should work fine. Can you post your configuration section? Something might be messed up there.
Hey möbius thanks for the reply , i think I fixed it by making all skills lvl 2 or higher before being learned. That seemed to do tge trick. For some reason it just wouldn't work at lvl 1.

Original thread: https://forums.rpgmakerweb.com/threads/xp-unlearn-skills-on-class-change.51670/