Class Feature Modify

Class Feature Modify 1.02
by Roninator2​

Introduction
Allows you to specify if features are to be given to a specific class or remove database features for specific classes.

Features
- Use note tags to specify what classes would not get any of the feature bonuses (block feature)
- Use note tags to specify what classes get bonus features (add features)
- If you block and allow bonuses to the same class, only Params are applied.
Sparams (e.g. PDR) and Xparams (e.g. HIT) are not.
Updated

How to Use
Insert below materials and above main
<class restrict: 1, 4, 5, 8>
Classes 1, 4, 5, & 8 will not get any of the features that have been added to the Weapon or Armour

Code:
<class bonus: 2, 5> Bonus will apply to class 2 & 5
:MHP 100   # increase max hp by 100
:ATK 5     # increase attack by 5
:HRG 15    # increase health regeneration by 15%
:PDR -10   # decrease physical damage rate by 10%
</class bonus>

Images
Spoiler: Images
Default
1645129496874.png


Equipped
1645129562741.png


Armour
1645129653542.png

Script
Spoiler: script

Credit and Thanks
- Roninator2

Terms of use
Follow the original Authors terms of use where applicable
- When not made by me (Roninator2)
Free for all uses in RPG Maker except nudity
Anyone using this script in their project before these terms
were changed are allowed to use this script even if it conflicts
with these new terms. New terms effective 03 Apr 2024
No part of this code can be used with AI programs or tools
Credit must be given
Hey Ron, thanks for the great script!

I've been testing the "Class Feature Modify" script on a blank project and am having a bit of trouble getting this to work properly for some things. Maybe I'm doing something wrong.


1. A weapon/armor with a class bonus for only PARAM works great with no issues, awesome! Example:

<class bonus: 2, 5>
:MHP 50
:ATK 5
</class bonus>

2. A weapon/armor with a class bonus for only XPARAM gives me an error immediately when I try to equip the weapon/armor.

Error:
Script 'Class Feature Modify' line 179: NoMethodError occured. undefined method 'added_features='for #<RPG::Weapon:0x824d5a8>

Example:

<class bonus: 2, 5>
:HIT 5
:EVA 5
</class bonus>

I can get the error message to go away if I put the "Block all features on class" script below the "Class Feature Modify" script, but this doesn't seem to apply the bonuses.

Putting the "Block all features on class" script on top of the "Class Feature Modify" script gives me the same error as above when I try to equip the weapon/armor.


3. A weapon/armor with a class bonus for only SPARAM gives me an error immediately when I try to equip the weapon/armor.

Error: Script 'Class Feature Modify' line 193: NoMethodError occured. undefined method 'added_features='for #<RPG::Weapon:0x824abf0>

Example:

<class bonus: 2, 5>
:TGR 5
</class bonus>
gives me an error immediately
Apologies. I seem to have uploaded an old file.
I updated the post to have the correct script.
Please try again.
Thanks Ron, the update fixed everything. 👍

Original thread: https://forums.rpgmakerweb.com/threads/class-feature-modify.145034/