mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
[Feature] Loadout&Domains Homebrew (#529)
* Removed ChatTheme from settings * 0 or blank loadoutSize now means unlimited * Added Homebrew maxDomains
This commit is contained in:
parent
2e5337c5c5
commit
ee5c3a9322
14 changed files with 74 additions and 65 deletions
|
|
@ -362,13 +362,12 @@ export default class DhCharacter extends BaseDataActor {
|
|||
|
||||
get loadoutSlot() {
|
||||
const loadoutCount = this.domainCards.loadout?.length ?? 0,
|
||||
max =
|
||||
game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).maxLoadout +
|
||||
this.bonuses.maxLoadout;
|
||||
worldSetting = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).maxLoadout,
|
||||
max = !worldSetting ? null : worldSetting + this.bonuses.maxLoadout;
|
||||
|
||||
return {
|
||||
current: loadoutCount,
|
||||
available: Math.max(max - loadoutCount, 0),
|
||||
available: !max ? true : Math.max(max - loadoutCount, 0),
|
||||
max
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue