mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-13 17:52:22 +00:00
* initial commit to not show shield when previewing two-hand weapon * revert error made * update to fix all combinations of equipping / trying two-handed weapons * clarify conditional logic * refactor to let avatar check for twoHanded display/hide logic * add case when avatar doesn't have weapon equipped
This commit is contained in:
parent
341f16cc82
commit
2f956252ab
1 changed files with 5 additions and 0 deletions
|
|
@ -187,6 +187,11 @@ export default {
|
|||
hideGear (gearType) {
|
||||
if (gearType === 'weapon') {
|
||||
let equippedWeapon = this.member.items.gear[this.costumeClass][gearType];
|
||||
|
||||
if (!equippedWeapon) {
|
||||
return false;
|
||||
}
|
||||
|
||||
let equippedIsTwoHanded = this.flatGear[equippedWeapon].twoHanded;
|
||||
let hasOverrideShield = this.overrideAvatarGear && this.overrideAvatarGear.shield;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue