Advertisement
diamondandplatinum3

Fire Emblem/Disgaea Weapon System (Lite) ~ RGSS3

Jan 11th, 2013
891
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 68.09 KB | None | 0 0
  1. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  2. #             Fire Emblem/Disgaea Weapon System (Lite Version)
  3. #             Version: 1.1
  4. #             Authors: DiamondandPlatinum3
  5. #             Date: January 12, 2013
  6. #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  7. #  Description:
  8. #
  9. #    This script introduces a mixture of both Fire Emblem's and Disgaea's
  10. #    weapon system to your game.
  11. #    With this script you can allow your actors to have access to any weapon
  12. #    (unless you don't want them to, of course), so long as the actor has a
  13. #    high enough weapon skill level to wield it, this is the script mimicking
  14. #    Fire Emblem's weapon system.
  15. #    When improving a weapon rank, you'll also earn parameter bonuses for that
  16. #    weapon type, which can be further improved as your weapon rank increases,
  17. #    mimicking Disgaea's weapon system.
  18. #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  19. #------------------------------------------------------------------------------
  20. #  Instructions:
  21. #
  22. #   ~ I have made a video tutorial for this script, it's advised that you take a
  23. #     look at it in case you get confused on what things do.
  24. #     You can find the Video Here: https://www.youtube.com/watch?v=REZyKy900fc
  25. #
  26. #
  27. #   ~ The first thing you need to do is remove all weapon types from any and all actor
  28. #     classes in the database. Due to the way I've made this script, all other weapon
  29. #     take priority, including the default weapon system. Therefore it is important
  30. #     to remove all weapon types from actor classes, so that this script can do it's
  31. #     task without conflicting with the default weapon system.
  32. #       ScreenShot Can Be Found Here:   goo.gl/eXq3X
  33. #    
  34. #    
  35. #
  36. #   ~ With the above done, your actors can now equip absolutely every single weapon
  37. #     type. However you may not want certain actors to be able to use certain
  38. #     weapon types. Example, you may not want actor 1 (Eric) to equip any Bows or
  39. #     Guns, but every other weapon type is just fine. If that's the case, simply
  40. #     add the following notetag to his actor notebox.
  41. #         ~DoNotEquip[ ?, ?, ?, ]
  42. #     Now you can replace the Question Marks with the ID's of the weapon types you
  43. #     do not wish for him to be able to equip. You can have as many or as little as
  44. #     you want.
  45. #       ScreenShots Can Be Found Here:
  46. #             goo.gl/t5IzQ
  47. #               goo.gl/uZZ4X
  48. #             goo.gl/KwxUh 
  49. #             goo.gl/g4WNw 
  50. #             goo.gl/xfYxL
  51. #
  52. #
  53. #  ~  You can restrict some weapons from being equipped until your actor has
  54. #     acquired a specific weapon skill. So your more powerful axes may be
  55. #     be restricted to only being equipped if your actor is a master at
  56. #     wielding axes. To do so you insert the following notetag in a weapon notebox.
  57. #         ~WeaponLevel: ?
  58. #     Now you can replace the Question Mark with a letter corresponding to a
  59. #     Weapon Rank, so a Letter like "D", "C", "B", "A", "S" will restrict
  60. #     that weapon until a certain weapon rank.
  61. #     If you do not use this tag on a weapon or insert any letter besides those,
  62. #     the weapon rank will default to "E".
  63. #       ScreenShot Can Be Found Here:   goo.gl/PWKTl
  64. #      
  65. #
  66. #  ~  If you want skills to help increase your weapon rank when they're used.
  67. #     You can add a notetag in their notebox which will allow this. It is the following:
  68. #         ~EarnWeaponSkillPoints: ?
  69. #     Now you can replace the Question Mark with a number which will add on to
  70. #     your actor's currently equipped weapon type (types if dual wielding).
  71. #       ScreenShot Can Be Found Here:   goo.gl/8z6Gt
  72. #
  73. #
  74. #
  75. #  ~  If you wish to temporarily turn on or off the Level Up Message Display for
  76. #     your weapons, you can do so via a script call:
  77. #         toggle_weapon_level_message_display( on_or_off )
  78. #     Replacing on_or_off with 'true' if you want the box to be displayed or
  79. #     'false' if you wish to temporarily disable it.
  80. #     This is handy for secretly increasing actor weapon ranks in your game.
  81. #
  82. #
  83. #  ~  You can add weapon points to any actor for the weapon they're currently
  84. #     holding by using the following script call:
  85. #         add_weapon_skill_points( actor_id, points )
  86. #     Replacing actor_id with the ID of actor you are giving points to and
  87. #     replacing points with the amount of points you are giving to them.
  88. #
  89. #
  90. #  ~  You can also increase specific weapon types for a player even when they're
  91. #     not equipping that type. Using the following script call:
  92. #         add_specific_weapon_type_skill_points( actor_id, wType, points )
  93. #     Replacing actor_id with the ID of the actor you wish to give points to,
  94. #     wType with the Weapon Type you are assigning points to (ie Sword is weapon type 4),
  95. #     and points with the amount of points you are giving them.
  96. #       This script call is especially useful if you wantto let NPCs give your
  97. #     Actors training in using weapons, because why would an archer help you learn
  98. #     how to use an axe?
  99. #
  100. #
  101. #     A ScreenShot Showing the use of the Above Three ScriptCalls Can Be Found
  102. #     Here:   goo.gl/ETywg
  103. #
  104. #
  105. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  106. module DiamondandPlatinum3
  107.   module WeaponLevels
  108.     #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
  109.     #                                                        -=
  110.     #                 Editable Region        ////            ==
  111.     #                                                        =-
  112.     #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  113.    
  114.    
  115.     #----------------------------------------------------------------------
  116.     # * Menu Option Information
  117.     #----------------------------------------------------------------------
  118.     # For this Script, a menu option is added to allow players to view their
  119.     # weapon levels. This option allows you to edit what the menu option is
  120.     # called when looking at the menu.
  121.     Menu_Option_Title = "Weapon Level Status"
  122.                                                
  123.    
  124.    
  125.    
  126.    
  127.     #----------------------------------------------------------------------
  128.     # * Message Box Information
  129.     #----------------------------------------------------------------------
  130.     Show_Message_Box = true   # Do you want a message box to be displayed when
  131.                               # Your current weapon rank goes up?
  132.                              
  133.     Rank_Up_SE = "Applause1"  # Sound Effect To Be Played when weapon rank
  134.     SE_Volume  = 80           # increases. If you don't want an SE to play,
  135.     SE_Pitch   = 100          # set to "NO_SOUNDEFFECT".
  136.                               # SE will only play when a MessageBox is displayed.
  137.                        
  138.                              
  139.     # Here You Get To Choose What the Message Box Says.
  140.     # Param Quotes will only be used if that param actually increased.
  141.     # Same for Skills
  142.     Increased_Weapon_Rank_Text    = "has increased their weapon rank!"
  143.     Increased_Attack_Power        = "Attack Power has been increased!"
  144.     Increased_Defence_Power       = "Weapon Defence has been increased!"
  145.     Increased_Magic_Attack_Power  = "Magic Attack Power has been increased!"
  146.     Increased_Magic_Defence_Power = "Magic Defence has been increased!"
  147.     Increased_Agility_Power       = "Agility has been improved!"
  148.     Acquired_New_Skill            = "has aquired a new skill!"
  149.                              
  150.                              
  151.    
  152.    
  153.                              
  154.     #----------------------------------------------------------------------
  155.     # * Weapon Accumulation Information
  156.     #----------------------------------------------------------------------
  157.     # How Many Points do you want to gain for your weapon when you attack
  158.     # with it in battle. 1 by default.
  159.     Attack_Points_Gain = 1
  160.    
  161.    
  162.     # Since we will always start at level E, modify how many times a
  163.     # weapon must be used before you go up to the Next Weapon Level
  164.     #
  165.     # So Basically everytime you attack with that weapon type, your count
  166.     # will increase by one, and once it hits one of the numbers you specified below,
  167.     # your weapon level will go up a rank.
  168.     WeaponAccumulation = {
  169.             #  D,   C,   B,   A,    S,
  170.       1  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 1,  By Default is 'Weapon Type: Axe'
  171.       2  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 2,  By Default is 'Weapon Type: Claw'
  172.       3  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 3,  By Default is 'Weapon Type: Spear'
  173.       4  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 4,  By Default is 'Weapon Type: Sword'
  174.       5  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 5,  By Default is 'Weapon Type: Katana'
  175.       6  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 6,  By Default is 'Weapon Type: Bow'
  176.       7  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 7,  By Default is 'Weapon Type: Dagger'
  177.       8  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 8,  By Default is 'Weapon Type: Hammer'
  178.       9  => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 9,  By Default is 'Weapon Type: Staff'
  179.       10 => [ 100, 250, 550, 1000, 1500, ], # Weapon Type 10, By Default is 'Weapon Type: Gun'
  180.      
  181.    
  182.       # If you have more weapon types than these, you'll need to add them just above.
  183.     # Copy-Paste the above, and I'll leave it to your common sense to change things
  184.     # accordingly. Paste ABOVE this comment
  185.     }
  186.    
  187.    
  188.    
  189.    
  190.    
  191.    
  192.     #----------------------------------------------------------------------
  193.     # * Weapon Bonus Params Information
  194.     #----------------------------------------------------------------------
  195.     # Here You get to decide what bonuses your actors get when they have leveled
  196.     # up a weapon and remain having it equipped. The Abbreviations are as followed:
  197.               # ATK  ATtacK power
  198.               # DEF  DEFense power
  199.               # MAT  Magic ATtack power
  200.               # MDF  Magic DeFense power
  201.               # AGI  AGIlity
  202.     # These are percentages out of 100, meaning that if I had a stat boost of 10%,
  203.     # The actor will receive a 10% bonus of their current stat.
  204.     # In other words, if ATK stat is 90 and weapon bonus for ATK is 10%, the actor
  205.     # will receive 9 extra stat points for their ATK.
  206.     #
  207.     # Effects do not carry on into further levels. So if an actor was to receive
  208.     # a param stat boost of 10% in weapon level "D", and 15% in weapon level "C",
  209.     # The actor will only get 15% during weapon level "C" instead of 25%.
  210.     # Keep this in mind while editing.
  211.     WeaponParamBonuses = {
  212.            # ATK, DEF, MAT, MDF, AGI,
  213.       1 => [                          # Weapon Type 1, By Default is 'Weapon Type: Axe'
  214.               5,   2,   0,   0,   1,  # Bonuses for Axe Level "D"
  215.               7,   2,   0,   0,   2,  # Bonuses for Axe Level "C"
  216.               9,   4,   0,   0,   3,  # Bonuses for Axe Level "B"
  217.               10,  5,   0,   0,   4,  # Bonuses for Axe Level "A"
  218.               13,  6,   0,   0,   6,  # Bonuses for Axe Level "S"
  219.            ],
  220.          
  221.            
  222.       2 => [                          # Weapon Type 2, By Default is 'Weapon Type: Claw'
  223.               5,   3,   0,   0,   1,  # Bonuses for Claw Level "D"
  224.               7,   4,   0,   0,   2,  # Bonuses for Claw Level "C"
  225.               8,   6,   0,   0,   3,  # Bonuses for Claw Level "B"
  226.               10,  8,   0,   0,   4,  # Bonuses for Claw Level "A"
  227.               13,  11,  0,   0,   6,  # Bonuses for Claw Level "S"
  228.            ],
  229.      
  230.            
  231.       3 => [                          # Weapon Type 3, By Default is 'Weapon Type: Spear'
  232.               5,   3,   0,   0,   1,  # Bonuses for Spear Level "D"
  233.               7,   4,   0,   0,   2,  # Bonuses for Spear Level "C"
  234.               8,   6,   0,   0,   3,  # Bonuses for Spear Level "B"
  235.               10,  8,   0,   0,   4,  # Bonuses for Spear Level "A"
  236.               13,  11,  0,   0,   6,  # Bonuses for Spear Level "S"
  237.            ],
  238.      
  239.            
  240.            # ATK, DEF, MAT, MDF, AGI,
  241.       4 => [                          # Weapon Type 4, By Default is 'Weapon Type: Sword'
  242.               5,   3,   0,   0,   1,  # Bonuses for Sword Level "D"
  243.               7,   4,   0,   0,   2,  # Bonuses for Sword Level "C"
  244.               8,   6,   0,   0,   3,  # Bonuses for Sword Level "B"
  245.               10,  8,   0,   0,   4,  # Bonuses for Sword Level "A"
  246.               13,  11,  0,   0,   6,  # Bonuses for Sword Level "S"
  247.            ],
  248.            
  249.            
  250.       5 => [                          # Weapon Type 5, By Default is 'Weapon Type: Katana'
  251.               5,   3,   0,   0,   1,  # Bonuses for Katana Level "D"
  252.               7,   4,   0,   0,   2,  # Bonuses for Katana Level "C"
  253.               8,   6,   0,   0,   3,  # Bonuses for Katana Level "B"
  254.               10,  8,   0,   0,   4,  # Bonuses for Katana Level "A"
  255.               13,  11,  0,   0,   6,  # Bonuses for Katana Level "S"
  256.            ],
  257.            
  258.            
  259.       6 => [                          # Weapon Type 6, By Default is 'Weapon Type: Bow'
  260.               5,   3,   0,   0,   1,  # Bonuses for Bow Level "D"
  261.               7,   4,   0,   0,   2,  # Bonuses for Bow Level "C"
  262.               8,   6,   0,   0,   3,  # Bonuses for Bow Level "B"
  263.               10,  8,   0,   0,   4,  # Bonuses for Bow Level "A"
  264.               13,  11,  0,   0,   6,  # Bonuses for Bow Level "S"
  265.            ],
  266.            
  267.            
  268.            # ATK, DEF, MAT, MDF, AGI,
  269.      7  => [                          # Weapon Type 7, By Default is 'Weapon Type: Dagger'
  270.               5,   3,   0,   0,   1,  # Bonuses for Dagger Level "D"
  271.               7,   4,   0,   0,   2,  # Bonuses for Dagger Level "C"
  272.               8,   6,   0,   0,   3,  # Bonuses for Dagger Level "B"
  273.               10,  8,   0,   0,   4,  # Bonuses for Dagger Level "A"
  274.               13,  11,  0,   0,   6,  # Bonuses for Dagger Level "S"
  275.            ],
  276.            
  277.            
  278.            
  279.       8 => [                          # Weapon Type 8, By Default is 'Weapon Type: Hammer'
  280.               5,   3,   0,   0,   1,  # Bonuses for Hammer Level "D"
  281.               7,   4,   0,   0,   2,  # Bonuses for Hammer Level "C"
  282.               8,   6,   0,   0,   3,  # Bonuses for Hammer Level "B"
  283.               10,  8,   0,   0,   4,  # Bonuses for Hammer Level "A"
  284.               13,  11,  0,   0,   6,  # Bonuses for Hammer Level "S"
  285.            ],
  286.            
  287.            
  288.            
  289.       9 => [                          # Weapon Type 9, By Default is 'Weapon Type: Staff'
  290.               5,   3,   0,   0,   1,  # Bonuses for Staff Level "D"
  291.               7,   4,   0,   0,   2,  # Bonuses for Staff Level "C"
  292.               8,   6,   0,   0,   3,  # Bonuses for Staff Level "B"
  293.               10,  8,   0,   0,   4,  # Bonuses for Staff Level "A"
  294.               13,  11,  0,   0,   6,  # Bonuses for Staff Level "S"
  295.            ],
  296.            
  297.            
  298.            # ATK, DEF, MAT, MDF, AGI,
  299.      10 => [                          # Weapon Type 10, By Default is 'Weapon Type: Gun'
  300.               5,   3,   0,   0,   1,  # Bonuses for Gun Level "D"
  301.               7,   4,   0,   0,   2,  # Bonuses for Gun Level "C"
  302.               8,   6,   0,   0,   3,  # Bonuses for Gun Level "B"
  303.               10,  8,   0,   0,   4,  # Bonuses for Gun Level "A"
  304.               13,  11,  0,   0,   6,  # Bonuses for Gun Level "S"
  305.            ],
  306.      
  307.      
  308.      
  309.      
  310.       # If you have more than 10 weapon types, you can add them by copying the
  311.       # above and changing the weapon type id to the appropriate number.
  312.       # Paste ABOVE this comment
  313.     }
  314.    
  315.    
  316.    
  317.    
  318.    
  319.    
  320.     #----------------------------------------------------------------------
  321.     # * Weapon Bonus Skills Information
  322.     #----------------------------------------------------------------------
  323.     # You can select specific skills that your actor can learn once they have
  324.     # achieved a high enough weapon rank. This skill will only be available
  325.     # whilst the actor has this weapon type equipped and has the required
  326.     # skill level. Therefore if this weapon type is removed, so too are the
  327.     # acquired skills until the conditions for learning those skills are once
  328.     # again satisfied.
  329.     # Basically you can have the same skill be learned by different weapon
  330.     # types and it'll work just fine.
  331.     #
  332.     # Skill Bonuses DO NOT carry over to higher levels. If you have a weapon
  333.     # type that gives you a skill at Rank "D", you must also include that skill
  334.     # in the next rank.
  335.     #
  336.     # If you do not want any skill for a specific rank, remove all skill IDs in
  337.     # that Rank.
  338.     WeaponSkillBonuses = {
  339.    
  340.       # Weapon Type 1, By Default is 'Weapon Type: Axe'
  341.       1 => {    #   Skill IDs
  342.                 1 => [ 3, ],            # Bonus Skills for: Axe Level "D"
  343.                 2 => [ 3, ],            # Bonus Skills for: Axe Level "C"
  344.                 3 => [ 3, 4, ],         # Bonus Skills for: Axe Level "B"
  345.                 4 => [ 3, 4, ],         # Bonus Skills for: Axe Level "A"
  346.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Axe Level "S"
  347.             },
  348.            
  349.            
  350.            
  351.       # Weapon Type 2, By Default is 'Weapon Type: Claw'
  352.       2 => {    
  353.                 1 => [ 3, ],            # Bonus Skills for: Claw Level "D"
  354.                 2 => [ 3, ],            # Bonus Skills for: Claw Level "C"
  355.                 3 => [ 3, 4, ],         # Bonus Skills for: Claw Level "B"
  356.                 4 => [ 3, 4, ],         # Bonus Skills for: Claw Level "A"
  357.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Claw Level "S"
  358.             },
  359.            
  360.            
  361.            
  362.       # Weapon Type 3, By Default is 'Weapon Type: Spear'
  363.       3 => {    
  364.                 1 => [ 3, ],            # Bonus Skills for: Spear Level "D"
  365.                 2 => [ 3, ],            # Bonus Skills for: Spear Level "C"
  366.                 3 => [ 3, 4, ],         # Bonus Skills for: Spear Level "B"
  367.                 4 => [ 3, 4, ],         # Bonus Skills for: Spear Level "A"
  368.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Spear Level "S"
  369.             },
  370.            
  371.            
  372.            
  373.       # Weapon Type 4, By Default is 'Weapon Type: Sword'
  374.       4 => {    #   Skill IDs
  375.                 1 => [ 3, ],            # Bonus Skills for: Sword Level "D"
  376.                 2 => [ 3, ],            # Bonus Skills for: Sword Level "C"
  377.                 3 => [ 3, 4, ],         # Bonus Skills for: Sword Level "B"
  378.                 4 => [ 3, 4, ],         # Bonus Skills for: Sword Level "A"
  379.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Sword Level "S"
  380.             },
  381.            
  382.            
  383.            
  384.       # Weapon Type 5, By Default is 'Weapon Type: Katana'
  385.       5 => {    
  386.                 1 => [ 3, ],            # Bonus Skills for: Katana Level "D"
  387.                 2 => [ 3, ],            # Bonus Skills for: Katana Level "C"
  388.                 3 => [ 3, 4, ],         # Bonus Skills for: Katana Level "B"
  389.                 4 => [ 3, 4, ],         # Bonus Skills for: Katana Level "A"
  390.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Katana Level "S"
  391.             },
  392.            
  393.            
  394.            
  395.       # Weapon Type 6, By Default is 'Weapon Type: Bow'
  396.       6 => {    
  397.                 1 => [ 3, ],            # Bonus Skills for: Bow Level "D"
  398.                 2 => [ 3, ],            # Bonus Skills for: Bow Level "C"
  399.                 3 => [ 3, 4, ],         # Bonus Skills for: Bow Level "B"
  400.                 4 => [ 3, 4, ],         # Bonus Skills for: Bow Level "A"
  401.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Bow Level "S"
  402.             },
  403.            
  404.            
  405.            
  406.       # Weapon Type 7, By Default is 'Weapon Type: Dagger'
  407.       7 => {    #   Skill IDs
  408.                 1 => [ 3, ],            # Bonus Skills for: Dagger Level "D"
  409.                 2 => [ 3, ],            # Bonus Skills for: Dagger Level "C"
  410.                 3 => [ 3, 4, ],         # Bonus Skills for: Dagger Level "B"
  411.                 4 => [ 3, 4, ],         # Bonus Skills for: Dagger Level "A"
  412.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Dagger Level "S"
  413.             },
  414.            
  415.            
  416.            
  417.       # Weapon Type 8, By Default is 'Weapon Type: Hammer'
  418.       8 => {    
  419.                 1 => [ 3, ],            # Bonus Skills for: Hammer Level "D"
  420.                 2 => [ 3, ],            # Bonus Skills for: Hammer Level "C"
  421.                 3 => [ 3, 4, ],         # Bonus Skills for: Hammer Level "B"
  422.                 4 => [ 3, 4, ],         # Bonus Skills for: Hammer Level "A"
  423.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Hammer Level "S"
  424.             },
  425.            
  426.            
  427.            
  428.       # Weapon Type 9, By Default is 'Weapon Type: Staff'
  429.       9 => {    
  430.                 1 => [ 3, ],            # Bonus Skills for: Staff Level "D"
  431.                 2 => [ 3, ],            # Bonus Skills for: Staff Level "C"
  432.                 3 => [ 3, 4, ],         # Bonus Skills for: Staff Level "B"
  433.                 4 => [ 3, 4, ],         # Bonus Skills for: Staff Level "A"
  434.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Staff Level "S"
  435.             },
  436.            
  437.            
  438.            
  439.       # Weapon Type 10, By Default is 'Weapon Type: Gun'
  440.       10 => {   #   Skill IDs
  441.                 1 => [ 3, ],            # Bonus Skills for: Gun Level "D"
  442.                 2 => [ 3, ],            # Bonus Skills for: Gun Level "C"
  443.                 3 => [ 3, 4, ],         # Bonus Skills for: Gun Level "B"
  444.                 4 => [ 3, 4, ],         # Bonus Skills for: Gun Level "A"
  445.                 5 => [ 3, 4, 5, ],      # Bonus Skills for: Gun Level "S"
  446.              },
  447.      
  448.      
  449.       # Same as before, if you have any more weapon types, add them above this
  450.       # comment
  451.     }
  452.    
  453.    
  454.    
  455.    
  456.    
  457.     #----------------------------------------------------------------------
  458.     # * Weapon Status Menu Information
  459.     #----------------------------------------------------------------------
  460.     WeaponStatusMenuInfo = {
  461.       :weapon_level_colour => {
  462.         # Colour:  Red,  Green,  Blue  
  463.         1  => [    150,   150,    60  ], # Colour For: Actor's Name
  464.         2  => [    255,   200,   255  ], # Colour For: "Weapon Level" Label
  465.         3  => [    200,   255,   255  ], # Colour For: "Weapon Level Bonuses" Label
  466.         4  => [    255,    50,   255  ], # Colour For: Weapon Level "S"
  467.         5  => [    170,   135,   170  ], # Colour For: Weapon Level "A"
  468.         6  => [    140,   165,   140  ], # Colour For: Weapon Level "B"
  469.         7  => [    110,   195,   110  ], # Colour For: Weapon Level "C"
  470.         8  => [     80,   225,    80  ], # Colour For: Weapon Level "D"
  471.         9  => [     50,   255,    50  ], # Colour For: Weapon Level "E"
  472.         10 => [    255,   255,   255  ], # Colour For: No Weapon Param Bonus
  473.         11 => [     50,   255,    50  ], # Colour For: Weapon Param Bonus
  474.         12 => [    255,   216,     0  ], # Colour For: Equipped Weapon Param Bonus
  475.         13 => [    127,   100,    36  ], # Colour For: Weapon Gauge Primary Colour
  476.         14 => [     63,    50,    18  ], # Colour For: Weapon Gauge Gradient Colour
  477.       },
  478.      
  479.       :weapon_icon_id => {
  480.         #     Icon_ID,  
  481.         1  => [ 144 ],       # Weapon Type: Axe
  482.         2  => [ 145 ],       # Weapon Type: Claw
  483.         3  => [ 146 ],       # Weapon Type: Spear
  484.         4  => [ 147 ],       # Weapon Type: Sword
  485.         5  => [ 148 ],       # Weapon Type: Katana
  486.         6  => [ 149 ],       # Weapon Type: Bow
  487.         7  => [ 150 ],       # Weapon Type: Dagger
  488.         8  => [ 151 ],       # Weapon Type: Hammer
  489.         9  => [ 152 ],       # Weapon Type: Staff
  490.         10 => [ 153 ],       # Weapon Type: Gun
  491.                              # More Weapon Types? No Worries, Insert Them Here.
  492.       },
  493.      
  494.     :bonusparam_icon_id => {
  495.         #    Icon_ID,  
  496.         1  => [ 66 ],       # Icon for Bonus Param: ATK
  497.         2  => [ 67 ],       # Icon for Bonus Param: DEF
  498.         3  => [ 68 ],       # Icon for Bonus Param: MAT
  499.         4  => [ 69 ],       # Icon for Bonus Param: MDF
  500.         5  => [ 70 ],       # Icon for Bonus Param: AGI
  501.       },
  502.     }
  503.     #===========================================================
  504.     #                                           \/
  505.     #               End of Editable Region      /\
  506.     #                                           \/
  507.     #===========================================================
  508.     #---------------------------------------------------------
  509.     # No touchie past here unless you know what you are
  510.     # doing. Failure to heed this warning could cause your
  511.     # computer to yell and scream at you.
  512.     #
  513.     # Edit at your own risk.
  514.     #--------------------------------------------------------
  515.    
  516.    
  517.    
  518.    
  519.    
  520.    
  521.    
  522.    
  523.    
  524.    
  525.     #------------------------------------------------------------------------
  526.     # * Toggle Weapon Level Message Box
  527.     #------------------------------------------------------------------------
  528.     def self.toggle_weapon_level_message_display( on_or_off )
  529.       self.const_set(:Show_Message_Box, on_or_off) if !!on_or_off == on_or_off
  530.     end
  531.     #------------------------------------------------------------------------
  532.     # * Get Current Weapon Skill
  533.     #------------------------------------------------------------------------
  534.     def self.get_current_weapon_level( wType, actor_id, wCurrentSkill )
  535.       return "E" if wType <= 0 || wCurrentSkill == nil
  536.       return "S" if wCurrentSkill >= WeaponAccumulation[wType][4]
  537.       return "A" if wCurrentSkill >= WeaponAccumulation[wType][3]
  538.       return "B" if wCurrentSkill >= WeaponAccumulation[wType][2]
  539.       return "C" if wCurrentSkill >= WeaponAccumulation[wType][1]
  540.       return "D" if wCurrentSkill >= WeaponAccumulation[wType][0]
  541.       return "E"
  542.     end
  543.     #------------------------------------------------------------------------
  544.     # * Convert Skill String To Index
  545.     #------------------------------------------------------------------------
  546.     def self.convert_skill_string_to_index( skill_string )
  547.       case skill_string
  548.         when "S" then return 4
  549.         when "A" then return 3
  550.         when "B" then return 2
  551.         when "C" then return 1
  552.         when "D" then return 0
  553.       end
  554.       return -1
  555.     end
  556.     #------------------------------------------------------------------------
  557.     # * Increment Weapon Skill Points
  558.     #------------------------------------------------------------------------
  559.     def self.increment_weapon_skill_points( actor_id, skillpoints = -1 )
  560.       skillpoints = Attack_Points_Gain if skillpoints < 0
  561.       actor = $game_actors[actor_id]
  562.      
  563.       # Get Weapon Types and Skill Levels
  564.       weapontype1 = actor.equips[0] && actor.equips[0].is_a?(RPG::Weapon) ? actor.equips[0].wtype_id : 0
  565.       weapontype2 = actor.equips[1] && actor.equips[1].is_a?(RPG::Weapon) ? actor.equips[1].wtype_id : 0
  566.            
  567.       # Increment Weapon Skill Points, Add Bonus Params, Show Level Up Message Box
  568.       if weapontype1 && weapontype1 > 0
  569.         weapon_skill = get_current_weapon_level( weapontype1, actor.id, actor.dp3_weapon_level[weapontype1 - 1] )
  570.         actor.dp3_weapon_level[weapontype1 - 1] += skillpoints
  571.         show_weapon_level_up_message_box(weapontype1, actor_id, weapon_skill)
  572.         remove_and_add_bonus_params(weapontype1, actor_id, weapon_skill)
  573.         remove_and_add_bonus_skills(weapontype1, actor_id, weapon_skill)
  574.       end
  575.      
  576.       if weapontype2 && weapontype2 > 0
  577.         weapon_skill = get_current_weapon_level( weapontype2, actor.id, actor.dp3_weapon_level[weapontype2 - 1] )
  578.         actor.dp3_weapon_level[weapontype2 - 1] += skillpoints
  579.         if weapontype1 != weapontype2
  580.           show_weapon_level_up_message_box(weapontype2, actor_id, weapon_skill)
  581.           remove_and_add_bonus_params(weapontype2, actor_id, weapon_skill)
  582.           remove_and_add_bonus_skills(weapontype2, actor_id, weapon_skill)
  583.         end
  584.       end
  585.     end
  586.     #------------------------------------------------------------------------
  587.     # * Increment Specific Weapon Skill Points
  588.     #------------------------------------------------------------------------
  589.     def self.increment_specific_weapon_skill_points( actor_id, wType, skillpoints = 1 )
  590.       actor = $game_actors[actor_id]
  591.      
  592.       # Get Weapon Types and Skill Levels
  593.       weapon_skill = get_current_weapon_level( wType, actor_id, actor.dp3_weapon_level[wType - 1] )
  594.        
  595.       # Increase Weapon Skill Points
  596.       actor.dp3_weapon_level[wType - 1] += skillpoints
  597.      
  598.       # Show Weapon Level Up Message Box if Weapon Rank Increased
  599.       show_weapon_level_up_message_box(wType, actor_id, weapon_skill)
  600.      
  601.       # Modify Bonus Params if Weapon Rank Increased
  602.       remove_and_add_bonus_params(wType, actor_id, weapon_skill)
  603.      
  604.       # Modify Bonus Skills if Weapon Rank Increased
  605.       remove_and_add_bonus_skills(wType, actor_id, weapon_skill)
  606.     end
  607.     #------------------------------------------------------------------------
  608.     # * Add Bonus Params
  609.     #------------------------------------------------------------------------
  610.     def self.add_bonus_params( wType, actor_id, slot_id, skip_weapon_check = false, curr_skill = nil)
  611.       unless !skip_weapon_check && get_opposing_weapon_slot_weapon_type( actor_id, slot_id ) == wType
  612.         actor = $game_actors[actor_id]
  613.         unless curr_skill
  614.           method_args = [wType, actor_id, actor.dp3_weapon_level[wType - 1]]
  615.           curr_skill = get_current_weapon_level( *method_args )
  616.         end
  617.         for i in 0..4
  618.           actor.dp3_increment_param(i + 2, get_bonus_param( wType, actor_id, i, curr_skill ))
  619.         end
  620.       end
  621.     end
  622.     #------------------------------------------------------------------------
  623.     # * Remove Bonus Params
  624.     #------------------------------------------------------------------------
  625.     def self.remove_bonus_params( wType, actor_id, slot_id, skip_weapon_check = false, curr_skill = nil)
  626.       unless !skip_weapon_check && get_opposing_weapon_slot_weapon_type( actor_id, slot_id ) == wType
  627.         actor = $game_actors[actor_id]
  628.         unless curr_skill
  629.           method_args = [wType, actor_id, actor.dp3_weapon_level[wType - 1]]
  630.           curr_skill = get_current_weapon_level( *method_args )
  631.         end
  632.         for i in 0..4
  633.           actor.dp3_decrement_param(i + 2, get_bonus_param( wType, actor_id, i, curr_skill ))
  634.         end
  635.       end
  636.     end
  637.     #------------------------------------------------------------------------
  638.     # * Add and Remove Bonus Params
  639.     #------------------------------------------------------------------------
  640.     def self.remove_and_add_bonus_params(wType, actor_id, skill_before)
  641.       curr_skill = get_current_weapon_level( wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1] )
  642.      
  643.       if convert_skill_string_to_index(curr_skill) > convert_skill_string_to_index(skill_before)
  644.         if get_currently_equipping_this_weapon_type( wType, actor_id )
  645.           remove_bonus_params( wType, actor_id, nil, true)
  646.           add_bonus_params( wType, actor_id, nil, true)
  647.         end
  648.       end
  649.     end
  650.     #------------------------------------------------------------------------
  651.     # * Add Weapon Bonus Skills
  652.     #------------------------------------------------------------------------
  653.     def self.add_weapon_bonus_skills( wType, actor_id, slot_id, skip_weapon_check = false, curr_skill = nil)
  654.      unless !skip_weapon_check && get_opposing_weapon_slot_weapon_type( actor_id, slot_id ) == wType
  655.        unless curr_skill
  656.           method_args = [wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1]]
  657.           curr_skill = get_current_weapon_level( *method_args )
  658.         end
  659.         curr_skill = convert_skill_string_to_index( curr_skill )
  660.         return if curr_skill < 0
  661.        
  662.         # Now Apply Learning the Skills
  663.         WeaponSkillBonuses[wType][curr_skill + 1].each do |skill_id|
  664.           $game_actors[actor_id].learn_skill(skill_id)
  665.         end
  666.       end
  667.     end
  668.     #------------------------------------------------------------------------
  669.     # * Remove Weapon Bonus Skills
  670.     #------------------------------------------------------------------------
  671.     def self.remove_weapon_bonus_skills( wType, actor_id, slot_id, skip_weapon_check = false, curr_skill = nil)
  672.       unless !skip_weapon_check && get_opposing_weapon_slot_weapon_type( actor_id, slot_id ) == wType
  673.         unless curr_skill
  674.           method_args = [wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1]]
  675.           curr_skill = get_current_weapon_level( *method_args )
  676.         end
  677.         curr_skill = convert_skill_string_to_index( curr_skill )
  678.         return if curr_skill < 0
  679.        
  680.         # Now Apply Forgetting the Skills
  681.         WeaponSkillBonuses[wType][curr_skill + 1].each do |skill_id|
  682.           $game_actors[actor_id].forget_skill(skill_id)
  683.         end
  684.        
  685.         # Incase of Dual Wielding Weapons, the other Weapon May Contain Skills We
  686.         # Just Removed, So Relearn them if Necessary
  687.         return if skip_weapon_check
  688.         wType = get_opposing_weapon_slot_weapon_type( actor_id, slot_id )
  689.         return if wType == 0
  690.         method_args = [wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1]]
  691.         curr_skill = get_current_weapon_level( *method_args )
  692.         add_weapon_bonus_skills( wType, actor_id, nil, true, curr_skill)
  693.       end
  694.     end
  695.     #------------------------------------------------------------------------
  696.     # * Add and Remove Bonus Skills
  697.     #------------------------------------------------------------------------
  698.     def self.remove_and_add_bonus_skills(wType, actor_id, skill_before)
  699.       curr_skill = get_current_weapon_level( wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1] )
  700.      
  701.       if convert_skill_string_to_index(curr_skill) > convert_skill_string_to_index(skill_before)
  702.         if get_currently_equipping_this_weapon_type( wType, actor_id )
  703.           remove_weapon_bonus_skills( wType, actor_id, nil, true, skill_before)
  704.           add_weapon_bonus_skills( wType, actor_id, nil, true, curr_skill)
  705.         end
  706.       end
  707.     end
  708.     #------------------------------------------------------------------------
  709.     # * Weapon Compatible With Current Skill?
  710.     #------------------------------------------------------------------------
  711.     def self.get_skilllevel_and_weapon_compatible( current_skill, wskill )
  712.       current_skill         = convert_skill_string_to_index(current_skill)
  713.       wskill                = convert_skill_string_to_index(wskill)
  714.       return current_skill >= wskill
  715.     end  
  716.     #------------------------------------------------------------------------
  717.     # * Get Currently Equipped This Weapon Type?
  718.     #------------------------------------------------------------------------
  719.     def self.get_currently_equipping_this_weapon_type( wType, actor_id )
  720.       weapon1 = $game_actors[actor_id].equips[0]
  721.       weapon1 = weapon1 && weapon1.is_a?(RPG::Weapon) ? weapon1.wtype_id : 0
  722.       weapon2 = $game_actors[actor_id].equips[1]
  723.       weapon2 = weapon2 && weapon2.is_a?(RPG::Weapon) ? weapon2.wtype_id : 0
  724.       return weapon1 == wType || weapon2 == wType
  725.     end
  726.     #------------------------------------------------------------------------
  727.     # * Get Opposing Weapon Slot Type ~ Dual Wielding
  728.     #------------------------------------------------------------------------
  729.     def self.get_opposing_weapon_slot_weapon_type( actor_id, slot_id )
  730.       # We're Checking the opposite Weapon Slot
  731.       if slot_id == 0
  732.         slot_id = 1
  733.       else
  734.         slot_id = 0
  735.       end
  736.       weapontype = $game_actors[actor_id].equips[slot_id]
  737.       weapontype = weapontype && weapontype.is_a?(RPG::Weapon) ? weapontype.wtype_id : 0
  738.       return weapontype
  739.     end
  740.     #------------------------------------------------------------------------
  741.     # * Get Next Level Up Rate
  742.     #------------------------------------------------------------------------
  743.     def self.get_next_level_up_rate( wType, actor_id, current_skill, current_skill_points )
  744.       return 0.0 if wType <= 0
  745.       case current_skill
  746.         when "S"
  747.           return 1.0
  748.         when "A"
  749.           return current_skill_points.to_f / WeaponAccumulation[wType][4]
  750.         when "B"
  751.           return current_skill_points.to_f / WeaponAccumulation[wType][3]
  752.         when "C"
  753.           return current_skill_points.to_f / WeaponAccumulation[wType][2]
  754.         when "D"
  755.           return current_skill_points.to_f / WeaponAccumulation[wType][1]
  756.       end
  757.       return current_skill_points.to_f / WeaponAccumulation[wType][0]
  758.     end
  759.     #------------------------------------------------------------------------
  760.     # * Get Bonus Param
  761.     #------------------------------------------------------------------------
  762.     def self.get_bonus_param( wType, actor_id, param, curr_skill, return_float = false )
  763.       return 0 if curr_skill == "E" || wType <= 0
  764.       index = 5 * convert_skill_string_to_index(curr_skill)
  765.       actor_param = $game_actors[actor_id].class.params[param + 2, $game_actors[actor_id].level]
  766.       actor_param = (actor_param.to_f * (WeaponParamBonuses[wType][param + index].to_f * 0.01)).to_f
  767.       actor_param = 1.0 if actor_param < 1.0 && WeaponParamBonuses[wType][param + index] > 0
  768.       return actor_param if return_float
  769.       return actor_param.to_i
  770.     end
  771.     #--------------------------------------------------------------------------
  772.     # * Show Weapon Level Up Message Box
  773.     #--------------------------------------------------------------------------
  774.     def self.show_weapon_level_up_message_box(wType, actor_id, skill_before)
  775.       return unless actor_id && Show_Message_Box && wType > 0
  776.       curr_skill = get_current_weapon_level( wType, actor_id, $game_actors[actor_id].dp3_weapon_level[wType - 1] )
  777.      
  778.       if convert_skill_string_to_index(curr_skill) > convert_skill_string_to_index(skill_before)
  779.         RPG::SE.new(Rank_Up_SE, SE_Volume, SE_Pitch).play if Rank_Up_SE && Rank_Up_SE != "NO_SOUNDEFFECT"
  780.         actor_name = $game_actors[actor_id].name + "'s "
  781.         $game_message.add('\.' + $game_actors[actor_id].name + " " + Increased_Weapon_Rank_Text)
  782.        
  783.         # Attack
  784.         old_bonus_param = get_bonus_param( wType, actor_id, 0, skill_before, true )
  785.         new_bonus_param = get_bonus_param( wType, actor_id, 0, curr_skill, true )
  786.         $game_message.add('\.' + actor_name + Increased_Attack_Power) if new_bonus_param > old_bonus_param
  787.        
  788.         # Defence
  789.         old_bonus_param = get_bonus_param( wType, actor_id, 1, skill_before, true )
  790.         new_bonus_param = get_bonus_param( wType, actor_id, 1, curr_skill, true )
  791.         $game_message.add('\.' + actor_name + Increased_Defence_Power) if new_bonus_param > old_bonus_param
  792.        
  793.         # Magic Attack
  794.         old_bonus_param = get_bonus_param( wType, actor_id, 2, skill_before, true )
  795.         new_bonus_param = get_bonus_param( wType, actor_id, 2, curr_skill, true )
  796.         $game_message.add('\.' + actor_name + Increased_Magic_Attack_Power) if new_bonus_param > old_bonus_param
  797.        
  798.         # Magic Defense
  799.         old_bonus_param = get_bonus_param( wType, actor_id, 3, skill_before, true )
  800.         new_bonus_param = get_bonus_param( wType, actor_id, 3, curr_skill, true )
  801.         $game_message.add('\.' + actor_name + Increased_Magic_Defence_Power) if new_bonus_param > old_bonus_param
  802.        
  803.         # Agility
  804.         old_bonus_param = get_bonus_param( wType, actor_id, 4, skill_before, true )
  805.         new_bonus_param = get_bonus_param( wType, actor_id, 4, curr_skill, true )
  806.         $game_message.add('\.' + actor_name + Increased_Agility_Power) if new_bonus_param > old_bonus_param
  807.        
  808.         # Learned new Skill?
  809.         curr_skill = convert_skill_string_to_index( curr_skill )
  810.         WeaponSkillBonuses[wType][curr_skill + 1].each do |skill_id|
  811.           unless $game_actors[actor_id].skill_learn?($data_skills[skill_id])
  812.             $game_actors[actor_id].learn_skill(skill_id)
  813.             $game_message.add('\.' + $game_actors[actor_id].name + " " + Acquired_New_Skill)
  814.             break
  815.           end
  816.         end
  817.       end
  818.     end
  819.   end # Weapon Levels Module
  820. end # DiamondandPlatinum3 Module
  821.  
  822.  
  823.  
  824. #==============================================================================
  825. # ** Game_Actor
  826. #------------------------------------------------------------------------------
  827. #  This class handles actors. It is used within the Game_Actors class
  828. # ($game_actors) and is also referenced from the Game_Party class ($game_party).
  829. #==============================================================================
  830.  
  831. class Game_Actor < Game_Battler
  832.   #--------------------------------------------------------------------------
  833.   # * Public Instance Variables
  834.   #--------------------------------------------------------------------------
  835.   attr_accessor :dp3_weapon_level                 # Weapon Level Array
  836.   attr_accessor :dp3_normal_params                # Regular Parameters Array
  837.   attr_accessor :dp3_actor_param_weapon_bonus     # Bonus Parameters Array
  838.   #--------------------------------------------------------------------------
  839.   # * Alias Listings
  840.   #--------------------------------------------------------------------------
  841.   alias dp3_weaplev_gameactor_init_0edku                  initialize
  842.   alias dp3_weaplev_gameactor_equippable_0edku            equippable?
  843.   alias dp3_weaplev_gameactor_changeequip_0edku           change_equip
  844.   alias dp3_weaplev_gameactor_skillconditionsmet_0edku    skill_conditions_met?
  845.   #--------------------------------------------------------------------------
  846.   # * Object Initialization
  847.   #--------------------------------------------------------------------------
  848.   def initialize( *args )
  849.     @dp3_weapon_level             = []
  850.     @dp3_normal_params            = [ 0, 0, 0, 0, 0  ] # ATK, DEF, MAT, MDF, AGI
  851.     @dp3_actor_param_weapon_bonus = [ 0, 0, 0, 0, 0,   # ATK, DEF, MAT, MDF, AGI
  852.                                       0, 0, 0, 0, 0, ] # In Case Of Dual Wielding
  853.     highest_weapon_id = 0
  854.     for weapon in $data_weapons
  855.       highest_weapon_id = weapon.wtype_id if weapon && weapon.wtype_id > highest_weapon_id
  856.     end
  857.     while(@dp3_weapon_level.size < highest_weapon_id)
  858.       @dp3_weapon_level[@dp3_weapon_level.size] = 0
  859.     end
  860.    
  861.    
  862.     # Call Original Method
  863.     dp3_weaplev_gameactor_init_0edku( *args )
  864.   end
  865.   #--------------------------------------------------------------------------
  866.   # * Determine if Equippable
  867.   #--------------------------------------------------------------------------
  868.   def equippable?(item)
  869.     can_equip = dp3_weaplev_gameactor_equippable_0edku(item) # Call Original Method
  870.     return can_equip || item.is_a?(RPG::Weapon) && dp3_is_weapon_level_sufficient(item)
  871.   end
  872.   #--------------------------------------------------------------------------
  873.   # * Change Equipment
  874.   #--------------------------------------------------------------------------
  875.   def change_equip(slot_id, item)
  876.     # Remove the Bonus Params For the Weapon Type Being Removed
  877.     if self.equips[slot_id] && self.equips[slot_id].is_a?(RPG::Weapon)
  878.       removed_weapon_type = self.equips[slot_id].wtype_id
  879.       if removed_weapon_type > 0
  880.         DiamondandPlatinum3::WeaponLevels::remove_bonus_params(removed_weapon_type, self.id, slot_id)
  881.         DiamondandPlatinum3::WeaponLevels::remove_weapon_bonus_skills(removed_weapon_type, self.id, slot_id)
  882.       end
  883.     end
  884.        
  885.     # Add the Bonus Params For the Weapon Type Being Equipped
  886.     if item && item.is_a?(RPG::Weapon)
  887.       new_weapon_type = item.wtype_id
  888.       if new_weapon_type > 0
  889.         DiamondandPlatinum3::WeaponLevels::add_bonus_params(new_weapon_type, self.id, slot_id)
  890.         DiamondandPlatinum3::WeaponLevels::add_weapon_bonus_skills(new_weapon_type, self.id, slot_id)
  891.       end
  892.     end
  893.    
  894.     # Call Original Method
  895.     dp3_weaplev_gameactor_changeequip_0edku(slot_id, item)
  896.   end
  897.  
  898.   #--------------------------------------------------------------------------
  899.   # * Determine if Weapon Level is Sufficient
  900.   #--------------------------------------------------------------------------
  901.   def dp3_is_weapon_level_sufficient(weapon)
  902.     # Do Not Equip Weapon Type Notetag
  903.     $data_actors[self.id].note[/~DoNotEquip\[\s*(.+?)\]/im]
  904.     if $1
  905.       do_not_equip_types = $1.scan(/\d+/).collect {|i| i.to_i }
  906.       return false if do_not_equip_types.include?(weapon.wtype_id)
  907.     end
  908.     #~~~~~
  909.     return true if weapon.wtype_id == 0
  910.     $data_weapons[weapon.id].note[/~WeaponLevel:\s*(.+)/i]
  911.     return true unless $1 && $1 != ""
  912.     method_args = [ weapon.wtype_id, self.id, @dp3_weapon_level[weapon.wtype_id - 1] ]
  913.     curr_skill = DiamondandPlatinum3::WeaponLevels::get_current_weapon_level( *method_args )
  914.     return DiamondandPlatinum3::WeaponLevels::get_skilllevel_and_weapon_compatible( curr_skill, $1.upcase )  
  915.   end
  916.   #--------------------------------------------------------------------------
  917.   # * Increment Param
  918.   #--------------------------------------------------------------------------
  919.   def dp3_increment_param(param_id, incrementation)
  920.     @param_plus[param_id] += incrementation
  921.   end
  922.   #--------------------------------------------------------------------------
  923.   # * Decrement Param
  924.   #--------------------------------------------------------------------------
  925.   def dp3_decrement_param(param_id, decrementation)
  926.     @param_plus[param_id] -= decrementation
  927.   end
  928.   #--------------------------------------------------------------------------
  929.   # * Check Usability Conditions for Skill
  930.   #--------------------------------------------------------------------------
  931.   def skill_conditions_met?(skill)
  932.     return true if dp3_weaplev_gameactor_skillconditionsmet_0edku(skill)
  933.     return false unless usable_item_conditions_met?(skill)
  934.    
  935.     # Check Weapon Types and Skills for Usability
  936.     weapontype = self.equips[0] && self.equips[0].is_a?(RPG::Weapon) ? self.equips[0].wtype_id : 0
  937.     if weapontype > 0
  938.       method_args = [ weapontype, self.id, @dp3_weapon_level[weapontype - 1] ]
  939.       curr_skill = DiamondandPlatinum3::WeaponLevels::get_current_weapon_level( *method_args )
  940.       if curr_skill != "E"
  941.         curr_skill = DiamondandPlatinum3::WeaponLevels::convert_skill_string_to_index( curr_skill ) + 1
  942.         return true if DiamondandPlatinum3::WeaponLevels::WeaponSkillBonuses[weapontype][curr_skill].include?(skill.id)
  943.       end
  944.     end
  945.     # Weapon 2
  946.     weapontype = self.equips[1] && self.equips[1].is_a?(RPG::Weapon) ? self.equips[1].wtype_id : 0
  947.     return false if weapontype <= 0
  948.     method_args = [ weapontype, self.id, @dp3_weapon_level[weapontype - 1] ]
  949.     curr_skill = DiamondandPlatinum3::WeaponLevels::get_current_weapon_level( *method_args )
  950.     return false if curr_skill == "E"
  951.     curr_skill = DiamondandPlatinum3::WeaponLevels::convert_skill_string_to_index( curr_skill ) + 1
  952.     return DiamondandPlatinum3::WeaponLevels::WeaponSkillBonuses[weapontype][curr_skill].include?(skill.id)
  953.   end
  954. end
  955.  
  956.  
  957.  
  958.  
  959.  
  960.  
  961.  
  962. #==============================================================================
  963. # ** Game_Battler
  964. #------------------------------------------------------------------------------
  965. #  A battler class with methods for sprites and actions added. This class
  966. # is used as a super class of the Game_Actor class and Game_Enemy class.
  967. #==============================================================================
  968.  
  969. class Game_Battler < Game_BattlerBase
  970.   #--------------------------------------------------------------------------
  971.   # * Alias Listings
  972.   #--------------------------------------------------------------------------
  973.   alias dp3_weaplev_gamebattler_useitem_0edku                 use_item  
  974.   #--------------------------------------------------------------------------
  975.   # * Aliased Method: Use Skill/Item
  976.   #--------------------------------------------------------------------------
  977.   def use_item(item)
  978.     if @actor_id && item.is_a?(RPG::Skill)
  979.       #///// Increment Skill Points if Necessary /////#
  980.       if item.id == 1 # Attack
  981.         DiamondandPlatinum3::WeaponLevels::increment_weapon_skill_points( @actor_id )
  982.       else
  983.         $data_skills[item.id].note[/~EarnWeaponSkillPoints:\s*(\d+)/im]
  984.         if $1 && $1 != ""
  985.           DiamondandPlatinum3::WeaponLevels::increment_weapon_skill_points( @actor_id, $1.to_i )
  986.         end
  987.       end
  988.     end
  989.    
  990.     # Call Original Method
  991.     dp3_weaplev_gamebattler_useitem_0edku(item)
  992.   end
  993. end
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002. #==============================================================================
  1003. # ** Window_WeaponLevelStatus
  1004. #------------------------------------------------------------------------------
  1005. #  This window displays full status specs on the Weapon Ranks.
  1006. #==============================================================================
  1007.  
  1008. class Window_WeaponLevelStatus < Window_Selectable
  1009.   include DiamondandPlatinum3::WeaponLevels
  1010.   #--------------------------------------------------------------------------
  1011.   # * Object Initialization
  1012.   #--------------------------------------------------------------------------
  1013.   def initialize(actor)
  1014.     @actor = actor
  1015.     create_oy_params
  1016.     super(0, 0, Graphics.width, Graphics.height)
  1017.     refresh
  1018.     activate
  1019.   end
  1020.   #--------------------------------------------------------------------------
  1021.   # * Create OY Params
  1022.   #--------------------------------------------------------------------------
  1023.   def create_oy_params
  1024.     $data_actors[@actor.id].note[/~DoNotEquip\[\s*(.+?)\]/im]
  1025.     do_not_equip_types = $1 ? $1.scan(/\d+/).collect {|i| i.to_i } : []
  1026.     @oy_finish = (90 + (25 * (WeaponAccumulation.size - do_not_equip_types.size)))
  1027.   end
  1028.   #--------------------------------------------------------------------------
  1029.   # * Set Contents Height
  1030.   #--------------------------------------------------------------------------
  1031.   def contents_height
  1032.     return @oy_finish
  1033.   end
  1034.   #--------------------------------------------------------------------------
  1035.   # * Set Actor
  1036.   #--------------------------------------------------------------------------
  1037.   def actor=(actor)
  1038.     return if @actor == actor
  1039.     @actor = actor
  1040.     create_oy_params
  1041.     create_contents
  1042.     self.oy = 0
  1043.     refresh
  1044.   end
  1045.   #--------------------------------------------------------------------------
  1046.   # * Update
  1047.   #--------------------------------------------------------------------------
  1048.   def update(*args)
  1049.     super(*args)
  1050.     self.oy += 1 if Input.press?(:DOWN) && self.oy <= (@oy_finish - self.height)
  1051.     self.oy -= 1 if Input.press?(:UP)   && self.oy > 0
  1052.   end
  1053.   #--------------------------------------------------------------------------
  1054.   # * Refresh
  1055.   #--------------------------------------------------------------------------
  1056.   def refresh
  1057.     contents.clear
  1058.     @xPos = 20; @yPos = 5
  1059.     # Draw Top
  1060.     draw_actor_name()
  1061.     draw_horz_line(@yPos)
  1062.     @yPos += 20
  1063.    
  1064.     # Draw Lower
  1065.     draw_labels()
  1066.     draw_weapon_level_info()
  1067.   end
  1068.   #--------------------------------------------------------------------------
  1069.   # * Draw Horizontal Line
  1070.   #--------------------------------------------------------------------------
  1071.   def draw_horz_line(y)
  1072.     line_colour = normal_color
  1073.     line_colour.alpha = 48
  1074.     line_y = y + line_height / 2 - 1
  1075.     contents.fill_rect(0, line_y, contents_width, 2, line_colour)
  1076.   end
  1077.   #--------------------------------------------------------------------------
  1078.   # * Draw Icon
  1079.   #--------------------------------------------------------------------------
  1080.   def draw_icon(icon_index, x, y, w = 24, h = 24, enabled = true)
  1081.     bitmap = Cache.system("Iconset")
  1082.     blit_x = ((icon_index % 16) * 24) + (24 - w)
  1083.     blit_y = ((icon_index / 16) * 24) + (24 - h)
  1084.     rect = Rect.new(blit_x, blit_y, w, h)
  1085.     y += (24 - h)
  1086.     contents.blt(x, y, bitmap, rect, enabled ? 255 : translucent_alpha)
  1087.   end
  1088.   #--------------------------------------------------------------------------
  1089.   # * Draw Name
  1090.   #--------------------------------------------------------------------------
  1091.   def draw_actor_name()
  1092.     contents.font.size = 30
  1093.     w = (@actor.name.length * contents.font.size)
  1094.     x = ((self.width * 0.5) - ((@actor.name.length * 13) * 0.5))
  1095.     self.change_color(Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][1]))
  1096.     self.draw_text(x, @yPos, w, contents.font.size, @actor.name)
  1097.    
  1098.    
  1099.     change_color(normal_color)
  1100.     contents.font.size = Font.default_size
  1101.    
  1102.     @yPos += 30
  1103.   end
  1104.   #--------------------------------------------------------------------------
  1105.   # * Draw Labels
  1106.   #--------------------------------------------------------------------------
  1107.   def draw_labels()
  1108.     contents.font.size = 30
  1109.     @xPos += 30
  1110.     self.change_color(Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][2]))
  1111.     self.draw_text(@xPos, @yPos, 180, contents.font.size, "Weapon Level")
  1112.     @xPos += 210
  1113.     self.draw_text(@xPos, @yPos, 250, contents.font.size, "Current Weapon Bonuses")
  1114.     change_color(normal_color)
  1115.     contents.font.size = Font.default_size
  1116.     @xPos = 20
  1117.     @yPos += 35
  1118.   end
  1119.   #--------------------------------------------------------------------------
  1120.   # * Draw Weapon Level Info
  1121.   #--------------------------------------------------------------------------
  1122.   def draw_weapon_level_info()
  1123.     $data_actors[@actor.id].note[/~DoNotEquip\[\s*(.+?)\]/im]
  1124.     do_not_equip_types = $1 ? $1.scan(/\d+/).collect {|i| i.to_i } : []
  1125.     yPos_Correction = 25
  1126.     for i in 1..WeaponAccumulation.size
  1127.       # Skip this Weapon Type?
  1128.       next if do_not_equip_types.include?(i)
  1129.       # Get Current Weapon Skill
  1130.       curr_skill = get_current_weapon_skill(i)
  1131.       # Draw Icon
  1132.       draw_icon(WeaponStatusMenuInfo[:weapon_icon_id][i][0], @xPos, @yPos, 24, yPos_Correction)
  1133.       @xPos += 25
  1134.       # Draw Gauge
  1135.       rate = get_next_level_up_rate(i, curr_skill)
  1136.       draw_gauge(@xPos, @yPos - 5, 150, rate, get_gaugecolour1, get_gaugecolour2)
  1137.       @xPos += 175 # Gauge Width Plus 25 Offset
  1138.       # Draw Weapon Level
  1139.       self.change_color(get_weapon_level_colour( curr_skill ))
  1140.       draw_text(@xPos, @yPos, 25, 25, curr_skill)
  1141.       self.change_color(normal_color)
  1142.       @xPos += 25
  1143.       # Draw Weapon Bonuses
  1144.       for j in 0..4
  1145.         draw_icon(WeaponStatusMenuInfo[:bonusparam_icon_id][j + 1][0], @xPos, @yPos, 24, yPos_Correction)
  1146.         @xPos += 29
  1147.         bonus = self.get_actor_bonus_param( i, j, curr_skill )
  1148.         text = bonus.to_s
  1149.         self.change_color(get_weapon_bonus_colour( bonus, i ))
  1150.         draw_text(@xPos, @yPos, 23, yPos_Correction, text)
  1151.         self.change_color(normal_color)
  1152.         @xPos += 26
  1153.       end
  1154.       @xPos = 20
  1155.       @yPos += yPos_Correction
  1156.     end
  1157.   end
  1158.   #--------------------------------------------------------------------------
  1159.   # * Get Current Weapon Skill
  1160.   #--------------------------------------------------------------------------
  1161.   def get_current_weapon_skill( wType )
  1162.     return DiamondandPlatinum3::WeaponLevels::get_current_weapon_level(
  1163.             wType, @actor.id, @actor.dp3_weapon_level[wType - 1] )
  1164.   end
  1165.   #--------------------------------------------------------------------------
  1166.   # * Get Current Weapon Skill
  1167.   #--------------------------------------------------------------------------
  1168.   def get_next_level_up_rate( wType, curr_skill )
  1169.     return DiamondandPlatinum3::WeaponLevels::get_next_level_up_rate(
  1170.             wType, @actor.id, curr_skill, @actor.dp3_weapon_level[wType - 1] )
  1171.   end
  1172.   #--------------------------------------------------------------------------
  1173.   # * Get Current Weapon Skill
  1174.   #--------------------------------------------------------------------------
  1175.   def get_actor_bonus_param( wType, param, curr_skill )
  1176.     return DiamondandPlatinum3::WeaponLevels::get_bonus_param(
  1177.             wType, @actor.id, param, curr_skill )
  1178.   end        
  1179.   #--------------------------------------------------------------------------
  1180.   # * Get Gauge Colours
  1181.   #--------------------------------------------------------------------------
  1182.   def get_gaugecolour1
  1183.     return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][13])
  1184.   end
  1185.   def get_gaugecolour2
  1186.     return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][14])
  1187.   end
  1188.   #--------------------------------------------------------------------------
  1189.   # * Get Weapon Level Colours
  1190.   #--------------------------------------------------------------------------
  1191.   def get_weapon_level_colour( curr_skill )
  1192.     case curr_skill
  1193.       when "S"; return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][4])
  1194.       when "A"; return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][5])
  1195.       when "B"; return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][6])
  1196.       when "C"; return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][7])
  1197.       when "D"; return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][8])
  1198.     end
  1199.     return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][9])
  1200.   end
  1201.   #--------------------------------------------------------------------------
  1202.   # * Get Weapon Bonus Colour
  1203.   #--------------------------------------------------------------------------
  1204.   def get_weapon_bonus_colour( bonus, wType )
  1205.     if @actor.equips[0] && @actor.equips[0].wtype_id == wType || @actor.equips[1] && @actor.equips[1].is_a?(RPG::Weapon) && @actor.equips[1].wtype_id == wType
  1206.       return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][12])
  1207.     end
  1208.     return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][11]) if bonus > 0
  1209.     return Color.new(*WeaponStatusMenuInfo[:weapon_level_colour][10])
  1210.   end
  1211. end
  1212.  
  1213.  
  1214.  
  1215.  
  1216.  
  1217. #==============================================================================
  1218. # ** Scene_WeaponLevelStatus
  1219. #------------------------------------------------------------------------------
  1220. #  This class performs the WeaponLevelStatus screen processing.
  1221. #==============================================================================
  1222.  
  1223. class Scene_WeaponLevelStatus < Scene_MenuBase
  1224.   #--------------------------------------------------------------------------
  1225.   # * Start Processing
  1226.   #--------------------------------------------------------------------------
  1227.   def start
  1228.     super
  1229.     @status_window = Window_WeaponLevelStatus.new(@actor)
  1230.     @status_window.set_handler(:cancel,   method(:return_scene))
  1231.     @status_window.set_handler(:pagedown, method(:next_actor))
  1232.     @status_window.set_handler(:pageup,   method(:prev_actor))
  1233.   end
  1234.   #--------------------------------------------------------------------------
  1235.   # * Change Actors
  1236.   #--------------------------------------------------------------------------
  1237.   def on_actor_change
  1238.     @status_window.actor = @actor
  1239.     @status_window.activate
  1240.   end
  1241. end
  1242.  
  1243.  
  1244.  
  1245.  
  1246.  
  1247.  
  1248. #==============================================================================
  1249. # ** Window_MenuCommand
  1250. #------------------------------------------------------------------------------
  1251. #  This command window appears on the menu screen.
  1252. #==============================================================================
  1253.  
  1254. class Window_MenuCommand < Window_Command
  1255.   #--------------------------------------------------------------------------
  1256.   # * For Adding Original Commands
  1257.   #--------------------------------------------------------------------------
  1258.   alias dp3_weaplev_winmenucommand_addorigcommd_0edku   add_original_commands
  1259.   #--------------------------------------------------------------------------
  1260.   def add_original_commands
  1261.     add_command(DiamondandPlatinum3::WeaponLevels::Menu_Option_Title, :weapon_level_status_command, main_commands_enabled)
  1262.     dp3_weaplev_winmenucommand_addorigcommd_0edku()
  1263.   end
  1264. end
  1265.  
  1266.  
  1267.  
  1268.  
  1269.  
  1270.  
  1271.  
  1272. #==============================================================================
  1273. # ** Window_EquipStatus
  1274. #------------------------------------------------------------------------------
  1275. #  This window displays actor parameter changes on the equipment screen.
  1276. #==============================================================================
  1277.  
  1278. class Window_EquipStatus < Window_Base
  1279.   #--------------------------------------------------------------------------
  1280.   # * Alias Listings
  1281.   #--------------------------------------------------------------------------
  1282.   alias dp3_weaplev_windowequipstatus_initialize_0edku            initialize
  1283.   alias dp3_weaplev_windowequipstatus_drawnewparam_0edku          draw_new_param
  1284.   #--------------------------------------------------------------------------
  1285.   # * Object Initialization
  1286.   #--------------------------------------------------------------------------
  1287.   def initialize(x, y)
  1288.     @dp3_slot_id = 0
  1289.     dp3_weaplev_windowequipstatus_initialize_0edku(x, y) # Call Original Method
  1290.   end
  1291.   #--------------------------------------------------------------------------
  1292.   # * Draw Post-Equipment Change Parameter
  1293.   #--------------------------------------------------------------------------
  1294.   def draw_new_param(x, y, param_id)
  1295.     bool1 = @temp_actor && @temp_actor.equips[@dp3_slot_id].is_a?(RPG::Weapon)
  1296.     bool2 = param_id > 1 && param_id < 7
  1297.     if bool1 && bool2
  1298.       # Get Weapon Types
  1299.       wType  = @actor.equips[@dp3_slot_id] && @actor.equips[@dp3_slot_id].is_a?(RPG::Weapon) ? @actor.equips[@dp3_slot_id].wtype_id : 0
  1300.       wType2 = @temp_actor.equips[@dp3_slot_id].wtype_id
  1301.       weapon_bonus_param = 0
  1302.      
  1303.       unless wType2 == wType || wType2 == DiamondandPlatinum3::WeaponLevels::get_opposing_weapon_slot_weapon_type( @actor.id, @dp3_slot_id )
  1304.         # Remove Negative Bonus Param from Temp Actor (AKA Current Actor Equipped Weapon)
  1305.         curr_skill = DiamondandPlatinum3::WeaponLevels::get_current_weapon_level( wType, @actor.id, @actor.dp3_weapon_level[wType - 1] )
  1306.         @temp_actor.dp3_decrement_param(param_id, DiamondandPlatinum3::WeaponLevels::get_bonus_param( wType, @actor.id, param_id - 2, curr_skill ))
  1307.        
  1308.         # Get Bonus Param (AKA New Weapon)
  1309.         curr_skill = DiamondandPlatinum3::WeaponLevels::get_current_weapon_level( wType2, @temp_actor.id, @temp_actor.dp3_weapon_level[wType2 - 1] )
  1310.         weapon_bonus_param = DiamondandPlatinum3::WeaponLevels::get_bonus_param( wType2, @temp_actor.id, param_id - 2, curr_skill )
  1311.       end
  1312.      
  1313.       # Apply Param
  1314.       new_value = (@temp_actor.param(param_id) + weapon_bonus_param)
  1315.       change_color(param_change_color(new_value - @actor.param(param_id)))
  1316.       draw_text(x, y, 32, line_height, new_value, 2)
  1317.      
  1318.     else
  1319.       # Call Original Method
  1320.       dp3_weaplev_windowequipstatus_drawnewparam_0edku(x, y, param_id)
  1321.     end
  1322.   end
  1323.   #--------------------------------------------------------------------------
  1324.   # * Set Slot ID
  1325.   #--------------------------------------------------------------------------
  1326.   def dp3_add_slot_id( slot_id )
  1327.     @dp3_slot_id = slot_id
  1328.   end
  1329.   #--------------------------------------------------------------------------
  1330.   # * Get Temp Actor
  1331.   #--------------------------------------------------------------------------
  1332.   def dp3_get_temp_actor()
  1333.     return @temp_actor
  1334.   end
  1335. end
  1336.  
  1337.  
  1338.  
  1339.  
  1340.  
  1341.  
  1342. #==============================================================================
  1343. # ** Window_EquipItem
  1344. #------------------------------------------------------------------------------
  1345. #  This window displays choices when opting to change equipment on the
  1346. # equipment screen.
  1347. #==============================================================================
  1348.  
  1349. class Window_EquipItem < Window_ItemList
  1350.   #--------------------------------------------------------------------------
  1351.   # * Update Help Text
  1352.   #--------------------------------------------------------------------------
  1353.   alias dp3_weaplev_windowequipitem_updatehelp_0edku   update_help
  1354.   #--------------------------------------------------------------------------
  1355.   def update_help
  1356.     dp3_weaplev_windowequipitem_updatehelp_0edku() # Call Original Method
  1357.     @status_window.dp3_add_slot_id(@slot_id)
  1358.   end
  1359. end
  1360.  
  1361.  
  1362.  
  1363.  
  1364. #==============================================================================
  1365. # ** Window_SkillList
  1366. #------------------------------------------------------------------------------
  1367. #  This window is for displaying a list of available skills on the skill window.
  1368. #==============================================================================
  1369.  
  1370. class Window_SkillList < Window_Selectable
  1371.   #--------------------------------------------------------------------------
  1372.   # * Include in Skill List?
  1373.   #--------------------------------------------------------------------------
  1374.   alias dp3_weaplev_windowskilllist_include_0edku   include?
  1375.   #--------------------------------------------------------------------------
  1376.   def include?(*args)
  1377.     bool = dp3_weaplev_windowskilllist_include_0edku(args[0]) || enable?(args[0])
  1378.     return bool && args[0].stype_id == @stype_id
  1379.   end
  1380. end
  1381.  
  1382.  
  1383.  
  1384.  
  1385. #==============================================================================
  1386. # ** Scene_Menu
  1387. #------------------------------------------------------------------------------
  1388. #  This class performs the menu screen processing.
  1389. #==============================================================================
  1390.  
  1391. class Scene_Menu < Scene_MenuBase
  1392.   #--------------------------------------------------------------------------
  1393.   # * Alias Listings
  1394.   #--------------------------------------------------------------------------
  1395.   alias dp3_weaplev_scenemenu_createcommdwindow_0edku   create_command_window
  1396.   alias dp3_weaplev_scenemenu_onpersonalok_0edku        on_personal_ok
  1397.   #--------------------------------------------------------------------------
  1398.   # * Create Command Window
  1399.   #--------------------------------------------------------------------------
  1400.   def create_command_window
  1401.     dp3_weaplev_scenemenu_createcommdwindow_0edku()
  1402.     @command_window.set_handler(:weapon_level_status_command, method(:command_personal))
  1403.   end
  1404.   #--------------------------------------------------------------------------
  1405.   # * [OK] Personal Command
  1406.   #--------------------------------------------------------------------------
  1407.   def on_personal_ok
  1408.     case @command_window.current_symbol
  1409.     when :weapon_level_status_command
  1410.       SceneManager.call(Scene_WeaponLevelStatus)
  1411.     else
  1412.       dp3_weaplev_scenemenu_onpersonalok_0edku()
  1413.     end
  1414.   end
  1415. end
  1416.  
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425. #==============================================================================
  1426. # ** Game_Interpreter
  1427. #------------------------------------------------------------------------------
  1428. #  An interpreter for executing event commands. This class is used within the
  1429. # Game_Map, Game_Troop, and Game_Event classes.
  1430. #==============================================================================
  1431.  
  1432. class Game_Interpreter
  1433.   #--------------------------------------------------------------------------
  1434.   # * Add Weapon Skill Points
  1435.   #--------------------------------------------------------------------------
  1436.   def add_weapon_skill_points( actor_id, points )
  1437.     return unless actor_id.is_a?(Integer) && points.is_a?(Integer)
  1438.     if actor_id > 0    
  1439.       # Increase Current Weapon(s) points
  1440.       DiamondandPlatinum3::WeaponLevels::increment_weapon_skill_points(actor_id, points)    
  1441.     end
  1442.   end
  1443.   #--------------------------------------------------------------------------
  1444.   # * Add Weapon Skill Points to Specific Weapon Type
  1445.   #--------------------------------------------------------------------------
  1446.   def add_specific_weapon_type_skill_points( actor_id, wType, points )
  1447.     return unless actor_id.is_a?(Integer) && wType.is_a?(Integer) && points.is_a?(Integer)
  1448.     if actor_id > 0 && wType > 0
  1449.       # Increment Points
  1450.       DiamondandPlatinum3::WeaponLevels::increment_specific_weapon_skill_points( actor_id, wType, points )
  1451.     end
  1452.   end
  1453.   #--------------------------------------------------------------------------
  1454.   # * Add Weapon Skill Points to Specific Weapon Type
  1455.   #--------------------------------------------------------------------------
  1456.   def toggle_weapon_level_message_display( on_or_off )
  1457.     DiamondandPlatinum3::WeaponLevels::toggle_weapon_level_message_display( on_or_off )
  1458.   end
  1459. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement