查看: 3161|回复: 2

[已经解决] 职业解锁系统的问题

[复制链接]
梦石
0
星屑
9292
在线时间
2504 小时
注册时间
2011-5-20
回帖
14521

开拓者

发表于 2012-10-22 13:53:04 | 显示全部楼层 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有账号?注册会员

×
先放上脚本···
  1. #==============================================================================
  2. #
  3. # ▼ Yanfly Engine Ace - Class System v1.08
  4. # -- Last Updated: 2012.01.08
  5. # -- Level: Normal, Hard
  6. # -- Requires: n/a
  7. #
  8. #==============================================================================

  9. $imported = {} if $imported.nil?
  10. $imported["YEA-ClassSystem"] = true
  11. =begin
  12. #================================================= =============================
  13. #▼更新
  14. #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - =- = - = - = - = - = - = - = - = - = - = - = - = - = - =
  15. 2012年1月8日 - 兼容性更新:学习技能引擎
  16. 2012.01.05 - 修正:设备不再被复制。
  17. 2012.01.04 - 更新:Autobattle将不再使用技能无法使用
  18. #中,类的具体实施者。
  19. 2012年1月2日 - 效率更新。
  20. 2011.12.26 - 添加自定义命令的功能。
  21. 2011.12.23 - 兼容性更新:类具体细节。
  22. #2011.12.22 - 兼容性更新:王牌菜单引擎。
  23. 2011.12.20 - 兼容性更新:类解锁级。
  24. #2011.12.19 - 开始脚本和成品。
  25. #
  26. #================================================= =============================
  27. #▼公司简介
  28. #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - =- = - = - = - = - = - = - = - = - = - = - = - = - = - =
  29. #这个脚本为您的播放器添加了自由改变类
  30. 演员外的战斗从菜单中。当改变类,这个脚本
  31. #为开发者提供的选项选择是否有类
  32. #自己的水平(导致演员的水平,以重置回类的
  33. #水平),或维持目前的水平。除了提供的能力
  34. #更改类的一个子类,装备也是可行的,和力学
  35. #具有该脚本内的一个子类也可以被定义。
  36. #
  37. #================================================= =============================
  38. #▼说明
  39. #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - =- = - = - = - = - = - = - = - = - = - = - = - = - = - =
  40. #如果要安装这个脚本,脚本编辑器打开你的复制/粘贴此脚本
  41. #▼材料/素材,但高于▼主要的开放式插槽下面。记住要保存。
  42. #
  43. #------------------------------------------------- ----------------------------
  44. #的演员Notetags - 这些notetags中的的演员notebox数据库中的。
  45. #------------------------------------------------- ----------------------------
  46. #<unlocked classes: X>
  47. #<unlocked classes: x, X>
  48. #这将设置默认的类作为解锁的演员。这不
  49. 覆盖默认的类模块中的解锁,而是,再加上
  50. #解锁的类的数量。
  51. #
  52. #------------------------------------------------- ----------------------------
  53. 在数据库中的类notebox#类Notetags的 - 这些notetags去。
  54. #------------------------------------------------- ----------------------------
  55. #<icon: X>
  56. #设置图标表示类为x。
  57. #
  58. #<说明说明>
  59. #字符串
  60. #字符串
  61. #</帮助说明>
  62. #设置的文本用于帮助窗口类中的场景。多线
  63. #notebox将被串在一起。使用一个换行符。
  64. #
  65. #------------------------------------------------- ----------------------------
  66. #脚本调用 - 使用脚本调用这些命令。
  67. #------------------------------------------------- ----------------------------
  68. #$ game_actors [X]。unlock_class(Y)
  69. #这使演员x的解锁等级Y,使其可用于切换中
  70. #在类的场景。
  71. #
  72. #$ game_actors [X]。remove_class(Y)
  73. #这将导致演员能够切换到X删除类y。
  74. ,如果目前的演员是Y类,这个类不会被删除。如果
  75. #演员的子类是y,则子类将束手无策。
  76. #
  77. #================================================= =============================
  78. #▼兼容性
  79. #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - =- = - = - = - = - = - = - = - = - = - = - = - = - = - =
  80. #这个脚本是为RPG制作VX王牌的严格。这是极不可能的
  81. #将运行与的RPG制造商VX没有调整。
  82. #
  83. =end

  84. module YEA
  85.   module CLASS_SYSTEM
  86. =begin   
  87.     # - 通用类设置 -
  88.     #这是整个脚本的一般设置。他们控制
  89.     #各项规章制度,这个脚本经历。这些设置
  90.     #也将决定一个球员的一个子类可以做什么。
  91. =end
  92.     CLASS_MENU_TEXT = "职业"  # 在主菜单中显示的文本.
  93.     MAINTAIN_LEVELS = false    # 保持的所有类。默认值:false.
  94.     DEFAULT_UNLOCKS = [ ]   # 默认情况下,类解锁。
  95. =begin
  96. #显示之间的主类和子类的时候写的一个
  97.     #窗口将出现等。
  98. =end
  99.     SUBCLASS_TEXT = "%s/%s"
  100. =begin   
  101. #这对于一个演员如果调整的统计继承一个演员都有一个
  102.     #子类装备。如果您希望禁用这个选项,设置速率为0.0。
  103. =end
  104.     SUBCLASS_STAT_RATE = 0.20
  105.    
  106.     # 这增加了子类技能类型可使用的技能类型.
  107.     SUBCLASS_SKILL_TYPES = true
  108.    
  109.     # 这增加了子类武器装备的武器类型.
  110.     SUBCLASS_WEAPON_TYPES = true
  111.    
  112.     # 这增加了子类防具装备的武器类型.
  113.     SUBCLASS_ARMOUR_TYPES = true
  114. =begin
  115.     # - 类场景“命令 -
  116.     这些设置调整类的一幕出现了。在这里,你可以调整
  117.     #命令列表和命令,在出现的项目。这些大多是
  118.     #可视化设置。调整您认为合适的。
  119.     #:命令说明
  120.     #:初级允许玩家改变主类。
  121.     #:子类,允许玩家改变的子类。
  122.     #
  123.     #:learn_skill。需要YEA - 学习技能引擎
  124.     #
  125. =end
  126.     COMMANDS =[ # 在该菜单项目的顺序显示.
  127.     # [ :command,   "Display"],
  128.       [ :primary,   "主要职业"],
  129.       [:subclass,  "次要职业"],
  130.       [:learn_skill, "学习技能"],
  131.     # [ :custom1,   "Custom1"],
  132.     # [ :custom2,   "Custom2"],
  133.     ] # 不要删除此。
  134. =begin   
  135.     # - 状态类的命令 -
  136.     #-------------------------------------
  137.     #对于那些使用脚本,可能会产生独特的效果
  138.     #类的菜单,使用这个散列管理类的自定义命令
  139.     #命令窗口。您可以禁用特定的命令或阻止他们
  140.     #通过交换机出现。如果您不希望将它们绑定到一个开关,
  141.     #设置适当的开关为0,它有没有影响。
  142. =end
  143.     CUSTOM_CLASS_COMMANDS ={
  144.     # :command => [EnableSwitch, ShowSwitch, Handler Method,
  145.       :custom1 => [           0,          0, :command_name1],
  146.       :custom2 => [           0,          0, :command_name2],
  147.     } # Do not remove this.
  148.    
  149.     # These settings adjust the colour displays for classes.
  150.     CURRENT_CLASS_COLOUR = 17     # "Window" colour used for current class.
  151.     SUBCLASS_COLOUR      = 4      # "Window" colour used for subclass.
  152.    
  153.     # This adjusts the display for class levels if MAINTAIN_LEVELS is false.
  154.     CLASS_LEVEL     = "LV%s"      # Text display for level.
  155.     LEVEL_FONT_SIZE = 16          # Font size used for level.
  156.    
  157.     # This array sets the order of how classes are ordered in the class listing
  158.     # window. Any class ID's unlisted will not be shown.
  159.     CLASS_ORDER = [41..999, 1..40]
  160.    
  161.     # This adjusts the font size for the Parameters window.
  162.     PARAM_FONT_SIZE = 20
  163.    
  164.     #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
  165.     # - Switch Settings -
  166.     #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
  167.     # These are the switches that govern whether or not certain menu items will
  168.     # appear and/or will be enabled. By binding them to a Switch, you can just
  169.     # set the Switch ON/OFF to show/hide or enable/disable a menu command. If
  170.     # you do not wish to use this feature, set these commands to 0.
  171.     #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
  172.     SWITCH_SHOW_CLASS      = 0    # Switch that shows Class in Main Menu.
  173.     SWITCH_ENABLE_CLASS    = 0    # Switch that enables Class in Main Menu.
  174.     SWITCH_SHOW_PRIMARY    = 0    # Switch that shows Subclass in Class Menu.
  175.     SWITCH_ENABLE_PRIMARY  = 0    # Switch that enables Subclass in Class Menu.
  176.     SWITCH_SHOW_SUBCLASS   = 0    # Switch that shows Subclass in Class Menu.
  177.     SWITCH_ENABLE_SUBCLASS = 0    # Switch that enables Subclass in Class Menu.
  178.    
  179.   end # CLASS_SYSTEM
  180. end # YEA

  181. #==============================================================================
  182. # ▼ Editting anything past this point may potentially result in causing
  183. # computer damage, incontinence, explosion of user's head, coma, death, and/or
  184. # halitosis so edit at your own risk.
  185. #==============================================================================

  186. module YEA
  187.   module CLASS_SYSTEM
  188.     module_function
  189.     #--------------------------------------------------------------------------
  190.     # convert_integer_array
  191.     #--------------------------------------------------------------------------
  192.     def convert_integer_array(array)
  193.       result = []
  194.       array.each { |i|
  195.         case i
  196.         when Range; result |= i.to_a
  197.         when Integer; result |= [i]
  198.         end }
  199.       return result
  200.     end
  201.     #--------------------------------------------------------------------------
  202.     # converted_contants
  203.     #--------------------------------------------------------------------------
  204.     DEFAULT_UNLOCKS = convert_integer_array(DEFAULT_UNLOCKS)
  205.     CLASS_ORDER = convert_integer_array(CLASS_ORDER)
  206.   end # CLASS_SYSTEM
  207.   module REGEXP
  208.   module ACTOR
  209.    
  210.     UNLOCKED_CLASSES =
  211.       /<(?:UNLOCKED_CLASSES|unlocked classes):[ ]*(\d+(?:\s*,\s*\d+)*)>/i
  212.    
  213.   end # ACTOR
  214.   module CLASS
  215.    
  216.     ICON_INDEX = /<(?:ICON_INDEX|icon index|icon):[ ](\d+)>/i
  217.     HELP_DESCRIPTION_ON  = /<(?:HELP_DESCRIPTION|help description)>/i
  218.     HELP_DESCRIPTION_OFF = /<\/(?:HELP_DESCRIPTION|help description)>/i
  219.    
  220.   end # CLASS
  221.   end # REGEXP
  222. end # YEA

  223. #==============================================================================
  224. # ■ Switch
  225. #==============================================================================

  226. module Switch
  227.   
  228.   #--------------------------------------------------------------------------
  229.   # self.class_show
  230.   #--------------------------------------------------------------------------
  231.   def self.class_show
  232.     return true if YEA::CLASS_SYSTEM::SWITCH_SHOW_CLASS <= 0
  233.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_SHOW_CLASS]
  234.   end
  235.   
  236.   #--------------------------------------------------------------------------
  237.   # self.class_enable
  238.   #--------------------------------------------------------------------------
  239.   def self.class_enable
  240.     return true if YEA::CLASS_SYSTEM::SWITCH_ENABLE_CLASS <= 0
  241.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_ENABLE_CLASS]
  242.   end
  243.   
  244.   #--------------------------------------------------------------------------
  245.   # self.primary_show
  246.   #--------------------------------------------------------------------------
  247.   def self.primary_show
  248.     return true if YEA::CLASS_SYSTEM::SWITCH_SHOW_PRIMARY <= 0
  249.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_SHOW_PRIMARY]
  250.   end
  251.   
  252.   #--------------------------------------------------------------------------
  253.   # self.primary_enable
  254.   #--------------------------------------------------------------------------
  255.   def self.primary_enable
  256.     return true if YEA::CLASS_SYSTEM::SWITCH_ENABLE_PRIMARY <= 0
  257.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_ENABLE_PRIMARY]
  258.   end
  259.   
  260.   #--------------------------------------------------------------------------
  261.   # self.subclass_show
  262.   #--------------------------------------------------------------------------
  263.   def self.subclass_show
  264.     return true if YEA::CLASS_SYSTEM::SWITCH_SHOW_SUBCLASS <= 0
  265.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_SHOW_SUBCLASS]
  266.   end
  267.   
  268.   #--------------------------------------------------------------------------
  269.   # self.subclass_enable
  270.   #--------------------------------------------------------------------------
  271.   def self.subclass_enable
  272.     return true if YEA::CLASS_SYSTEM::SWITCH_ENABLE_SUBCLASS <= 0
  273.     return $game_switches[YEA::CLASS_SYSTEM::SWITCH_ENABLE_SUBCLASS]
  274.   end
  275.    
  276. end # Switch

  277. #==============================================================================
  278. # ■ Numeric
  279. #==============================================================================

  280. class Numeric
  281.   
  282.   #--------------------------------------------------------------------------
  283.   # new method: group_digits
  284.   #--------------------------------------------------------------------------
  285.   unless $imported["YEA-CoreEngine"]
  286.   def group; return self.to_s; end
  287.   end # $imported["YEA-CoreEngine"]
  288.    
  289. end # Numeric

  290. #==============================================================================
  291. # ■ DataManager
  292. #==============================================================================

  293. module DataManager
  294.   
  295.   #--------------------------------------------------------------------------
  296.   # alias method: load_database
  297.   #--------------------------------------------------------------------------
  298.   class <<self; alias load_database_cs load_database; end
  299.   def self.load_database
  300.     load_database_cs
  301.     load_notetags_cs
  302.   end
  303.   
  304.   #--------------------------------------------------------------------------
  305.   # new method: load_notetags_cs
  306.   #--------------------------------------------------------------------------
  307.   def self.load_notetags_cs
  308.     groups = [$data_actors, $data_classes]
  309.     for group in groups
  310.       for obj in group
  311.         next if obj.nil?
  312.         obj.load_notetags_cs
  313.       end
  314.     end
  315.   end
  316.   
  317. end # DataManager

  318. #==============================================================================
  319. # ■ RPG::Actor
  320. #==============================================================================

  321. class RPG::Actor < RPG::BaseItem
  322.   
  323.   #--------------------------------------------------------------------------
  324.   # public instance variables
  325.   #--------------------------------------------------------------------------
  326.   attr_accessor :unlocked_classes
  327.   
  328.   #--------------------------------------------------------------------------
  329.   # common cache: load_notetags_cs
  330.   #--------------------------------------------------------------------------
  331.   def load_notetags_cs
  332.     @unlocked_classes = []
  333.     #---
  334.     self.note.split(/[\r\n]+/).each { |line|
  335.       case line
  336.       #---
  337.       when YEA::REGEXP::ACTOR::UNLOCKED_CLASSES
  338.         $1.scan(/\d+/).each { |num|
  339.         @unlocked_classes.push(num.to_i) if num.to_i > 0 }
  340.       #---
  341.       end
  342.     } # self.note.split
  343.     #---
  344.   end
  345.   
  346. end # RPG::Actor

  347. #==============================================================================
  348. # ■ RPG::Class
  349. #==============================================================================

  350. class RPG::Class < RPG::BaseItem
  351.   
  352.   #--------------------------------------------------------------------------
  353.   # public instance variables
  354.   #--------------------------------------------------------------------------
  355.   attr_accessor :icon_index
  356.   
  357.   #--------------------------------------------------------------------------
  358.   # common cache: load_notetags_cs
  359.   #--------------------------------------------------------------------------
  360.   def load_notetags_cs
  361.     @icon_index = 0
  362.     @help_description_on = false
  363.     #---
  364.     self.note.split(/[\r\n]+/).each { |line|
  365.       case line
  366.       #---
  367.       when YEA::REGEXP::CLASS::ICON_INDEX
  368.         @icon_index = $1.to_i
  369.       #---
  370.       when YEA::REGEXP::CLASS::HELP_DESCRIPTION_ON
  371.         @help_description_on = true
  372.       when YEA::REGEXP::CLASS::HELP_DESCRIPTION_OFF
  373.         @help_description_on = false
  374.       #---
  375.       else
  376.         @description += line.to_s if @help_description_on
  377.       end
  378.     } # self.note.split
  379.     #---
  380.     @description.gsub!(/[|]/i) { "\n" }
  381.   end
  382.   
  383. end # RPG::Class

  384. #==============================================================================
  385. # ■ Game_Temp
  386. #==============================================================================

  387. class Game_Temp
  388.   
  389.   #--------------------------------------------------------------------------
  390.   # public instance variables
  391.   #--------------------------------------------------------------------------
  392.   attr_accessor :scene_class_index
  393.   attr_accessor :scene_class_oy
  394.   
  395. end # Game_Temp

  396. #==============================================================================
  397. # ■ Game_Action
  398. #==============================================================================

  399. class Game_Action
  400.   
  401.   #--------------------------------------------------------------------------
  402.   # alias method: valid?
  403.   #--------------------------------------------------------------------------
  404.   alias game_action_valid_cs valid?
  405.   def valid?
  406.     return false if check_auto_battle_class
  407.     return game_action_valid_cs
  408.   end
  409.   
  410.   #--------------------------------------------------------------------------
  411.   # new method: check_auto_battle_class
  412.   #--------------------------------------------------------------------------
  413.   def check_auto_battle_class
  414.     return false unless subject.actor?
  415.     return false unless subject.auto_battle?
  416.     return false if item.nil?
  417.     return false if subject.added_skill_types.include?(item.stype_id)
  418.     return false if item.id == subject.attack_skill_id
  419.     return true
  420.   end
  421.   
  422. end # Game_Action

  423. #==============================================================================
  424. # ■ Game_BattlerBase
  425. #==============================================================================

  426. class Game_BattlerBase
  427.   
  428.   #--------------------------------------------------------------------------
  429.   # public instance variables
  430.   #--------------------------------------------------------------------------
  431.   attr_accessor :temp_flag
  432.   
  433.   #--------------------------------------------------------------------------
  434.   # alias method: added_skill_types
  435.   #--------------------------------------------------------------------------
  436.   alias game_battlerbase_added_skill_types_cs added_skill_types
  437.   def added_skill_types
  438.     result = game_battlerbase_added_skill_types_cs
  439.     result |= subclass_skill_types
  440.     return result
  441.   end
  442.   
  443.   #--------------------------------------------------------------------------
  444.   # new method: subclass_skill_types
  445.   #--------------------------------------------------------------------------
  446.   def subclass_skill_types; return []; end
  447.   
  448.   #--------------------------------------------------------------------------
  449.   # alias method: equip_wtype_ok?
  450.   #--------------------------------------------------------------------------
  451.   alias game_battlerbase_equip_wtype_ok_cs equip_wtype_ok?
  452.   def equip_wtype_ok?(wtype_id)
  453.     return true if subclass_equip_wtype?(wtype_id)
  454.     return game_battlerbase_equip_wtype_ok_cs(wtype_id)
  455.   end
  456.   
  457.   #--------------------------------------------------------------------------
  458.   # new method: subclass_equip_wtype?
  459.   #--------------------------------------------------------------------------
  460.   def subclass_equip_wtype?(wtype_id); return false; end
  461.   
  462.   #--------------------------------------------------------------------------
  463.   # alias method: equip_atype_ok?
  464.   #--------------------------------------------------------------------------
  465.   alias game_battlerbase_equip_atype_ok_cs equip_atype_ok?
  466.   def equip_atype_ok?(atype_id)
  467.     return true if subclass_equip_atype?(atype_id)
  468.     return game_battlerbase_equip_atype_ok_cs(atype_id)
  469.   end
  470.   
  471.   #--------------------------------------------------------------------------
  472.   # new method: subclass_equip_atype?
  473.   #--------------------------------------------------------------------------
  474.   def subclass_equip_atype?(atype_id); return false; end
  475.   
  476. end # Game_BattlerBase

  477. #==============================================================================
  478. # ■ Game_Actor
  479. #==============================================================================

  480. class Game_Actor < Game_Battler
  481.   
  482.   #--------------------------------------------------------------------------
  483.   # alias method: setup
  484.   #--------------------------------------------------------------------------
  485.   alias game_actor_setup_cs setup
  486.   def setup(actor_id)
  487.     game_actor_setup_cs(actor_id)
  488.     init_unlocked_classes
  489.     init_subclass
  490.   end
  491.   
  492.   #--------------------------------------------------------------------------
  493.   # new method: init_unlocked_classes
  494.   #--------------------------------------------------------------------------
  495.   def init_unlocked_classes
  496.     @unlocked_classes = actor.unlocked_classes.clone
  497.     @unlocked_classes.push(@class_id) if !@unlocked_classes.include?(@class_id)
  498.     @unlocked_classes.sort!
  499.   end
  500.   
  501.   #--------------------------------------------------------------------------
  502.   # new method: init_subclass
  503.   #--------------------------------------------------------------------------
  504.   def init_subclass
  505.     @subclass_id = 0
  506.   end
  507.   
  508.   #--------------------------------------------------------------------------
  509.   # new method: unlocked_classes
  510.   #--------------------------------------------------------------------------
  511.   def unlocked_classes
  512.     init_unlocked_classes if @unlocked_classes.nil?
  513.     return @unlocked_classes
  514.   end
  515.   
  516.   #--------------------------------------------------------------------------
  517.   # new method: unlock_class
  518.   #--------------------------------------------------------------------------
  519.   def unlock_class(class_id)
  520.     init_unlocked_classes if @unlocked_classes.nil?
  521.     return if @unlocked_classes.include?(class_id)
  522.     @unlocked_classes.push(class_id)
  523.     learn_class_skills(class_id)
  524.   end
  525.   
  526.   #--------------------------------------------------------------------------
  527.   # new method: remove_class
  528.   #--------------------------------------------------------------------------
  529.   def remove_class(class_id)
  530.     init_unlocked_classes if @unlocked_classes.nil?
  531.     return if class_id == @class_id
  532.     @unlocked_classes.delete(class_id)
  533.     @subclass_id = 0 if class_id == @subclass_id
  534.     refresh
  535.   end
  536.   
  537.   #--------------------------------------------------------------------------
  538.   # new method: subclass
  539.   #--------------------------------------------------------------------------
  540.   def subclass
  541.     init_subclass if @subclass_id.nil?
  542.     return $data_classes[@subclass_id]
  543.   end
  544.   
  545.   #--------------------------------------------------------------------------
  546.   # alias method: change_class
  547.   #--------------------------------------------------------------------------
  548.   alias game_actor_change_class_cs change_class
  549.   def change_class(class_id, keep_exp = false)
  550.     @subclass_id = 0 if @subclass_id == class_id
  551.     game_actor_change_class_cs(class_id, keep_exp)
  552.     learn_class_skills(class_id)
  553.     unlock_class(class_id)
  554.   end
  555.   
  556.   #--------------------------------------------------------------------------
  557.   # new method: learn_class_skills
  558.   #--------------------------------------------------------------------------
  559.   def learn_class_skills(class_id)
  560.     return if class_id <= 0
  561.     return if $data_classes[class_id].nil?
  562.     $data_classes[class_id].learnings.each do |learning|
  563.       learn_skill(learning.skill_id) if learning.level == class_level(class_id)
  564.     end
  565.   end
  566.   
  567.   #--------------------------------------------------------------------------
  568.   # new method: change_subclass
  569.   #--------------------------------------------------------------------------
  570.   def change_subclass(class_id)
  571.     return if class_id == @class_id
  572.     unlock_class(class_id)
  573.     @subclass_id = @subclass_id == class_id ? 0 : class_id
  574.     learn_class_skills(@subclass_id)
  575.     refresh
  576.   end
  577.   
  578.   #--------------------------------------------------------------------------
  579.   # new method: class_level
  580.   #--------------------------------------------------------------------------
  581.   def class_level(class_id)
  582.     return @level if YEA::CLASS_SYSTEM::MAINTAIN_LEVELS
  583.     temp_class = $data_classes[class_id]
  584.     @exp[class_id] = 0 if @exp[class_id].nil?
  585.     n = 1
  586.     loop do
  587.       break if temp_class.exp_for_level(n+1) > @exp[class_id]
  588.       n += 1
  589.     end
  590.     return n
  591.   end
  592.   
  593.   #--------------------------------------------------------------------------
  594.   # new method: subclass_level
  595.   #--------------------------------------------------------------------------
  596.   def subclass_level
  597.     return 0 if @subclass_id == 0
  598.     return @level if YEA::CLASS_SYSTEM::MAINTAIN_LEVELS
  599.     return class_level(@subclass_id)
  600.   end
  601.   
  602.   #--------------------------------------------------------------------------
  603.   # alias method: param_base
  604.   #--------------------------------------------------------------------------
  605.   alias game_actor_param_base_cs param_base
  606.   def param_base(param_id)
  607.     result = game_actor_param_base_cs(param_id)
  608.     unless subclass.nil?
  609.       subclass_rate = YEA::CLASS_SYSTEM::SUBCLASS_STAT_RATE
  610.       slevel = subclass_level
  611.       result += subclass.params[param_id, slevel] * subclass_rate
  612.     end
  613.     return result.to_i
  614.   end
  615.   
  616.   #--------------------------------------------------------------------------
  617.   # new method: subclass_skill_types
  618.   #--------------------------------------------------------------------------
  619.   def subclass_skill_types
  620.     return [] unless YEA::CLASS_SYSTEM::SUBCLASS_SKILL_TYPES
  621.     return [] if subclass.nil?
  622.     array = []
  623.     for feature in subclass.features
  624.       next unless feature.code == FEATURE_STYPE_ADD
  625.       next if features_set(FEATURE_STYPE_ADD).include?(feature.data_id)
  626.       array.push(feature.data_id)
  627.     end
  628.     return array
  629.   end
  630.   
  631.   #--------------------------------------------------------------------------
  632.   # new method: subclass_equip_wtype?
  633.   #--------------------------------------------------------------------------
  634.   def subclass_equip_wtype?(wtype_id)
  635.     return false unless YEA::CLASS_SYSTEM::SUBCLASS_WEAPON_TYPES
  636.     return false if subclass.nil?
  637.     for feature in subclass.features
  638.       next unless feature.code == FEATURE_EQUIP_WTYPE
  639.       return true if wtype_id == feature.data_id
  640.     end
  641.     return super
  642.   end
  643.   
  644.   #--------------------------------------------------------------------------
  645.   # new method: subclass_equip_atype?
  646.   #--------------------------------------------------------------------------
  647.   def subclass_equip_atype?(atype_id)
  648.     return false unless YEA::CLASS_SYSTEM::SUBCLASS_ARMOUR_TYPES
  649.     return false if subclass.nil?
  650.     for feature in subclass.features
  651.       next unless feature.code == FEATURE_EQUIP_ATYPE
  652.       return true if atype_id == feature.data_id
  653.     end
  654.     return super
  655.   end
  656.   
  657.   #--------------------------------------------------------------------------
  658.   # alias method: release_unequippable_items
  659.   #--------------------------------------------------------------------------
  660.   alias game_actor_release_unequippable_items_cs release_unequippable_items
  661.   def release_unequippable_items(item_gain = true)
  662.     item_gain = false if @temp_flag
  663.     game_actor_release_unequippable_items_cs(item_gain)
  664.   end
  665.   
  666. end # Game_Actor

  667. #==============================================================================
  668. # ■ Game_Interpreter
  669. #==============================================================================

  670. class Game_Interpreter
  671.   
  672.   #--------------------------------------------------------------------------
  673.   # overwrite method: command_321
  674.   #--------------------------------------------------------------------------
  675.   def command_321
  676.     actor = $game_actors[@params[0]]
  677.     if actor && $data_classes[@params[1]]
  678.       maintain = YEA::CLASS_SYSTEM::MAINTAIN_LEVELS
  679.       actor.change_class(@params[1], maintain)
  680.     end
  681.   end
  682.   
  683. end # Game_Interpreter

  684. #==============================================================================
  685. # ■ Window_Base
  686. #==============================================================================

  687. class Window_Base < Window
  688.   
  689.   #--------------------------------------------------------------------------
  690.   # overwrite method: draw_actor_class
  691.   #--------------------------------------------------------------------------
  692.   def draw_actor_class(actor, x, y, width = 112)
  693.     change_color(normal_color)
  694.     if actor.subclass.nil?
  695.       text = actor.class.name
  696.     else
  697.       fmt = YEA::CLASS_SYSTEM::SUBCLASS_TEXT
  698.       text = sprintf(fmt, actor.class.name, actor.subclass.name)
  699.     end
  700.     draw_text(x, y, width, line_height, text)
  701.   end
  702.   
  703. end # Window_Base

  704. #==============================================================================
  705. # ■ Window_MenuCommand
  706. #==============================================================================

  707. class Window_MenuCommand < Window_Command
  708.   
  709.   #--------------------------------------------------------------------------
  710.   # alias method: add_formation_command
  711.   #--------------------------------------------------------------------------
  712.   alias window_menucommand_add_formation_command_cs add_formation_command
  713.   def add_formation_command
  714.     add_class_command unless $imported["YEA-AceMenuEngine"]
  715.     window_menucommand_add_formation_command_cs
  716.   end
  717.   
  718.   #--------------------------------------------------------------------------
  719.   # new method: add_class_command
  720.   #--------------------------------------------------------------------------
  721.   def add_class_command
  722.     return unless Switch.class_show
  723.     text = YEA::CLASS_SYSTEM::CLASS_MENU_TEXT
  724.     add_command(text, :class, Switch.class_enable)
  725.   end
  726.   
  727. end # Window_MenuCommand

  728. #==============================================================================
  729. # ■ Window_ClassCommand
  730. #==============================================================================

  731. class Window_ClassCommand < Window_Command
  732.   
  733.   #--------------------------------------------------------------------------
  734.   # initialize
  735.   #--------------------------------------------------------------------------
  736.   def initialize(x, y)
  737.     super(x, y)
  738.     @actor = nil
  739.   end
  740.   
  741.   #--------------------------------------------------------------------------
  742.   # ● ウィンドウ幅の取得
  743.   #--------------------------------------------------------------------------
  744.   def window_width; return 160; end
  745.   
  746.   #--------------------------------------------------------------------------
  747.   # actor=
  748.   #--------------------------------------------------------------------------
  749.   def actor=(actor)
  750.     return if @actor == actor
  751.     @actor = actor
  752.     refresh
  753.   end
  754.   
  755.   #--------------------------------------------------------------------------
  756.   # item_window=
  757.   #--------------------------------------------------------------------------
  758.   def item_window=(window)
  759.     @item_window = window
  760.   end
  761.   
  762.   #--------------------------------------------------------------------------
  763.   # visible_line_number
  764.   #--------------------------------------------------------------------------
  765.   def visible_line_number; return 4; end
  766.   
  767.   #--------------------------------------------------------------------------
  768.   # make_command_list
  769.   #--------------------------------------------------------------------------
  770.   def make_command_list
  771.     return if @actor.nil?
  772.     for command in YEA::CLASS_SYSTEM::COMMANDS
  773.       case command[0]
  774.       when :primary
  775.         next unless Switch.primary_show
  776.         add_command(command[1], command[0], Switch.primary_enable)
  777.       when :subclass
  778.         next unless Switch.subclass_show
  779.         add_command(command[1], command[0], Switch.subclass_enable)
  780.       when :learn_skill
  781.         next unless $imported["YEA-LearnSkillEngine"]
  782.         add_learn_skill_command
  783.       else
  784.         process_custom_command(command)
  785.       end
  786.     end
  787.     if !$game_temp.scene_class_index.nil?
  788.       select($game_temp.scene_class_index)
  789.       self.oy = $game_temp.scene_class_oy
  790.     end
  791.     $game_temp.scene_class_index = nil
  792.     $game_temp.scene_class_oy = nil
  793.   end
  794.   
  795.   #--------------------------------------------------------------------------
  796.   # process_ok
  797.   #--------------------------------------------------------------------------
  798.   def process_ok
  799.     $game_temp.scene_class_index = index
  800.     $game_temp.scene_class_oy = self.oy
  801.     super
  802.   end
  803.   
  804.   #--------------------------------------------------------------------------
  805.   # process_custom_command
  806.   #--------------------------------------------------------------------------
  807.   def process_custom_command(command)
  808.     return unless YEA::CLASS_SYSTEM::CUSTOM_CLASS_COMMANDS.include?(command[0])
  809.     show = YEA::CLASS_SYSTEM::CUSTOM_CLASS_COMMANDS[command[0]][1]
  810.     continue = show <= 0 ? true : $game_switches[show]
  811.     return unless continue
  812.     text = command[1]
  813.     switch = YEA::CLASS_SYSTEM::CUSTOM_CLASS_COMMANDS[command[0]][0]
  814.     enabled = switch <= 0 ? true : $game_switches[switch]
  815.     add_command(text, command[0], enabled)
  816.   end
  817.   
  818.   #--------------------------------------------------------------------------
  819.   # update
  820.   #--------------------------------------------------------------------------
  821.   def update
  822.     super
  823.     update_visible_windows
  824.   end
  825.   
  826.   #--------------------------------------------------------------------------
  827.   # update_visible_windows
  828.   #--------------------------------------------------------------------------
  829.   def update_visible_windows
  830.     return if @current_index == current_symbol
  831.     @current_index = current_symbol
  832.     @item_window.refresh unless @item_window.nil?
  833.   end
  834.   
  835.   #--------------------------------------------------------------------------
  836.   # add_learn_skill_command
  837.   #--------------------------------------------------------------------------
  838.   def add_learn_skill_command
  839.     return unless Switch.show_learn_skill
  840.     name = YEA::LEARN_SKILL::COMMAND_NAME
  841.     add_command(name, :learn_skill, true)
  842.   end
  843.   
  844. end # Window_ClassCommand

  845. #==============================================================================
  846. # ■ Window_ClassStatus
  847. #==============================================================================

  848. class Window_ClassStatus < Window_Base
  849.   
  850.   #--------------------------------------------------------------------------
  851.   # initialize
  852.   #--------------------------------------------------------------------------
  853.   def initialize(dx, dy)
  854.     super(dx, dy, window_width, fitting_height(4))
  855.     @actor = nil
  856.   end
  857.   
  858.   #--------------------------------------------------------------------------
  859.   # window_width
  860.   #--------------------------------------------------------------------------
  861.   def window_width; Graphics.width - 160; end
  862.   
  863.   #--------------------------------------------------------------------------
  864.   # actor=
  865.   #--------------------------------------------------------------------------
  866.   def actor=(actor)
  867.     return if @actor == actor
  868.     @actor = actor
  869.     refresh
  870.   end
  871.   
  872.   #--------------------------------------------------------------------------
  873.   # refresh
  874.   #--------------------------------------------------------------------------
  875.   def refresh
  876.     contents.clear
  877.     return if @actor.nil?
  878.     draw_actor_face(@actor, 0, 0)
  879.     draw_actor_simple_status(@actor, 108, line_height / 2)
  880.   end
  881.   
  882. end # Window_ClassStatus

  883. #==============================================================================
  884. # ■ Window_ClassParam
  885. #==============================================================================

  886. class Window_ClassParam < Window_Base
  887.   
  888.   #--------------------------------------------------------------------------
  889.   # initialize
  890.   #--------------------------------------------------------------------------
  891.   def initialize(dx, dy)
  892.     super(dx, dy, window_width, Graphics.height - dy)
  893.     @actor = nil
  894.     @temp_actor = nil
  895.     refresh
  896.   end
  897.   
  898.   #--------------------------------------------------------------------------
  899.   # window_width
  900.   #--------------------------------------------------------------------------
  901.   def window_width; return Graphics.width * 2 / 5; end
  902.   
  903.   #--------------------------------------------------------------------------
  904.   # actor=
  905.   #--------------------------------------------------------------------------
  906.   def actor=(actor)
  907.     return if @actor == actor
  908.     @actor = actor
  909.     refresh
  910.   end
  911.   
  912.   #--------------------------------------------------------------------------
  913.   # refresh
  914.   #--------------------------------------------------------------------------
  915.   def refresh
  916.     contents.clear
  917.     8.times {|i| draw_item(0, line_height * i, i) }
  918.   end
  919.   
  920.   #--------------------------------------------------------------------------
  921.   # set_temp_actor
  922.   #--------------------------------------------------------------------------
  923.   def set_temp_actor(temp_actor)
  924.     return if @temp_actor == temp_actor
  925.     @temp_actor = temp_actor
  926.     refresh
  927.   end
  928.   
  929.   #--------------------------------------------------------------------------
  930.   # draw_item
  931.   #--------------------------------------------------------------------------
  932.   def draw_item(dx, dy, param_id)
  933.     draw_background_colour(dx, dy)
  934.     draw_param_name(dx + 4, dy, param_id)
  935.     draw_current_param(dx + 4, dy, param_id) if @actor
  936.     drx = (contents.width + 22) / 2
  937.     draw_right_arrow(drx, dy)
  938.     draw_new_param(drx + 22, dy, param_id) if @temp_actor
  939.     reset_font_settings
  940.   end
  941.   
  942.   #--------------------------------------------------------------------------
  943.   # draw_background_colour
  944.   #--------------------------------------------------------------------------
  945.   def draw_background_colour(dx, dy)
  946.     colour = Color.new(0, 0, 0, translucent_alpha/2)
  947.     rect = Rect.new(dx+1, dy+1, contents.width - 2, line_height - 2)
  948.     contents.fill_rect(rect, colour)
  949.   end
  950.   
  951.   #--------------------------------------------------------------------------
  952.   # overwrite method: draw_param_name
  953.   #--------------------------------------------------------------------------
  954.   def draw_param_name(dx, dy, param_id)
  955.     contents.font.size = YEA::CLASS_SYSTEM::PARAM_FONT_SIZE
  956.     change_color(system_color)
  957.     draw_text(dx, dy, contents.width, line_height, Vocab::param(param_id))
  958.   end
  959.   
  960.   #--------------------------------------------------------------------------
  961.   # overwrite method: draw_current_param
  962.   #--------------------------------------------------------------------------
  963.   def draw_current_param(dx, dy, param_id)
  964.     change_color(normal_color)
  965.     dw = (contents.width + 22) / 2
  966.     draw_text(0, dy, dw, line_height, @actor.param(param_id).group, 2)
  967.     reset_font_settings
  968.   end
  969.   
  970.   #--------------------------------------------------------------------------
  971.   # draw_right_arrow
  972.   #--------------------------------------------------------------------------
  973.   def draw_right_arrow(x, y)
  974.     change_color(system_color)
  975.     draw_text(x, y, 22, line_height, "→", 1)
  976.   end
  977.   
  978.   #--------------------------------------------------------------------------
  979.   # draw_new_param
  980.   #--------------------------------------------------------------------------
  981.   def draw_new_param(dx, dy, param_id)
  982.     contents.font.size = YEA::CLASS_SYSTEM::PARAM_FONT_SIZE
  983.     new_value = @temp_actor.param(param_id)
  984.     change_color(param_change_color(new_value - @actor.param(param_id)))
  985.     draw_text(0, dy, contents.width-4, line_height, new_value.group, 2)
  986.     reset_font_settings
  987.   end
  988.   
  989. end # Window_ClassParam

  990. #==============================================================================
  991. # ■ Window_ClassList
  992. #==============================================================================

  993. class Window_ClassList < Window_Selectable
  994.   
  995.   #--------------------------------------------------------------------------
  996.   # initialize
  997.   #--------------------------------------------------------------------------
  998.   def initialize(dx, dy)
  999.     dw = Graphics.width - (Graphics.width * 2 / 5)
  1000.     dh = Graphics.height - dy
  1001.     super(dx, dy, dw, dh)
  1002.     @actor = nil
  1003.     @command_window = nil
  1004.     @status_window
  1005.     @data = []
  1006.   end
  1007.   
  1008.   #--------------------------------------------------------------------------
  1009.   # actor=
  1010.   #--------------------------------------------------------------------------
  1011.   def actor=(actor)
  1012.     return if @actor == actor
  1013.     @actor = actor
  1014.     @last_item = nil
  1015.     refresh
  1016.     self.oy = 0
  1017.   end
  1018.   
  1019.   #--------------------------------------------------------------------------
  1020.   # command_window=
  1021.   #--------------------------------------------------------------------------
  1022.   def command_window=(command_window)
  1023.     @command_window = command_window
  1024.   end
  1025.   
  1026.   #--------------------------------------------------------------------------
  1027.   # status_window=
  1028.   #--------------------------------------------------------------------------
  1029.   def status_window=(status_window)
  1030.     @status_window = status_window
  1031.   end
  1032.   
  1033.   #--------------------------------------------------------------------------
  1034.   # item_max
  1035.   #--------------------------------------------------------------------------
  1036.   def item_max; return @data ? @data.size : 1; end
  1037.   
  1038.   #--------------------------------------------------------------------------
  1039.   # item
  1040.   #--------------------------------------------------------------------------
  1041.   def item; return @data && index >= 0 ? @data[index] : nil; end
  1042.   
  1043.   #--------------------------------------------------------------------------
  1044.   # current_item_enabled?
  1045.   #--------------------------------------------------------------------------
  1046.   def current_item_enabled?; return enable?(@data[index]); end
  1047.   
  1048.   #--------------------------------------------------------------------------
  1049.   # include?
  1050.   #--------------------------------------------------------------------------
  1051.   def include?(item)
  1052.     return true if YEA::CLASS_SYSTEM::DEFAULT_UNLOCKS.include?(item.id)
  1053.     return @actor.unlocked_classes.include?(item.id)
  1054.   end
  1055.   
  1056.   #--------------------------------------------------------------------------
  1057.   # enable?
  1058.   #--------------------------------------------------------------------------
  1059.   def enable?(item)
  1060.     return false if item == @actor.class
  1061.     return true
  1062.   end
  1063.   
  1064.   #--------------------------------------------------------------------------
  1065.   # make_item_list
  1066.   #--------------------------------------------------------------------------
  1067.   def make_item_list
  1068.     @data = []
  1069.     for class_id in YEA::CLASS_SYSTEM::CLASS_ORDER
  1070.       next if $data_classes[class_id].nil?
  1071.       item = $data_classes[class_id]
  1072.       @data.push(item) if include?(item)
  1073.     end
  1074.   end
  1075.   
  1076.   #--------------------------------------------------------------------------
  1077.   # select_last
  1078.   #--------------------------------------------------------------------------
  1079.   def select_last
  1080.     case @command_window.current_symbol
  1081.     when :primary
  1082.       select(@data.index(@actor.class))
  1083.     when :subclass
  1084.       select(0) if @actor.subclass.nil?
  1085.       select(@data.index(@actor.subclass)) unless @actor.subclass.nil?
  1086.     else
  1087.       select(0)
  1088.     end
  1089.   end
  1090.   
  1091.   #--------------------------------------------------------------------------
  1092.   # draw_item
  1093.   #--------------------------------------------------------------------------
  1094.   def draw_item(index)
  1095.     item = @data[index]
  1096.     return if item.nil?
  1097.     rect = item_rect(index)
  1098.     rect.width -= 4
  1099.     reset_font_settings
  1100.     set_item_colour(item)
  1101.     draw_class_icon(item, rect)
  1102.     draw_class_name(item, rect)
  1103.     draw_class_level(item, rect)
  1104.   end
  1105.   
  1106.   #--------------------------------------------------------------------------
  1107.   # set_item_colour
  1108.   #--------------------------------------------------------------------------
  1109.   def set_item_colour(item)
  1110.     if item == @actor.class
  1111.       change_color(text_color(YEA::CLASS_SYSTEM::CURRENT_CLASS_COLOUR))
  1112.     elsif item == @actor.subclass
  1113.       change_color(text_color(YEA::CLASS_SYSTEM::SUBCLASS_COLOUR))
  1114.     else
  1115.       change_color(normal_color, enable?(item))
  1116.     end
  1117.   end
  1118.   
  1119.   #--------------------------------------------------------------------------
  1120.   # draw_class_icon
  1121.   #--------------------------------------------------------------------------
  1122.   def draw_class_icon(item, rect)
  1123.     icon = item.icon_index
  1124.     draw_icon(icon, rect.x, rect.y)
  1125.   end
  1126.   
  1127.   #--------------------------------------------------------------------------
  1128.   # draw_class_name
  1129.   #--------------------------------------------------------------------------
  1130.   def draw_class_name(item, rect)
  1131.     text = item.name
  1132.     draw_text(24, rect.y, rect.width-24, line_height, text)
  1133.   end
  1134.   
  1135.   #--------------------------------------------------------------------------
  1136.   # draw_class_level
  1137.   #--------------------------------------------------------------------------
  1138.   def draw_class_level(item, rect)
  1139.     return if YEA::CLASS_SYSTEM::MAINTAIN_LEVELS
  1140.     return if @actor.nil?
  1141.     level = @actor.class_level(item.id)
  1142.     contents.font.size = YEA::CLASS_SYSTEM::LEVEL_FONT_SIZE
  1143.     text = sprintf(YEA::CLASS_SYSTEM::CLASS_LEVEL, level.group)
  1144.     draw_text(rect, text, 2)
  1145.   end
  1146.   
  1147.   #--------------------------------------------------------------------------
  1148.   # update_help
  1149.   #--------------------------------------------------------------------------
  1150.   def update_help
  1151.     @help_window.set_item(item)
  1152.     return if @actor.nil?
  1153.     return if @status_window.nil?
  1154.     update_param_window
  1155.   end
  1156.   
  1157.   #--------------------------------------------------------------------------
  1158.   # update_param_window
  1159.   #--------------------------------------------------------------------------
  1160.   def update_param_window
  1161.     return if @last_item == item
  1162.     @last_item = item
  1163.     class_id = item.nil? ? @actor.class_id : item.id
  1164.     temp_actor = Marshal.load(Marshal.dump(@actor))
  1165.     temp_actor.temp_flag = true
  1166.     case @command_window.current_symbol
  1167.     when :primary
  1168.       temp_actor.change_class(class_id, YEA::CLASS_SYSTEM::MAINTAIN_LEVELS)
  1169.     when :subclass
  1170.       temp_actor.change_subclass(class_id)
  1171.     end
  1172.     @status_window.set_temp_actor(temp_actor)
  1173.   end
  1174.   
  1175.   #--------------------------------------------------------------------------
  1176.   # update_class
  1177.   #--------------------------------------------------------------------------
  1178.   def update_class
  1179.     @last_item = nil
  1180.     update_help
  1181.     refresh
  1182.     activate
  1183.   end
  1184.   
  1185.   #--------------------------------------------------------------------------
  1186.   # refresh
  1187.   #--------------------------------------------------------------------------
  1188.   def refresh
  1189.     make_item_list
  1190.     create_contents
  1191.     draw_all_items
  1192.   end
  1193.   
  1194. end # Window_ClassList

  1195. #==============================================================================
  1196. # ■ Scene_Menu
  1197. #==============================================================================

  1198. class Scene_Menu < Scene_MenuBase
  1199.   
  1200.   #--------------------------------------------------------------------------
  1201.   # alias method: create_command_window
  1202.   #--------------------------------------------------------------------------
  1203.   alias scene_menu_create_command_window_cs create_command_window
  1204.   def create_command_window
  1205.     scene_menu_create_command_window_cs
  1206.     @command_window.set_handler(:class, method(:command_personal))
  1207.   end
  1208.   
  1209.   #--------------------------------------------------------------------------
  1210.   # alias method: on_personal_ok
  1211.   #--------------------------------------------------------------------------
  1212.   alias scene_menu_on_personal_ok_cs on_personal_ok
  1213.   def on_personal_ok
  1214.     case @command_window.current_symbol
  1215.     when :class
  1216.       SceneManager.call(Scene_Class)
  1217.     else
  1218.       scene_menu_on_personal_ok_cs
  1219.     end
  1220.   end
  1221.   
  1222. end # Scene_Menu

  1223. #==============================================================================
  1224. # ■ Scene_Class
  1225. #==============================================================================

  1226. class Scene_Class < Scene_MenuBase
  1227.   
  1228.   #--------------------------------------------------------------------------
  1229.   # start
  1230.   #--------------------------------------------------------------------------
  1231.   def start
  1232.     super
  1233.     create_help_window
  1234.     create_command_window
  1235.     create_status_window
  1236.     create_param_window
  1237.     create_item_window
  1238.     relocate_windows
  1239.   end
  1240.   
  1241.   #--------------------------------------------------------------------------
  1242.   # create_command_window
  1243.   #--------------------------------------------------------------------------
  1244.   def create_command_window
  1245.     wy = @help_window.height
  1246.     @command_window = Window_ClassCommand.new(0, wy)
  1247.     @command_window.viewport = @viewport
  1248.     @command_window.help_window = @help_window
  1249.     @command_window.actor = @actor
  1250.     @command_window.set_handler(:cancel,   method(:return_scene))
  1251.     @command_window.set_handler(:primary,  method(:command_class_change))
  1252.     @command_window.set_handler(:subclass, method(:command_class_change))
  1253.     process_custom_class_commands
  1254.     return if $game_party.in_battle
  1255.     @command_window.set_handler(:pagedown, method(:next_actor))
  1256.     @command_window.set_handler(:pageup,   method(:prev_actor))
  1257.     @command_window.set_handler(:learn_skill, method(:command_learn_skill))
  1258.   end
  1259.   
  1260.   #--------------------------------------------------------------------------
  1261.   # process_custom_class_commands
  1262.   #--------------------------------------------------------------------------
  1263.   def process_custom_class_commands
  1264.     for command in YEA::CLASS_SYSTEM::COMMANDS
  1265.       next unless YEA::CLASS_SYSTEM::CUSTOM_CLASS_COMMANDS.include?(command[0])
  1266.       called_method = YEA::CLASS_SYSTEM::CUSTOM_CLASS_COMMANDS[command[0]][2]
  1267.       @command_window.set_handler(command[0], method(called_method))
  1268.     end
  1269.   end
  1270.   
  1271.   #--------------------------------------------------------------------------
  1272.   # create_status_window
  1273.   #--------------------------------------------------------------------------
  1274.   def create_status_window
  1275.     wy = @help_window.height
  1276.     @status_window = Window_ClassStatus.new(@command_window.width, wy)
  1277.     @status_window.viewport = @viewport
  1278.     @status_window.actor = @actor
  1279.   end
  1280.   
  1281.   #--------------------------------------------------------------------------
  1282.   # create_param_window
  1283.   #--------------------------------------------------------------------------
  1284.   def create_param_window
  1285.     dx = Graphics.width - (Graphics.width * 2 / 5)
  1286.     dy = @status_window.y + @status_window.height
  1287.     @param_window = Window_ClassParam.new(dx, dy)
  1288.     @param_window.viewport = @viewport
  1289.     @param_window.actor = @actor
  1290.   end
  1291.   
  1292.   #--------------------------------------------------------------------------
  1293.   # create_item_window
  1294.   #--------------------------------------------------------------------------
  1295.   def create_item_window
  1296.     dy = @status_window.y + @status_window.height
  1297.     @item_window = Window_ClassList.new(0, dy)
  1298.     @item_window.help_window = @help_window
  1299.     @item_window.command_window = @command_window
  1300.     @item_window.status_window = @param_window
  1301.     @item_window.viewport = @viewport
  1302.     @item_window.actor = @actor
  1303.     @command_window.item_window = @item_window
  1304.     @item_window.set_handler(:ok,     method(:on_class_ok))
  1305.     @item_window.set_handler(:cancel, method(:on_class_cancel))
  1306.   end
  1307.   
  1308.   #--------------------------------------------------------------------------
  1309.   # relocate_windows
  1310.   #--------------------------------------------------------------------------
  1311.   def relocate_windows
  1312.     return unless $imported["YEA-AceMenuEngine"]
  1313.     case Menu.help_window_location
  1314.     when 0 # Top
  1315.       @help_window.y = 0
  1316.       @command_window.y = @help_window.height
  1317.       @param_window.y = @command_window.y + @command_window.height
  1318.     when 1 # Middle
  1319.       @command_window.y = 0
  1320.       @help_window.y = @command_window.height
  1321.       @param_window.y = @help_window.y + @help_window.height
  1322.     else # Bottom
  1323.       @command_window.y = 0
  1324.       @param_window.y = @command_window.height
  1325.       @help_window.y = @param_window.y + @param_window.height
  1326.     end
  1327.     @status_window.y = @command_window.y
  1328.     @item_window.y = @param_window.y
  1329.   end
  1330.   
  1331.   #--------------------------------------------------------------------------
  1332.   # on_actor_change
  1333.   #--------------------------------------------------------------------------
  1334.   def on_actor_change
  1335.     @command_window.actor = @actor
  1336.     @status_window.actor = @actor
  1337.     @param_window.actor = @actor
  1338.     @item_window.actor = @actor
  1339.     @command_window.activate
  1340.   end
  1341.   
  1342.   #--------------------------------------------------------------------------
  1343.   # command_class_change
  1344.   #--------------------------------------------------------------------------
  1345.   def command_class_change
  1346.     @item_window.activate
  1347.     @item_window.select_last
  1348.   end
  1349.   
  1350.   #--------------------------------------------------------------------------
  1351.   # on_class_cancel
  1352.   #--------------------------------------------------------------------------
  1353.   def on_class_cancel
  1354.     @item_window.unselect
  1355.     @command_window.activate
  1356.     @param_window.set_temp_actor(nil)
  1357.   end
  1358.   
  1359.   #--------------------------------------------------------------------------
  1360.   # on_class_ok
  1361.   #--------------------------------------------------------------------------
  1362.   def on_class_ok
  1363.     Sound.play_equip
  1364.     class_id = @item_window.item.id
  1365.     maintain = YEA::CLASS_SYSTEM::MAINTAIN_LEVELS
  1366.     hp = @actor.hp * 1.0 / @actor.mhp
  1367.     mp = @actor.mp * 1.0 / [@actor.mmp, 1].max
  1368.     case @command_window.current_symbol
  1369.     when :primary
  1370.       @actor.change_class(class_id, maintain)
  1371.     when :subclass
  1372.       @actor.change_subclass(class_id)
  1373.     else
  1374.       @item_window.activate
  1375.       return
  1376.     end
  1377.     @actor.hp = (@actor.mhp * hp).to_i
  1378.     @actor.mp = (@actor.mmp * mp).to_i
  1379.     @status_window.refresh
  1380.     @item_window.update_class
  1381.   end
  1382.   
  1383.   #--------------------------------------------------------------------------
  1384.   # new method: command_learn_skill
  1385.   #--------------------------------------------------------------------------
  1386.   def command_learn_skill
  1387.     return unless $imported["YEA-LearnSkillEngine"]
  1388.     SceneManager.call(Scene_LearnSkill)
  1389.   end
  1390.   
  1391.   #--------------------------------------------------------------------------
  1392.   # command_name1
  1393.   #--------------------------------------------------------------------------
  1394.   def command_name1
  1395.     # Do nothing.
  1396.   end
  1397.   
  1398.   #--------------------------------------------------------------------------
  1399.   # command_name2
  1400.   #--------------------------------------------------------------------------
  1401.   def command_name2
  1402.     # Do nothing.
  1403.   end
  1404.   
  1405. end # Scene_Class

  1406. #==============================================================================
  1407. #
  1408. # ▼ End of File
  1409. #
  1410. #==============================================================================
