Blue Mage Script help - chameleon1333 - 08-20-2013
So i'm trying to create a blue mage character. I've got a script for that allows me to choose the id numbers for blue magic and choose the ids of the sctors that are blue mages. The blue mage will learn a skill when attacked only. To get around the issue of enemy's not using helping skills on the mage (such as white wind from final fantasy) i have a script for a skill that controls the enemy (actually they just become an ally and can't be controlled) and they will use the healling skill, but the Blue Mage wont learn it even though it's working on them. Looking at the blue mage script it looks like it only set up to learn on a "hit", but i don't know how to add it for other skills like healling or status changing ones. Here the script im using
Code: =begin
Fomar0153's Blue Mages Script
Changle Log
----------------------
1.0 -> 1.1 : Added notification when learning a new Skill
----------------------
Known bugs
----------------------
None
=end
class Game_Actor < Game_Battler
# Edit to include the actor (character) id
BlueMages = [1]
# Edit to include all the skill ids of the skills you want your
# blue mages to learn
BlueMagic = [23, 26]
#--------------------------------------------------------------------------
# ● Aliased make_damage_value
#--------------------------------------------------------------------------
alias bluemagic_make_damage_value make_damage_value
def make_damage_value(user, item)
bluemagic_make_damage_value(user, item)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
end
class Scene_Battle < Scene_Base
#--------------------------------------------------------------------------
# ● New method add_text
#--------------------------------------------------------------------------
def add_text(text)
@log_window.add_text(text)
end
end
RE: Blue Mage Script help - chameleon1333 - 08-24-2013
Anyone? Echo.... echo........ echo........ echo..........
RE: Blue Mage Script help - Ahzoh - 08-24-2013
you should ask DerVVulfmann bout this maybe?
RE: Blue Mage Script help - chameleon1333 - 08-24-2013
I've figured it out on my own. adding the following gave me what i was looking for:
Code: #--------------------------------------------------------------------------
# ● Aliased item_effect_recover_hp
#--------------------------------------------------------------------------
alias bluemagic_item_effect_recover_hp item_effect_recover_hp
def item_effect_recover_hp(user, item, effect)
bluemagic_item_effect_recover_hp(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_recover_mp
#--------------------------------------------------------------------------
alias bluemagic_item_effect_recover_mp item_effect_recover_mp
def item_effect_recover_mp(user, item, effect)
bluemagic_item_effect_recover_mp(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_gain_tp
#--------------------------------------------------------------------------
alias bluemagic_item_effect_gain_tp item_effect_gain_tp
def item_effect_gain_tp(user, item, effect)
bluemagic_item_effect_gain_tp(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_add_state
#--------------------------------------------------------------------------
alias bluemagic_item_effect_add_state item_effect_add_state
def item_effect_add_state(user, item, effect)
bluemagic_item_effect_add_state(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_remove_state
#--------------------------------------------------------------------------
alias bluemagic_item_effect_remove_state item_effect_remove_state
def item_effect_remove_state(user, item, effect)
bluemagic_item_effect_remove_state(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_add_buff
#--------------------------------------------------------------------------
alias bluemagic_item_effect_add_buff item_effect_add_buff
def item_effect_add_buff(user, item, effect)
bluemagic_item_effect_add_buff(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
#--------------------------------------------------------------------------
# ● Aliased item_effect_add_debuff
#--------------------------------------------------------------------------
alias bluemagic_item_effect_add_debuff item_effect_add_debuff
def item_effect_add_debuff(user, item, effect)
bluemagic_item_effect_add_debuff(user, item, effect)
if @result.hit? and item.class == RPG::Skill
if BlueMages.include?(@actor_id) and BlueMagic.include?(item.id)
i = @skills.size
learn_skill(item.id)
if !(i == @skills.size)
SceneManager.scene.add_text(actor.name + " learns " + item.name + ".")
end
end
end
end
RE: Blue Mage Script help - DerVVulfman - 08-24-2013
Ahhh... we learn by doing. And you got to it before anyone here had a CHANCE to help. Nice.
RE: Blue Mage Script help - Ahzoh - 08-24-2013
what makes a blue wizard different than any other?
RE: Blue Mage Script help - DerVVulfman - 08-24-2013
They learn the skills they're attacked by. Dunno why they call it Blue Mage.... just sum it up as a Skill Learning script.
RE: Blue Mage Script help - Ahzoh - 08-25-2013
it should be called move-mimic, and this sound pretty cool then.
RE: Blue Mage Script help - chameleon1333 - 08-25-2013
http://finalfantasy.wikia.com/wiki/Blue_Mage
|