Changed so that equip attempts always go through and the neccessary weapons are unequipped to fascilitate it

This commit is contained in:
WBHarry 2025-05-25 21:14:08 +02:00
parent 8e92b5f6d9
commit 9962c05a20
2 changed files with 3 additions and 11 deletions

View file

@ -94,9 +94,7 @@
"LacksDomain": "Your character doesn't have the domain of the card!",
"MaxLoadoutReached": "You can't have any more domain cards at this level!",
"DuplicateDomainCard": "You already have a domain card with that name!",
"ActionRequiresTarget": "The action requires at least one target",
"TwoHandedWeaponEquipped": "You have a two-handed weapon equipped",
"SecondaryWeaponEquipped": "You have a secondary weapon equipped"
"ActionRequiresTarget": "The action requires at least one target"
}
},
"General": {

View file

@ -958,10 +958,7 @@ export default class PCSheet extends DaggerheartSheet(ActorSheetV2) {
currentWeapons.primary &&
currentWeapons.primary.burden === SYSTEM.GENERAL.burden.twoHanded.value
) {
ui.notifications.error(
game.i18n.localize('DAGGERHEART.Notification.Error.TwoHandedWeaponEquipped')
);
return;
await this.document.items.get(currentWeapons.primary.id).update({ 'system.equipped': false });
}
if (currentWeapons.secondary) {
@ -969,10 +966,7 @@ export default class PCSheet extends DaggerheartSheet(ActorSheetV2) {
}
} else {
if (currentWeapons.secondary && item.system.burden === SYSTEM.GENERAL.burden.twoHanded.value) {
ui.notifications.error(
game.i18n.localize('DAGGERHEART.Notification.Error.SecondaryWeaponEquipped')
);
return;
await this.document.items.get(currentWeapons.secondary.id).update({ 'system.equipped': false });
}
if (currentWeapons.primary) {