DNI Skill Core System (Daikenouichi) Script modification request

Panda_Artist

Humble RPG Fan
Veteran
Joined
Dec 22, 2018
Messages
241
Reaction score
15
First Language
Portuguese
Primarily Uses
RMVXA
Good Morning / Day / Afternoon / Evening everyone.

I have a request for a certain kind of script modification.

Once again, it must have this script in mind. I hope I am not violating any rules!

http://dainekoichi.blogspot.com/2015/10/rmvxa-skill-core-system_5.html

Dainekoichi's script allows users to equip a skill core, you don't need to set any skill types either because the script will do it automatically for you (if you have a magic skill type skill and a special skill type skill within the same core, the character will gain both types)

However, I would like to implement two major modifications but unfortunately I don't have enough knowledge of RGSS to implement them properly:

1. Being able to forcefully remove all of the equipped skill cores available via a script call to an actor or all of them (This because in my game there will be times where characters will leave the party or will be seperated. This way I can prompt the player to reconfigure their skill cores at certain points in the game. I tested it and when I remove a party member there is no way I could remove the skill core from him/her)

2. Implementing a progression system where available skill score slots are added as characters level up (for example at level 1 can only equip 2 skill cores ant at level 99 can equip 8).

I did try contact the original creator but to no avail...

Is there any easy way to implement these?
 

Another Fen

Veteran
Veteran
Joined
Jan 23, 2013
Messages
564
Reaction score
275
First Language
German
Primarily Uses
Hey there,

You could try this as an addon to the script:
Code:
#============================================================================
#
#  "Skillcore Unlock and Unequip" - Addon
#  Version 1.02 (July 25th, 2019)
#  by Another Fen <forums.rpgmakerweb.com>
# 
#  This is an unofficial extension for the "DNI Skill Core System" by
#  DaiNekoIchi, which can be found here: http://dainekoichi.blogspot.com/
#
# Contents: -----------------------------------------------------------------
#  This script adds the ability to unlock additional skill cores at specific
#  actor levels. It also offers a script command to unequip any skill core an
#  actor may have currently equipped.
#
# Usage: --------------------------------------------------------------------
#  Add this as a new script below the "DNI Skill Core System" in the script
#  editor and save your project.
#
#  To unlock a new skillcore slot at a specific level, add
#    <add skillcore: 20>
#  to the actors notebox. Alternatively, you can also add this to noteboxes
#  of their classes, states or equipment items.
#  Replace 20 by the respective unlock level.
# 
#  To unequip skillcores of an actor, use this as a script command:
#    unequip_actor_skillcores(10)
#  Replace 10 by the actors database ID, or by 0 to unequip all skillcores
#  available to the party.
#
#============================================================================

class RPG::BaseItem

  def skillcore_unlock_levels
    @skillcore_unlock_levels ||= extract_skillcore_unlock_levels
  end
 
  def extract_skillcore_unlock_levels
    regexp = /<add\s?skillcore(?:(?:\s?at\s?level)?(?:\s?\:)?\s*(\d+))?>/i
    return self.note.scan(regexp).map { |match|
      match[0] ? Integer(match[0]) : 0
    }
  end
end


class Game_Actor
 
  alias_method(:setup_ILC_refreshSkillcoreSlots, :setup)
  def setup(actor_id)
    setup_ILC_refreshSkillcoreSlots(actor_id)
    # Initial refresh, as @skillcores is set up last:
    refresh_skillcore_slots
  end
 
  alias_method(:refresh_ILC_refreshSkillcoreSlots, :refresh)
  def refresh
    refresh_ILC_refreshSkillcoreSlots
    # Skillcores may not be set up yet:
    refresh_skillcore_slots  if @skillcores
  end
 
  def refresh_skillcore_slots
    slotnumber = skillcore_equip_slots
    while @skillcores.length < slotnumber
      @skillcores.push(-1)
    end
    while @skillcores.length > slotnumber
      remove_skillcore(@skillcores.length - 1)  if @skillcores.last != -1
      @skillcores.pop
    end
  end
 
  def skillcore_equip_slots
    return feature_objects.reduce(DAI::SKILLCORES::EQUIP_COUNT) { |result, obj|
      result + obj.skillcore_unlock_levels.count { |lv| lv <= self.level }
    }
  end
 
  def unequip_all_skillcores
    self.skillcores.each_index { |i|
      remove_skillcore(i)  if self.skillcores[i] != -1
    }
  end
end


class Game_Interpreter
 
  def unequip_actor_skillcores(actor_id)
    if actor_id == 0
      actors = $game_party.skillcores.map { |core| $game_actors[core[:actor]] }
      actors = actors.uniq.compact
      actors.each { |actor| actor.unequip_all_skillcores }
    else
      $game_actors[actor_id].unequip_all_skillcores
    end
  end
end
 
Last edited:

Panda_Artist

Humble RPG Fan
Veteran
Joined
Dec 22, 2018
Messages
241
Reaction score
15
First Language
Portuguese
Primarily Uses
RMVXA
I just cannot thank you enough for this, I would pay you if I could, this is absolutely amazing....

You will undoubtedly be credited for this.

Thank you, very much, sir.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,853
Messages
1,016,986
Members
137,561
Latest member
visploo100
Top