复制代码
  1. #==============================================================================
  2. #
  3. # ▼ Yanfly Engine Ace - Class System Add-On: Class Unlock Level v1.00
  4. # -- Last Updated: 2011.12.20
  5. # -- Level: Normal
  6. # -- Requires: YEA - Class System v1.01+
  7. #
  8. #==============================================================================

  9. $imported = {} if $imported.nil?
  10. $imported["YEA-ClassUnlockLevel"] = true

  11. #==============================================================================
  12. # ▼ Updates
  13. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  14. # 2011.12.20 - Started Script and Finished.
  15. #
  16. #==============================================================================
  17. # ▼ Introduction
  18. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  19. # This script allows for classes to be unlocked after a class reaches a certain
  20. # level. Note that this script is made for the Class System script and not
  21. # using the MAINTAIN_LEVELS feature. Requirements for unlocking a class can be
  22. # multiple level requirements as well.
  23. #
  24. #==============================================================================
  25. # ▼ Instructions
  26. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  27. # To install this script, open up your script editor and copy/paste this script
  28. # to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save.
  29. #
  30. # -----------------------------------------------------------------------------
  31. # Class Notetags - These notetags go in the class notebox in the database.
  32. # -----------------------------------------------------------------------------
  33. # <level unlock requirements>
  34. #   class x: level y
  35. #   class x: level y
  36. # </level unlock requirements>
  37. # Sets the requirements for unlocking that particular class. The unlocking of
  38. # the class will require classes x to be at level y. Insert multiple of the
  39. # strings in between the two opening and closing notetags to require all of the
  40. # class levels to be met.
  41. #
  42. #==============================================================================
  43. # ▼ Compatibility
  44. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  45. # This script is made strictly for RPG Maker VX Ace. It is highly unlikely that
  46. # it will run with RPG Maker VX without adjusting.
  47. #
  48. # This script requires Yanfly Engine Ace - Class System v1.01+.
  49. #
  50. #==============================================================================
  51. # ▼ Editting anything past this point may potentially result in causing
  52. # computer damage, incontinence, explosion of user's head, coma, death, and/or
  53. # halitosis so edit at your own risk.
  54. #==============================================================================

  55. if $imported["YEA-ClassSystem"] && !YEA::CLASS_SYSTEM::MAINTAIN_LEVELS

  56. module YEA
  57.   module REGEXP
  58.   module CLASS
  59.    
  60.     LV_UNLOCK_ON =
  61.       /<(?:LEVEL_UNLOCK_REQUIREMENTS|level unlock requirements)>/i
  62.     LV_UNLOCK_OFF =
  63.       /<\/(?:LEVEL_UNLOCK_REQUIREMENTS|level unlock requirements)>/i
  64.     LV_UNLOCK_STR = /CLASS[ ](\d+): LEVEL[ ](\d+)/i
  65.    
  66.   end # CLASS
  67.   end # REGEXP
  68. end # YEA

  69. #==============================================================================
  70. # ■ DataManager
  71. #==============================================================================

  72. module DataManager
  73.   
  74.   #--------------------------------------------------------------------------
  75.   # alias method: load_database
  76.   #--------------------------------------------------------------------------
  77.   class <<self; alias load_database_cul load_database; end
  78.   def self.load_database
  79.     load_database_cul
  80.     load_notetags_cul
  81.   end
  82.   
  83.   #--------------------------------------------------------------------------
  84.   # new method: load_notetags_cul
  85.   #--------------------------------------------------------------------------
  86.   def self.load_notetags_cul
  87.     for obj in $data_classes
  88.       next if obj.nil?
  89.       obj.load_notetags_cul
  90.     end
  91.   end
  92.   
  93. end # DataManager

  94. #==============================================================================
  95. # ■ RPG::Class
  96. #==============================================================================

  97. class RPG::Class < RPG::BaseItem
  98.   
  99.   #--------------------------------------------------------------------------
  100.   # public instance variables
  101.   #--------------------------------------------------------------------------
  102.   attr_accessor :level_unlock
  103.   
  104.   #--------------------------------------------------------------------------
  105.   # common cache: load_notetags_cul
  106.   #--------------------------------------------------------------------------
  107.   def load_notetags_cul
  108.     @level_unlock = {}
  109.     @level_unlock_on = false
  110.     #---
  111.     self.note.split(/[\r\n]+/).each { |line|
  112.       case line
  113.       #---
  114.       when YEA::REGEXP::CLASS::LV_UNLOCK_ON
  115.         @level_unlock_on = true
  116.       when YEA::REGEXP::CLASS::LV_UNLOCK_OFF
  117.         @level_unlock_on = false
  118.       when YEA::REGEXP::CLASS::LV_UNLOCK_STR
  119.         next unless @level_unlock_on
  120.         @level_unlock[$1.to_i] = $2.to_i
  121.       end
  122.     } # self.note.split
  123.     #---
  124.   end
  125.   
  126. end # RPG::Class

  127. #==============================================================================
  128. # ■ Game_Actor
  129. #==============================================================================

  130. class Game_Actor < Game_Battler
  131.   
  132.   #--------------------------------------------------------------------------
  133.   # check_level_unlocked_classes
  134.   #--------------------------------------------------------------------------
  135.   def check_level_unlocked_classes
  136.     for item in $data_classes
  137.       next if item.nil?
  138.       next if unlocked_classes.include?(item.id)
  139.       next if item.level_unlock == {}
  140.       next unless class_unlock_level_requirements_met?(item)
  141.       unlock_class(item.id)
  142.     end
  143.   end
  144.   
  145.   #--------------------------------------------------------------------------
  146.   # class_unlock_level_requirements_met?
  147.   #--------------------------------------------------------------------------
  148.   def class_unlock_level_requirements_met?(item)
  149.     for key in item.level_unlock
  150.       class_id = key[0]
  151.       level_req = key[1]
  152.       return false if class_level(class_id) < level_req
  153.     end
  154.     return true
  155.   end
  156.   
  157. end # Game_Actor

  158. #==============================================================================
  159. # ■ Window_ClassList
  160. #==============================================================================

  161. class Window_ClassList < Window_Selectable
  162.   
  163.   #--------------------------------------------------------------------------
  164.   # alias method: actor=
  165.   #--------------------------------------------------------------------------
  166.   alias window_classlist_actor_equals_cul actor=
  167.   def actor=(actor)
  168.     return if @actor == actor
  169.     actor.check_level_unlocked_classes
  170.     window_classlist_actor_equals_cul(actor)
  171.   end
  172.   
  173. end # Window_ClassList

  174. end # $imported["YEA-ClassSystem"] && !YEA::CLASS_SYSTEM::MAINTAIN_LEVELS

  175. #==============================================================================
  176. #
  177. # ▼ End of File
  178. #
  179. #==============================================================================
