Dual Wield plugin updated to 2.56
I have updated the main Dual Wield plugin script to version 2.56 with the following changes:
- Documentation rewritten slightly to make it easier to understand how to use some of the more advanced features
- Documentation updated to make it much more obvious to load this plugin after YEP_DamageCore if you are using it.
- Added two new note tags to weapons more info below:
- <Twohanded Attack Modifier></Twohanded Attack Modifier>
- <Offhand Attack Modifier></OffhandAttackModifier>
These new note tags allow a developer to modify the main or offhand attack values directly from specific weapons, meaning you can have weapons that bestow a penalty to attack value if wielded in the offhand (in addition to any % penalty already in effect from the plugin parameters), or an additional bonus for using a two-handed weapon. Both tags can be used at the same time on a weapon, but since you can't put a two handed weapon in your offhand, they should never actually take effect at the same time.
Using the Switchable Two-Handed Weapons extension together with both tags, you can make a katana or bastard sword that had bonuses to weapon attack when being two handed, but when switched to one-handed mode and put in the offhand deals substantially less damage.
Usage example:
<Twohanded Attack Modifier> value = 12 </Twohanded Attack Modifier>
The above tag will make a weapon being two-handed 12 attack stronger. This value is only applied if the weapon is being two-handed. Note that if you have a light shield in your offhand, the weapon is still considered two-handed.
<Offhand Attack Modifier> value = -5 </Offhand Attack Modifier>
This tag will reduce the offhand attack value by 5 if this weapon is being held in the offhand. Note that if you are wielding two of the same weapons, this modifier only applies to the offhand attack value.
You can make these tags quite complex as well.
a or user can be used as the actor equipping the item. You have access to any variables or parameters on that actor for use in the formula.
<Offhand Attack Modifier> if (a.isStateAffected(21)){ value = -5 } else { value = -12 } </Offhand Attack Modifier>
This example tag reduces the penalty on the weapon if the actor is affected by a state, perhaps an ambidexterity talent makes the weapon more effective in a more skilled offhand?
s and v can be used to reference game switches and variables as well:
<Twohanded Attack Modifier> if (s[14]){ value = 20 } else { value = 0 } </Twohanded Attack Modifier>
The above example disables the two-handed bonus on this weapon unless switch 14 is on.
<Offhand Attack Modifier> value = v[12] </Offhand Attack Modifier>
The above example gives a bonus/penalty to the offhand weapon equal to the value of variable 12.
You can also use the 'item' object to reference the weapon itself. In projects where weapons are unique, and may not always have the same exact parameters, modifying their attack value by a flat number might become unbalancing.
<Twohanded Attack Modifier> value = item.params[2] * 0.75 value = Math.round(value) </Twohanded Attack Modifier>
The above will add an extra 75% of the attack value already on a weapon as a bonus when two-handing the weapon. We use a round value to insure that we don't get any wonky attack values by using a decimal value like that.
That's all for today, and special thanks to @SirCumferance for the suggestion.
Files
Get MV - Dual Wield
MV - Dual Wield
Bring proper dual wielding support to RMMV
Status | Released |
Category | Tool |
Author | Ramza |
Tags | javascript-plugin, RPG Maker |
More posts
- Version 2.74 Minor UpdateNov 28, 2022
- Version 2.73 BugfixJul 16, 2022
- Version 2.73 UpdateFeb 22, 2022
- Version 2.71 Minor BugfixDec 26, 2021
- Version 1.70 Update + Menu Extension v1.42Oct 19, 2021
- Version 2.69 Minor bugfixOct 26, 2020
- Menu Extension v1.41Sep 26, 2020
- Dual Wield MZ is released!Aug 23, 2020
- Version 2.68 releaseApr 29, 2020
- Menu Extension v1.40Apr 26, 2020
Leave a comment
Log in with itch.io to leave a comment.