Skills Learning System by Charlie Fleed Version 2.3 (8-8-2010)
Introduction
Hi all. This script started as a Skills Learning System modeled after the system featured in Final Fantasy 9, but it now offers a lot more.
With this system you can:
1) learn skills by using weapons and armors/accessories and earning weapon/armor exp points;
2) set up skills that are immediately available once the corresponding weapon/armor/accessory is equipped;
3) set some skills to require a specified equipment in order to be used during battles;
4) set some skills to require a minimum character level before they can be learned;
5) limit the skills a character can learn to the only ones listed as available for his/her class in the database;
6) teach skills or give skill exp points for specific skills to characters by using items.
Methods have been added to give characters exp points with events, using the script event command. See the examples in the demo.
The following screen shows the learning status.
The character has mastered "Cross Cut", and is learning Barrier and Spiral Blade. Barrier can be permanently learned from the shield, Spiral Blade from the sword.
The skills however are already available as they also are equipment skills, as indicated by the yellow dot over the equipment icons.
As usual I would like you to try it, and report bugs, give comments, suggestions...
Enjoy!
It doesn't use the SDK. Almost everything is done through aliasing, I think it should have good compatibility with other scripts.
Features
Features
Full support of learning from weapons, all armor types and items.
Learning of skills can be limited on a class basis.
Learning of skills can be limited based on the character's level.
Configurable amount of exp_points needed for each skill.
A learning status screen that shows the exp points for the learning process.
Shop Add-On, Equip Add-On and Item Add-On: display animated window with information about skills.
Skills that cannot be learned are shown in disabled color (applies to learning status scene, equip scene, shop scene and item scene).
Screenshots
Screenshots
Instructions
Inside the demo.
FAQs
How to add a Learning Status entry in the menu.
Q:How to add a Learning Status entry in the menu. A:Since version 1.7 the Learning Status is not accessible from the Status scene by pressing a key. In order to access the Learning Status from the main menu you can do the following.
when 4 # save
# If saving is forbidden
if $game_system.save_disabled
# Play buzzer SE
$game_system.se_play($data_system.buzzer_se)
return
end
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to save screen
$scene = Scene_Save.new
when 5 # end game
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to end game screen
$scene = Scene_End.new
end
and replace it with
Code:
when 4 # learning status
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Make status window active
@command_window.active = false
@status_window.active = true
@status_window.index = 0
when 5 # save
# If saving is forbidden
if $game_system.save_disabled
# Play buzzer SE
$game_system.se_play($data_system.buzzer_se)
return
end
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to save screen
$scene = Scene_Save.new
when 6 # end game
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to end game screen
$scene = Scene_End.new
end
In Scene_Menu::update_status find
Code:
when 3 # status
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to status screen
$scene = Scene_Status.new(@status_window.index)
end
and replace it with
Code:
when 3 # status
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to status screen
$scene = Scene_Status.new(@status_window.index)
when 4 # learning status
# Play decision SE
$game_system.se_play($data_system.decision_se)
# Switch to status screen
$scene = Scene_Learning_Status.new(@status_window.index)
end
i really love this script but i want that if you equip a weapon, you can learn the skill permanently and you can also use it right away. But when i
put a skill in
EQUIPMENT_LEARNINGS and EQUIPMENT_SKILLS as well, it shows the skill 2 times in the window.
What do i have to change that the U(: indicates a skill that can be used right away) Term isn't shown, because
i set up each skill like that (equip a weapon, can learn the skill and use it also right away)
FFIX Skills Learning System aka Equipment Skills, NEW!!! v2.2 (6-1-2010) - Charlie Fleed - 11-21-2009
In "SLS Windows" at line 171, replace the refresh method with this one
Code:
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
x = 0
y = 0
if $scene.is_a?(Scene_Shop)
draw_actor_name(@actor, x, y)
y+=24
end
self.contents.font.color=system_color
self.contents.draw_text(x,y,320,self.contents.font.size,"Equipment Skills")
y+=self.contents.font.size+2
self.contents.font.color=normal_color
if @equip_type==0 and @equip_id!=0 and $game_party.
learning_db[$data_weapons[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_weapons[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
end
end
if @equip_type>0 and @equip_id!=0 and $game_party.
learning_db[$data_armors[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_armors[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
end
end
end
FFIX Skills Learning System aka Equipment Skills, NEW!!! v2.2 (6-1-2010) - Charlie Fleed - 01-07-2010
Updated to version 2.2.
The system has been patched to be compatible with DerVVulfman's Multi-Slots system.
There are a few minor improvements too, including a more clear (I think) learning status.
Charlie Fleed Wrote:In "SLS Windows" at line 171, replace the refresh method with this one
Code:
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
x = 0
y = 0
if $scene.is_a?(Scene_Shop)
draw_actor_name(@actor, x, y)
y+=24
end
self.contents.font.color=system_color
self.contents.draw_text(x,y,320,self.contents.font.size,"Equipment Skills")
y+=self.contents.font.size+2
self.contents.font.color=normal_color
if @equip_type==0 and @equip_id!=0 and $game_party.
learning_db[$data_weapons[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_weapons[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
end
end
if @equip_type>0 and @equip_id!=0 and $game_party.
learning_db[$data_armors[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_armors[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
end
end
end
I tried to fill that in (2.2) but then this window doesn't show up in the Equipment Menu. Could you edit this so it's compatible with 2.2?
ty Zare
FFIX Skills Learning System aka Equipment Skills, NEW!!! v2.2 (6-1-2010) - Charlie Fleed - 01-07-2010
The new version for that patch should be like this:
Code:
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
@empty=true
x = 0
y = 0
if $scene.is_a?(Scene_Shop)
self.contents.font.color=system_color
self.contents.draw_text(x,y,50,32,"Actor:")
draw_actor_name(@actor, x+54, y)
y+=24
end
self.contents.font.color=system_color
self.contents.draw_text(x,y,320,self.contents.font.size,"Equip Skills and Learnings")
y+=self.contents.font.size+2
self.contents.font.color=normal_color
if @equip_type==0 and @equip_id!=0 and $game_party.
learning_db[$data_weapons[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_weapons[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
@empty=false
end
end
if @equip_type>0 and @equip_id!=0 and $game_party.
learning_db[$data_armors[@equip_id].name]!=nil
for learning in $game_party.
learning_db[$data_armors[@equip_id].name].learnings
skill=$data_skills[learning.skill_id]
rect = Rect.new(x, y, 24, 24)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
bitmap = RPG::Cache.icon(skill.icon_name)
self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24), opacity)
if @actor!=nil
self.contents.font.color=(@actor.can_learn?(learning.skill_id)) ? normal_color : disabled_color
end
self.contents.draw_text(x + 28, y, 172, self.contents.font.size, "L:"+skill.name, 0)
s=""
if @actor!=nil and (@actor.skill_learn?(skill.id) or learning.level==0)
s=s+"A"
end
if @actor!=nil and @actor.experience_points_skills[skill.id] >= learning.level
s=s+" M" unless learning.level==0
end
#self.contents.draw_text(x + 200, y, 48, self.contents.font.size, skill.sp_cost.to_s, 2)
self.contents.draw_text(x + 200, y, 48, self.contents.font.size, s, 2)
y+=24
@empty=false
end
end
end