复制代码
  1. #==============================================================================
  2. #
  3. # ▼ Yanfly Engine Ace - Class Specifics v1.00
  4. # -- Last Updated: 2011.12.23
  5. # -- Level: Normal
  6. # -- Requires: YEA - Class System v1.03+
  7. #
  8. #==============================================================================

  9. $imported = {} if $imported.nil?
  10. $imported["YEA-ClassSpecifics"] = true

  11. #==============================================================================
  12. # ▼ Updates
  13. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  14. # 2011.12.23 - Started Script and Finished.
  15. #
  16. #==============================================================================
  17. # ▼ Introduction
  18. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  19. # This script allows for certain classes to be primary-only or sublcass-only.
  20. # In addition to that, subclasses can require certain classes to be primary
  21. # classes in order to be applied.
  22. #
  23. #==============================================================================
  24. # ▼ Instructions
  25. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  26. # To install this script, open up your script editor and copy/paste this script
  27. # to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save.
  28. #
  29. # -----------------------------------------------------------------------------
  30. # Class Notetags - These notetags go in the class notebox in the database.
  31. # -----------------------------------------------------------------------------
  32. # <primary only>
  33. # Makes this class equippable only if it's the primary class.
  34. #
  35. # <subclass only>
  36. # Makes this class equippable only if it's the subclass class.
  37. #
  38. # <subclass to: x>
  39. # <subclass to: x, x>
  40. # This makes the class subclass only and only equippable if the primary class
  41. # is one of the listed x classes.
  42. #
  43. #==============================================================================
  44. # ▼ Compatibility
  45. # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  46. # This script is made strictly for RPG Maker VX Ace. It is highly unlikely that
  47. # it will run with RPG Maker VX without adjusting.
  48. #
  49. # This script requires Yanfly Engine Ace - Class System v1.03+.
  50. #
  51. #==============================================================================
  52. # ▼ Editting anything past this point may potentially result in causing
  53. # computer damage, incontinence, explosion of user's head, coma, death, and/or
  54. # halitosis so edit at your own risk.
  55. #==============================================================================

  56. if $imported["YEA-ClassSystem"]

  57. module YEA
  58.   module REGEXP
  59.   module CLASS
  60.    
  61.     PRIMARY_ONLY  = /<(?:PRIMARY_ONLY|primary only)>/i
  62.     SUBCLASS_ONLY = /<(?:SUBCLASS_ONLY|subclass only)>/i
  63.     SUBCLASS_TO = /<(?:SUBCLASS_TO|subclass to):[ ]*(\d+(?:\s*,\s*\d+)*)>/i
  64.    
  65.   end # CLASS
  66.   end # REGEXP
  67. end # YEA

  68. #==============================================================================
  69. # ■ DataManager
  70. #==============================================================================

  71. module DataManager
  72.   
  73.   #--------------------------------------------------------------------------
  74.   # alias method: load_database
  75.   #--------------------------------------------------------------------------
  76.   class <<self; alias load_database_csp load_database; end
  77.   def self.load_database
  78.     load_database_csp
  79.     load_notetags_csp
  80.   end
  81.   
  82.   #--------------------------------------------------------------------------
  83.   # new method: load_notetags_csp
  84.   #--------------------------------------------------------------------------
  85.   def self.load_notetags_csp
  86.     for obj in $data_classes
  87.       next if obj.nil?
  88.       obj.load_notetags_csp
  89.     end
  90.   end
  91.   
  92. end # DataManager

  93. #==============================================================================
  94. # ■ RPG::Class
  95. #==============================================================================

  96. class RPG::Class < RPG::BaseItem
  97.   
  98.   #--------------------------------------------------------------------------
  99.   # public instance variables
  100.   #--------------------------------------------------------------------------
  101.   attr_accessor :primary_only
  102.   attr_accessor :subclass_only
  103.   attr_accessor :subclass_to
  104.   
  105.   #--------------------------------------------------------------------------
  106.   # common cache: load_notetags_csp
  107.   #--------------------------------------------------------------------------
  108.   def load_notetags_csp
  109.     @primary_only = false
  110.     @subclass_only = false
  111.     @subclass_to = []
  112.     #---
  113.     self.note.split(/[\r\n]+/).each { |line|
  114.       case line
  115.       #---
  116.       when YEA::REGEXP::CLASS::PRIMARY_ONLY
  117.         @primary_only = true
  118.         @subclass_only = false
  119.         @subclass_to = []
  120.       when YEA::REGEXP::CLASS::SUBCLASS_ONLY
  121.         @primary_only = false
  122.         @subclass_only = true
  123.       when YEA::REGEXP::CLASS::SUBCLASS_TO
  124.         @primary_only = false
  125.         @subclass_only = true
  126.         $1.scan(/\d+/).each { |num|
  127.         @subclass_to.push(num.to_i) if num.to_i > 0 }
  128.       end
  129.     } # self.note.split
  130.     #---
  131.   end
  132.   
  133. end # RPG::Class

  134. #==============================================================================
  135. # ■ Game_Actor
  136. #==============================================================================

  137. class Game_Actor < Game_Battler
  138.   
  139.   #--------------------------------------------------------------------------
  140.   # alias method: change_class
  141.   #--------------------------------------------------------------------------
  142.   alias game_actor_change_class_csp change_class
  143.   def change_class(class_id, keep_exp = false)
  144.     return if $data_classes[class_id].subclass_only
  145.     game_actor_change_class_csp(class_id, keep_exp)
  146.     correct_subclass
  147.   end
  148.   
  149.   #--------------------------------------------------------------------------
  150.   # alias method: change_subclass
  151.   #--------------------------------------------------------------------------
  152.   alias game_actor_change_subclass_csp change_subclass
  153.   def change_subclass(class_id)
  154.     return unless subclass_requirements_met?(class_id)
  155.     game_actor_change_subclass_csp(class_id)
  156.   end
  157.   
  158.   #--------------------------------------------------------------------------
  159.   # new method: subclass_requirements_met?
  160.   #--------------------------------------------------------------------------
  161.   def subclass_requirements_met?(class_id)
  162.     subclass = $data_classes[class_id]
  163.     return false if subclass.primary_only
  164.     return subclass_to?(class_id) if subclass.subclass_to != []
  165.     return true
  166.   end
  167.   
  168.   #--------------------------------------------------------------------------
  169.   # new method: subclass_to?
  170.   #--------------------------------------------------------------------------
  171.   def subclass_to?(class_id)
  172.     return true if class_id == 0
  173.     subclass = $data_classes[class_id]
  174.     return false if subclass.nil?
  175.     for class_id in subclass.subclass_to
  176.       return true if class_id == self.class.id
  177.     end
  178.     return false
  179.   end
  180.   
  181.   #--------------------------------------------------------------------------
  182.   # new method: correct_subclass
  183.   #--------------------------------------------------------------------------
  184.   def correct_subclass
  185.     return if @subclass_id == 0
  186.     subclass = $data_classes[@subclass_id]
  187.     return if subclass.nil?
  188.     return if subclass.subclass_to == []
  189.     @subclass_id = 0 if !subclass_to?(@subclass_id)
  190.   end
  191.   
  192. end # Game_Actor

  193. #==============================================================================
  194. # ■ Window_ClassList
  195. #==============================================================================

  196. class Window_ClassList < Window_Selectable
  197.   
  198.   #--------------------------------------------------------------------------
  199.   # alias method: enable?
  200.   #--------------------------------------------------------------------------
  201.   alias window_classlist_enable_csp enable?
  202.   def enable?(item)
  203.     case @command_window.current_symbol
  204.     when :primary
  205.       return false if item.subclass_only
  206.     when :subclass
  207.       return false if item.primary_only
  208.       return @actor.subclass_to?(item.id) if item.subclass_to != []
  209.     end
  210.     return window_classlist_enable_csp(item)
  211.   end
  212.   
  213. end # Window_ClassList

  214. end # $imported["YEA-ClassSystem"]

  215. #==============================================================================
  216. #
  217. # ▼ End of File
  218. #
  219. #==============================================================================
复制代码
我想知道的是用什么脚本可以让指定角色或当前角色或队伍里指定角色解锁可以转换的新职业!
[img]http://service.t.sina.com.cn/widget/qmd/5339802982/c02e16bd/7.png
梦石
0
星屑
2378
在线时间
1014 小时
注册时间
2012-4-30
回帖
1459

开拓者

发表于 2012-10-22 16:15:39 | 显示全部楼层
大神使用谷歌翻译使我很头疼啊。。。<unlocked classes: X>在角色备注中添加。。默认解锁X号职业貌似吧。。。谷歌翻译很疼。。。
<level unlock requirements>
#   class x: level y
#   class x: level y
# </level unlock requirements>
是角色备注指职业x在该角色Y等级时解锁。。。。
<icon: x>
显示几号图标。。
<help description>
  string
  string
</help description>
string为帮助中显示的。。。
===================
<primary only>
只能当主职业
<subclass only>>
只能当主职业
<subclass to: x>
<subclass to: x, x>
只能在X等级使使用的主职业。。。。
  在职业备注里加
  1. $game_actors[x].unlock_class(y)#使X角色解锁y 职业
复制代码
  1. $game_actors[x].remove_class(y)#使X角色切换y 职业
复制代码
这个系统有三个部分的。这里是所有的用法。。所以有些可能没有用。。。。

点评

脚本框里的是事件脚本。。。  发表于 2012-10-22 16:16

评分

参与人数 1梦石 +2 收起 理由
Mic_洛洛 + 2 认可答案,6R精美好人卡+1

查看全部评分

回复

使用道具 举报

梦石
0
星屑
9292
在线时间
2504 小时
注册时间
2011-5-20
回帖
14521

开拓者

 楼主| 发表于 2012-10-22 18:07:02 | 显示全部楼层
铅笔描绘的思念 发表于 2012-10-22 16:15
大神使用谷歌翻译使我很头疼啊。。。在角色备注中添加。。默认解锁X号职业貌似吧。。。谷歌翻译很疼。。。 ...

如果我要角色完成某个任务后才可以解锁职业呢?

点评

如果是事件任务就事件脚本来搞定。。如果是脚本可以改改。。  发表于 2012-10-22 19:54
[img]http://service.t.sina.com.cn/widget/qmd/5339802982/c02e16bd/7.png
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖返回顶部