Skip to content

Commit

Permalink
Round down max slots in crafting abilities (foundryvtt#17630)
Browse files Browse the repository at this point in the history
CarlosFdez authored Dec 6, 2024
1 parent 019a6c0 commit 77d0301
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/module/rules/rule-element/crafting-ability.ts
Original file line number Diff line number Diff line change
@@ -82,7 +82,7 @@ class CraftingAbilityRuleElement extends RuleElementPF2e<CraftingAbilityRuleSche

const slug = this.resolveInjectedProperties(this.slug);
const key = sluggify(slug, { camel: "dromedary" });
const maxSlots = this.maxSlots !== undefined ? Number(this.resolveValue(this.maxSlots)) : null;
const maxSlots = this.maxSlots !== undefined ? Math.floor(Number(this.resolveValue(this.maxSlots))) : null;
const maxItemLevel = Number(this.resolveValue(this.maxItemLevel));
const existing = this.actor.system.crafting.entries[key];
if (existing) {

0 comments on commit 77d0301

Please sign in to comment.