mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-15 21:21:08 +01:00
Merged with main
This commit is contained in:
commit
ed5c8bc826
36 changed files with 1117 additions and 835 deletions
|
|
@ -5,13 +5,13 @@ import * as documents from './module/documents/_module.mjs';
|
||||||
import RegisterHandlebarsHelpers from './module/helpers/handlebarsHelper.mjs';
|
import RegisterHandlebarsHelpers from './module/helpers/handlebarsHelper.mjs';
|
||||||
import DhpCombatTracker from './module/ui/combatTracker.mjs';
|
import DhpCombatTracker from './module/ui/combatTracker.mjs';
|
||||||
import { GMUpdateEvent, handleSocketEvent, socketEvent } from './module/helpers/socket.mjs';
|
import { GMUpdateEvent, handleSocketEvent, socketEvent } from './module/helpers/socket.mjs';
|
||||||
import { registerDHPSettings } from './module/applications/settings.mjs';
|
import { registerDHSettings } from './module/applications/settings.mjs';
|
||||||
import DhpChatLog from './module/ui/chatLog.mjs';
|
import DhpChatLog from './module/ui/chatLog.mjs';
|
||||||
import DhpPlayers from './module/ui/players.mjs';
|
import DhpPlayers from './module/ui/players.mjs';
|
||||||
import DhpRuler from './module/ui/ruler.mjs';
|
import DhpRuler from './module/ui/ruler.mjs';
|
||||||
import DhpTokenRuler from './module/ui/tokenRuler.mjs';
|
import DhpTokenRuler from './module/ui/tokenRuler.mjs';
|
||||||
import { dualityRollEnricher, getDualityMessage } from './module/enrichers/DualityRollEnricher.mjs';
|
import { dualityRollEnricher } from './module/enrichers/DualityRollEnricher.mjs';
|
||||||
import { getCommandTarget, rollCommandToJSON } from './module/helpers/utils.mjs';
|
import { getCommandTarget, rollCommandToJSON, setDiceSoNiceForDualityRoll } from './module/helpers/utils.mjs';
|
||||||
import { abilities } from './module/config/actorConfig.mjs';
|
import { abilities } from './module/config/actorConfig.mjs';
|
||||||
|
|
||||||
globalThis.SYSTEM = SYSTEM;
|
globalThis.SYSTEM = SYSTEM;
|
||||||
|
|
@ -97,7 +97,7 @@ Hooks.once('init', () => {
|
||||||
|
|
||||||
game.socket.on(`system.${SYSTEM.id}`, handleSocketEvent);
|
game.socket.on(`system.${SYSTEM.id}`, handleSocketEvent);
|
||||||
|
|
||||||
registerDHPSettings();
|
registerDHSettings();
|
||||||
RegisterHandlebarsHelpers.registerHelpers();
|
RegisterHandlebarsHelpers.registerHelpers();
|
||||||
|
|
||||||
return preloadHandlebarsTemplates();
|
return preloadHandlebarsTemplates();
|
||||||
|
|
@ -213,12 +213,19 @@ Hooks.on('chatMessage', (_, message) => {
|
||||||
const attributeRoll = `${attribute?.data?.value ? `${attribute.data.value > 0 ? `+${attribute.data.value}` : `${attribute.data.value}`}` : ''}`;
|
const attributeRoll = `${attribute?.data?.value ? `${attribute.data.value > 0 ? `+${attribute.data.value}` : `${attribute.data.value}`}` : ''}`;
|
||||||
const roll = new Roll(`${hopeAndFearRoll}${advantageRoll}${attributeRoll}`);
|
const roll = new Roll(`${hopeAndFearRoll}${advantageRoll}${attributeRoll}`);
|
||||||
await roll.evaluate();
|
await roll.evaluate();
|
||||||
|
|
||||||
|
setDiceSoNiceForDualityRoll(
|
||||||
|
roll,
|
||||||
|
rollCommand.advantage && !rollCommand.disadvantage,
|
||||||
|
rollCommand.disadvantage && !rollCommand.advantage
|
||||||
|
);
|
||||||
|
|
||||||
resolve({
|
resolve({
|
||||||
roll,
|
roll,
|
||||||
attribute: attribute
|
attribute: attribute
|
||||||
? {
|
? {
|
||||||
value: attribute.data.value,
|
value: attribute.data.value,
|
||||||
label: `${game.i18n.localize(abilities[attributeValue].label)} ${attribute.data.value >= 0 ? `+` : `-`}${attribute.data.value}`
|
label: `${game.i18n.localize(abilities[attributeValue].label)} ${attribute.data.value >= 0 ? `+` : ``}${attribute.data.value}`
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
title
|
title
|
||||||
|
|
|
||||||
154
lang/en.json
154
lang/en.json
|
|
@ -46,6 +46,21 @@
|
||||||
"CloseLabel": "Close",
|
"CloseLabel": "Close",
|
||||||
"FarLabel": "Far",
|
"FarLabel": "Far",
|
||||||
"VeryFarLabel": "Very Far"
|
"VeryFarLabel": "Very Far"
|
||||||
|
},
|
||||||
|
"Appearance": {
|
||||||
|
"title": "Appearance Settings",
|
||||||
|
"label": "Appearance Settings",
|
||||||
|
"hint": "Modify the look of various parts of the system",
|
||||||
|
"name": "Appearance Settings",
|
||||||
|
"duality": "Duality Rolls",
|
||||||
|
"DiceSoNice": {
|
||||||
|
"title": "Dice So Nice",
|
||||||
|
"hint": "Coloration of Hope and Fear dice if the Dice So Nice module is used.",
|
||||||
|
"foreground": "Foreground",
|
||||||
|
"background": "Background",
|
||||||
|
"outline": "Outline",
|
||||||
|
"edge": "Edge"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Automation": {
|
"Automation": {
|
||||||
|
|
@ -139,52 +154,58 @@
|
||||||
"Reaction": "Reaction"
|
"Reaction": "Reaction"
|
||||||
},
|
},
|
||||||
"Abilities": {
|
"Abilities": {
|
||||||
"Agility": {
|
"agility": {
|
||||||
"Name": "Agility",
|
"name": "Agility",
|
||||||
"Verb": {
|
"short": "AGI",
|
||||||
"Sprint": "Sprint",
|
"verb": {
|
||||||
"Leap": "Leap",
|
"sprint": "Sprint",
|
||||||
"Maneuver": "Maneuver"
|
"leap": "Leap",
|
||||||
|
"maneuver": "Maneuver"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Strength": {
|
"strength": {
|
||||||
"Name": "Strength",
|
"name": "Strength",
|
||||||
"Verb": {
|
"short": "STR",
|
||||||
"Lift": "Lift",
|
"verb": {
|
||||||
"Smash": "Smash",
|
"lift": "Lift",
|
||||||
"Grapple": "Grapple"
|
"smash": "Smash",
|
||||||
|
"grapple": "Grapple"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Finesse": {
|
"finesse": {
|
||||||
"Name": "Finesse",
|
"name": "Finesse",
|
||||||
"Verb": {
|
"short": "FIN",
|
||||||
"Control": "Control",
|
"verb": {
|
||||||
"Hide": "Hide",
|
"control": "Control",
|
||||||
"Tinker": "Tinker"
|
"hide": "Hide",
|
||||||
|
"tinker": "Tinker"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Instinct": {
|
"instinct": {
|
||||||
"Name": "Instinct",
|
"name": "Instinct",
|
||||||
"Verb": {
|
"short": "INS",
|
||||||
"Perceive": "Perceive",
|
"verb": {
|
||||||
"Sense": "Sense",
|
"perceive": "Perceive",
|
||||||
"Navigate": "Navigate"
|
"sense": "Sense",
|
||||||
|
"navigate": "Navigate"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Presence": {
|
"presence": {
|
||||||
"Name": "Presence",
|
"name": "Presence",
|
||||||
"Verb": {
|
"short": "PRE",
|
||||||
"Charm": "Charm",
|
"verb": {
|
||||||
"Perform": "Perform",
|
"charm": "Charm",
|
||||||
"Deceive": "Deceive"
|
"perform": "Perform",
|
||||||
|
"deceive": "Deceive"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Knowledge": {
|
"knowledge": {
|
||||||
"Name": "Knowledge",
|
"name": "Knowledge",
|
||||||
"Verb": {
|
"short": "KNO",
|
||||||
"Recall": "Recall",
|
"verb": {
|
||||||
"Analyze": "Analyze",
|
"recall": "Recall",
|
||||||
"Comprehend": "Comprehend"
|
"analyze": "Analyze",
|
||||||
|
"comprehend": "Comprehend"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -383,39 +404,39 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Burden": {
|
"Burden": {
|
||||||
"OneHanded": "One-Handed",
|
"oneHanded": "One-Handed",
|
||||||
"TwoHanded": "Two-Handed"
|
"twoHanded": "Two-Handed"
|
||||||
},
|
},
|
||||||
"Range": {
|
"Range": {
|
||||||
"Melee": {
|
"melee": {
|
||||||
"Name": "Melee",
|
"name": "Melee",
|
||||||
"Description": "means a character is within touching distance of the target. PCs can generally touch targets up to a few feet away from them, but melee range may be greater for especially large NPCs."
|
"description": "means a character is within touching distance of the target. PCs can generally touch targets up to a few feet away from them, but melee range may be greater for especially large NPCs."
|
||||||
},
|
},
|
||||||
"VeryClose": {
|
"veryClose": {
|
||||||
"Name": "Very Close",
|
"name": "Very Close",
|
||||||
"Description": "means a distance where one can see fine details of a target- within moments of reaching, if need be. This is usually anywhere from about 5-10 feet away. While in danger, a PC can usually get to anything that’s very close as part of any other action they take. Anything on a battle map that is within the shortest length of a game card (~2-3 inches) can usually be considered very close."
|
"description": "means a distance where one can see fine details of a target- within moments of reaching, if need be. This is usually anywhere from about 5-10 feet away. While in danger, a PC can usually get to anything that’s very close as part of any other action they take. Anything on a battle map that is within the shortest length of a game card (~2-3 inches) can usually be considered very close."
|
||||||
},
|
},
|
||||||
"Close": {
|
"close": {
|
||||||
"Name": "Close",
|
"name": "Close",
|
||||||
"Description": "means a distance where one can see prominent details of a target-- across a room or to a neighboring market stall, generally about 10-30 feet away. While in danger, a PC can usually get to anything that’s close as part of any other action they take. Anything on a battle map that is within the length of a standard pen or pencil (~5-6 inches) can usually be considered close."
|
"description": "means a distance where one can see prominent details of a target-- across a room or to a neighboring market stall, generally about 10-30 feet away. While in danger, a PC can usually get to anything that’s close as part of any other action they take. Anything on a battle map that is within the length of a standard pen or pencil (~5-6 inches) can usually be considered close."
|
||||||
},
|
},
|
||||||
"Far": {
|
"far": {
|
||||||
"Name": "Far",
|
"name": "Far",
|
||||||
"Description": "means a distance where one can see the appearance of a person or object, but probably not in great detail-- across a small battlefield or down a large corridor. This is usually about 30-100 feet away. While under danger, a PC will likely have to make an Agility check to get here safely. Anything on a battle map that is within the length of a standard piece of paper (~10-11 inches) can usually be considered far."
|
"description": "means a distance where one can see the appearance of a person or object, but probably not in great detail-- across a small battlefield or down a large corridor. This is usually about 30-100 feet away. While under danger, a PC will likely have to make an Agility check to get here safely. Anything on a battle map that is within the length of a standard piece of paper (~10-11 inches) can usually be considered far."
|
||||||
},
|
},
|
||||||
"VeryFar": {
|
"veryFar": {
|
||||||
"Name": "Very Far",
|
"name": "Very Far",
|
||||||
"Description": "means a distance where you can see the shape of a person or object, but probably not make outany details-- across a large battlefield or down a long street, generally about 100-300 feet away. While under danger, a PC likely has to make an Agility check to get here safely. Anything on a battle map that is beyond far distance, but still within sight of the characters can usually be considered very far."
|
"description": "means a distance where you can see the shape of a person or object, but probably not make outany details-- across a large battlefield or down a long street, generally about 100-300 feet away. While under danger, a PC likely has to make an Agility check to get here safely. Anything on a battle map that is beyond far distance, but still within sight of the characters can usually be considered very far."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"DamageType": {
|
"DamageType": {
|
||||||
"Physical": {
|
"physical": {
|
||||||
"Name": "Physical",
|
"name": "Physical",
|
||||||
"Abbreviation": "Phy"
|
"abbreviation": "Phy"
|
||||||
},
|
},
|
||||||
"Magical": {
|
"magical": {
|
||||||
"Name": "Magical",
|
"name": "Magical",
|
||||||
"Abbreviation": "Mag"
|
"abbreviation": "Mag"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"HealingType": {
|
"HealingType": {
|
||||||
|
|
@ -923,13 +944,13 @@
|
||||||
"NewFeature": "New Feature"
|
"NewFeature": "New Feature"
|
||||||
},
|
},
|
||||||
"Armor": {
|
"Armor": {
|
||||||
"BaseScore": "Base Score",
|
"baseScore": "Base Score",
|
||||||
"Feature": "Feature",
|
"feature": "Feature",
|
||||||
"Description": "Description",
|
"description": "Description",
|
||||||
"BaseThresholds": {
|
"baseThresholds": {
|
||||||
"Base": "Base Thresholds",
|
"base": "Base Thresholds",
|
||||||
"Major": "Major Threshold",
|
"major": "Major Threshold",
|
||||||
"Severe": "Severe Threshold"
|
"severe": "Severe Threshold"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Class": {
|
"Class": {
|
||||||
|
|
@ -1051,6 +1072,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Weapon": {
|
"Weapon": {
|
||||||
|
"PrimaryWeapon": "Primary Weapon",
|
||||||
"SecondaryWeapon": "Secondary Weapon",
|
"SecondaryWeapon": "Secondary Weapon",
|
||||||
"Trait": "Trait",
|
"Trait": "Trait",
|
||||||
"Range": "Range",
|
"Range": "Range",
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ export { default as DhpAncestry } from './sheets/ancestry.mjs';
|
||||||
export { default as DhpCommunity } from './sheets/community.mjs';
|
export { default as DhpCommunity } from './sheets/community.mjs';
|
||||||
export { default as DhpMiscellaneous } from './sheets/items/miscellaneous.mjs';
|
export { default as DhpMiscellaneous } from './sheets/items/miscellaneous.mjs';
|
||||||
export { default as DhpConsumable } from './sheets/items/consumable.mjs';
|
export { default as DhpConsumable } from './sheets/items/consumable.mjs';
|
||||||
export { default as DhpWeapon } from './sheets/weapon.mjs';
|
export { default as DhpWeapon } from './sheets/items/weapon.mjs';
|
||||||
export { default as DhpArmor } from './sheets/armor.mjs';
|
export { default as DhpArmor } from './sheets/items/armor.mjs';
|
||||||
export { default as DhpChatMessage } from './chatMessage.mjs';
|
export { default as DhpChatMessage } from './chatMessage.mjs';
|
||||||
export { default as DhpEnvironment } from './sheets/environment.mjs';
|
export { default as DhpEnvironment } from './sheets/environment.mjs';
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { DualityRollColor } from '../config/settingsConfig.mjs';
|
|
||||||
import DhpDualityRoll from '../data/dualityRoll.mjs';
|
import DhpDualityRoll from '../data/dualityRoll.mjs';
|
||||||
|
import { DualityRollColor } from '../data/settings/Appearance.mjs';
|
||||||
|
|
||||||
export default class DhpChatMesssage extends ChatMessage {
|
export default class DhpChatMesssage extends ChatMessage {
|
||||||
async renderHTML() {
|
async renderHTML() {
|
||||||
|
|
@ -16,7 +16,7 @@ export default class DhpChatMesssage extends ChatMessage {
|
||||||
const html = await super.renderHTML();
|
const html = await super.renderHTML();
|
||||||
if (
|
if (
|
||||||
this.type === 'dualityRoll' &&
|
this.type === 'dualityRoll' &&
|
||||||
game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.DualityRollColor) ===
|
game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance).dualityColorScheme ===
|
||||||
DualityRollColor.colorful.value
|
DualityRollColor.colorful.value
|
||||||
) {
|
) {
|
||||||
html.classList.add('duality');
|
html.classList.add('duality');
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,9 @@ export default class DaggerheartActionConfig extends DaggerheartSheet(Applicatio
|
||||||
}
|
}
|
||||||
|
|
||||||
static async updateForm(event, _, formData) {
|
static async updateForm(event, _, formData) {
|
||||||
const data = foundry.utils.expandObject(foundry.utils.mergeObject(this.action.toObject(), formData.object));
|
const data = foundry.utils.expandObject(
|
||||||
|
foundry.utils.mergeObject(this.action.toObject(), foundry.utils.expandObject(formData.object))
|
||||||
|
);
|
||||||
const newActions = this.action.parent.actions.map(x => x.toObject());
|
const newActions = this.action.parent.actions.map(x => x.toObject());
|
||||||
if (!newActions.findSplice(x => x.id === data.id, data)) {
|
if (!newActions.findSplice(x => x.id === data.id, data)) {
|
||||||
newActions.push(data);
|
newActions.push(data);
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
import { DualityRollColor } from '../config/settingsConfig.mjs';
|
import { DualityRollColor } from '../config/settingsConfig.mjs';
|
||||||
import { defaultLevelTiers, DhLevelTiers } from '../data/levelTier.mjs';
|
import { defaultLevelTiers, DhLevelTiers } from '../data/levelTier.mjs';
|
||||||
|
import DhAppearance from '../data/settings/Appearance.mjs';
|
||||||
|
import DHAppearanceSettings from './settings/appearanceSettings.mjs';
|
||||||
|
|
||||||
class DhpAutomationSettings extends FormApplication {
|
class DhpAutomationSettings extends FormApplication {
|
||||||
constructor(object = {}, options = {}) {
|
constructor(object = {}, options = {}) {
|
||||||
|
|
@ -161,7 +163,7 @@ class DhpRangeSettings extends FormApplication {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export const registerDHPSettings = () => {
|
export const registerDHSettings = () => {
|
||||||
// const debouncedReload = foundry.utils.debounce(() => window.location.reload(), 100);
|
// const debouncedReload = foundry.utils.debounce(() => window.location.reload(), 100);
|
||||||
|
|
||||||
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.General.AbilityArray, {
|
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.General.AbilityArray, {
|
||||||
|
|
@ -216,14 +218,11 @@ export const registerDHPSettings = () => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.DualityRollColor, {
|
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance, {
|
||||||
name: game.i18n.localize('DAGGERHEART.Settings.DualityRollColor.Name'),
|
scope: 'client',
|
||||||
hint: game.i18n.localize('DAGGERHEART.Settings.DualityRollColor.Hint'),
|
config: false,
|
||||||
scope: 'world',
|
type: DhAppearance,
|
||||||
config: true,
|
default: DhAppearance.defaultSchema
|
||||||
type: Number,
|
|
||||||
choices: Object.values(DualityRollColor),
|
|
||||||
default: DualityRollColor.colorful.value
|
|
||||||
});
|
});
|
||||||
|
|
||||||
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.DualityRollColor, {
|
game.settings.register(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.DualityRollColor, {
|
||||||
|
|
@ -267,53 +266,13 @@ export const registerDHPSettings = () => {
|
||||||
type: DhpRangeSettings,
|
type: DhpRangeSettings,
|
||||||
restricted: true
|
restricted: true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
game.settings.registerMenu(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance, {
|
||||||
|
name: game.i18n.localize('DAGGERHEART.Settings.Menu.Appearance.title'),
|
||||||
|
label: game.i18n.localize('DAGGERHEART.Settings.Menu.Appearance.label'),
|
||||||
|
hint: game.i18n.localize('DAGGERHEART.Settings.Menu.Appearance.hint'),
|
||||||
|
icon: 'fa-solid fa-palette',
|
||||||
|
type: DHAppearanceSettings,
|
||||||
|
restricted: false
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// const {HandlebarsApplicationMixin, ApplicationV2} = foundry.applications.api;
|
|
||||||
|
|
||||||
// export default class DhpSettings extends HandlebarsApplicationMixin(ApplicationV2) {
|
|
||||||
// constructor(actor, shortrest){
|
|
||||||
// super({});
|
|
||||||
|
|
||||||
// this.actor = actor;
|
|
||||||
// this.selectedActivity = null;
|
|
||||||
// this.shortrest = shortrest;
|
|
||||||
|
|
||||||
// this.customActivity = SYSTEM.GENERAL.downtime.custom;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// get title(){
|
|
||||||
// return game.i18n.localize("DAGGERHEART.Application.Settings.Title");
|
|
||||||
// }
|
|
||||||
|
|
||||||
// static DEFAULT_OPTIONS = {
|
|
||||||
// tag: 'form',
|
|
||||||
// classes: ["daggerheart", "application", "settings"],
|
|
||||||
// position: { width: 800, height: 'auto' },
|
|
||||||
// actions: {
|
|
||||||
// selectActivity: this.selectActivity,
|
|
||||||
// },
|
|
||||||
// form: { handler: this.updateData }
|
|
||||||
// };
|
|
||||||
|
|
||||||
// static PARTS = {
|
|
||||||
// application: {
|
|
||||||
// id: "settings",
|
|
||||||
// template: "systems/daggerheart/templates/application/settings.hbs"
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
// async _prepareContext(_options) {
|
|
||||||
// const context = await super._prepareContext(_options);
|
|
||||||
|
|
||||||
// return context;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// static async updateData(event, element, formData){
|
|
||||||
// this.render();
|
|
||||||
// }
|
|
||||||
|
|
||||||
// static close(){
|
|
||||||
// super.close();
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
|
||||||
59
module/applications/settings/appearanceSettings.mjs
Normal file
59
module/applications/settings/appearanceSettings.mjs
Normal file
|
|
@ -0,0 +1,59 @@
|
||||||
|
import DhAppearance from '../../data/settings/Appearance.mjs';
|
||||||
|
|
||||||
|
const { HandlebarsApplicationMixin, ApplicationV2 } = foundry.applications.api;
|
||||||
|
|
||||||
|
export default class DHAppearanceSettings extends HandlebarsApplicationMixin(ApplicationV2) {
|
||||||
|
constructor() {
|
||||||
|
super({});
|
||||||
|
|
||||||
|
this.settings = new DhAppearance(
|
||||||
|
game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance).toObject()
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
get title() {
|
||||||
|
return game.i18n.localize('DAGGERHEART.Settings.Menu.Appearance.name');
|
||||||
|
}
|
||||||
|
|
||||||
|
static DEFAULT_OPTIONS = {
|
||||||
|
tag: 'form',
|
||||||
|
id: 'daggerheart-appearance-settings',
|
||||||
|
classes: ['daggerheart', 'setting', 'dh-style'],
|
||||||
|
position: { width: '600', height: 'auto' },
|
||||||
|
actions: {
|
||||||
|
reset: this.reset,
|
||||||
|
save: this.save
|
||||||
|
},
|
||||||
|
form: { handler: this.updateData, submitOnChange: true }
|
||||||
|
};
|
||||||
|
|
||||||
|
static PARTS = {
|
||||||
|
main: {
|
||||||
|
template: 'systems/daggerheart/templates/settings/appearance-settings.hbs'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
async _prepareContext(_options) {
|
||||||
|
const context = await super._prepareContext(_options);
|
||||||
|
context.settingFields = this.settings;
|
||||||
|
|
||||||
|
return context;
|
||||||
|
}
|
||||||
|
|
||||||
|
static async updateData(event, element, formData) {
|
||||||
|
const updatedSettings = foundry.utils.expandObject(formData.object);
|
||||||
|
|
||||||
|
await this.settings.updateSource(updatedSettings);
|
||||||
|
this.render();
|
||||||
|
}
|
||||||
|
|
||||||
|
static async reset() {
|
||||||
|
this.settings = new DhAppearance();
|
||||||
|
this.render();
|
||||||
|
}
|
||||||
|
|
||||||
|
static async save() {
|
||||||
|
await game.settings.set(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance, this.settings.toObject());
|
||||||
|
this.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,63 +0,0 @@
|
||||||
// import DhpApplicationMixin from '../daggerheart-sheet.mjs';
|
|
||||||
|
|
||||||
// export default class ArmorSheet extends DhpApplicationMixin(ItemSheet) {
|
|
||||||
// static documentType = "armor";
|
|
||||||
|
|
||||||
// /** @override */
|
|
||||||
// static get defaultOptions() {
|
|
||||||
// return foundry.utils.mergeObject(super.defaultOptions, {
|
|
||||||
// classes: ["daggerheart", "sheet", "armor"],
|
|
||||||
// width: 400,
|
|
||||||
// height: 'auto',
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
|
|
||||||
// /** @override */
|
|
||||||
// getData() {
|
|
||||||
// const context = super.getData();
|
|
||||||
// context.config = CONFIG.daggerheart;
|
|
||||||
|
|
||||||
// return context;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// async _handleAction(action, event, button) {
|
|
||||||
// switch(action){
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
import DaggerheartSheet from './daggerheart-sheet.mjs';
|
|
||||||
|
|
||||||
const { ItemSheetV2 } = foundry.applications.sheets;
|
|
||||||
export default class ArmorSheet extends DaggerheartSheet(ItemSheetV2) {
|
|
||||||
static DEFAULT_OPTIONS = {
|
|
||||||
tag: 'form',
|
|
||||||
classes: ['daggerheart', 'sheet', 'armor'],
|
|
||||||
position: { width: 400 },
|
|
||||||
form: {
|
|
||||||
handler: this.updateForm,
|
|
||||||
submitOnChange: true,
|
|
||||||
closeOnSubmit: false
|
|
||||||
},
|
|
||||||
dragDrop: [{ dragSelector: null, dropSelector: null }]
|
|
||||||
};
|
|
||||||
|
|
||||||
static PARTS = {
|
|
||||||
form: {
|
|
||||||
id: 'feature',
|
|
||||||
template: 'systems/daggerheart/templates/sheets/armor.hbs'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
async _prepareContext(_options) {
|
|
||||||
const context = await super._prepareContext(_options);
|
|
||||||
context.document = this.document;
|
|
||||||
context.config = CONFIG.daggerheart;
|
|
||||||
|
|
||||||
return context;
|
|
||||||
}
|
|
||||||
|
|
||||||
static async updateForm(event, _, formData) {
|
|
||||||
await this.document.update(formData.object);
|
|
||||||
this.render();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
59
module/applications/sheets/items/armor.mjs
Normal file
59
module/applications/sheets/items/armor.mjs
Normal file
|
|
@ -0,0 +1,59 @@
|
||||||
|
import DaggerheartSheet from '../daggerheart-sheet.mjs';
|
||||||
|
|
||||||
|
const { ItemSheetV2 } = foundry.applications.sheets;
|
||||||
|
export default class ArmorSheet extends DaggerheartSheet(ItemSheetV2) {
|
||||||
|
static DEFAULT_OPTIONS = {
|
||||||
|
tag: 'form',
|
||||||
|
classes: ['daggerheart', 'sheet', 'dh-style', 'armor'],
|
||||||
|
position: { width: 600 },
|
||||||
|
form: {
|
||||||
|
handler: this.updateForm,
|
||||||
|
submitOnChange: true,
|
||||||
|
closeOnSubmit: false
|
||||||
|
},
|
||||||
|
dragDrop: [{ dragSelector: null, dropSelector: null }]
|
||||||
|
};
|
||||||
|
|
||||||
|
static PARTS = {
|
||||||
|
header: { template: 'systems/daggerheart/templates/sheets/items/armor/header.hbs' },
|
||||||
|
tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' },
|
||||||
|
description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' },
|
||||||
|
settings: {
|
||||||
|
template: 'systems/daggerheart/templates/sheets/items/armor/settings.hbs',
|
||||||
|
scrollable: ['.settings']
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
static TABS = {
|
||||||
|
description: {
|
||||||
|
active: true,
|
||||||
|
cssClass: '',
|
||||||
|
group: 'primary',
|
||||||
|
id: 'description',
|
||||||
|
icon: null,
|
||||||
|
label: 'DAGGERHEART.Sheets.Feature.Tabs.Description'
|
||||||
|
},
|
||||||
|
settings: {
|
||||||
|
active: false,
|
||||||
|
cssClass: '',
|
||||||
|
group: 'primary',
|
||||||
|
id: 'settings',
|
||||||
|
icon: null,
|
||||||
|
label: 'DAGGERHEART.Sheets.Feature.Tabs.Settings'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
async _prepareContext(_options) {
|
||||||
|
const context = await super._prepareContext(_options);
|
||||||
|
context.document = this.document;
|
||||||
|
context.config = CONFIG.daggerheart;
|
||||||
|
context.tabs = super._getTabs(this.constructor.TABS);
|
||||||
|
|
||||||
|
return context;
|
||||||
|
}
|
||||||
|
|
||||||
|
static async updateForm(event, _, formData) {
|
||||||
|
await this.document.update(formData.object);
|
||||||
|
this.render();
|
||||||
|
}
|
||||||
|
}
|
||||||
58
module/applications/sheets/items/weapon.mjs
Normal file
58
module/applications/sheets/items/weapon.mjs
Normal file
|
|
@ -0,0 +1,58 @@
|
||||||
|
import DaggerheartSheet from '../daggerheart-sheet.mjs';
|
||||||
|
|
||||||
|
const { ItemSheetV2 } = foundry.applications.sheets;
|
||||||
|
export default class WeaponSheet extends DaggerheartSheet(ItemSheetV2) {
|
||||||
|
static DEFAULT_OPTIONS = {
|
||||||
|
tag: 'form',
|
||||||
|
classes: ['daggerheart', 'sheet', 'dh-style', 'weapon'],
|
||||||
|
position: { width: 600 },
|
||||||
|
form: {
|
||||||
|
handler: this.updateForm,
|
||||||
|
submitOnChange: true,
|
||||||
|
closeOnSubmit: false
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
static PARTS = {
|
||||||
|
header: { template: 'systems/daggerheart/templates/sheets/items/weapon/header.hbs' },
|
||||||
|
tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' },
|
||||||
|
description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' },
|
||||||
|
settings: {
|
||||||
|
template: 'systems/daggerheart/templates/sheets/items/weapon/settings.hbs',
|
||||||
|
scrollable: ['.settings']
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
static TABS = {
|
||||||
|
description: {
|
||||||
|
active: true,
|
||||||
|
cssClass: '',
|
||||||
|
group: 'primary',
|
||||||
|
id: 'description',
|
||||||
|
icon: null,
|
||||||
|
label: 'DAGGERHEART.Sheets.Feature.Tabs.Description'
|
||||||
|
},
|
||||||
|
settings: {
|
||||||
|
active: false,
|
||||||
|
cssClass: '',
|
||||||
|
group: 'primary',
|
||||||
|
id: 'settings',
|
||||||
|
icon: null,
|
||||||
|
label: 'DAGGERHEART.Sheets.Feature.Tabs.Settings'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
async _prepareContext(_options) {
|
||||||
|
const context = await super._prepareContext(_options);
|
||||||
|
context.document = this.document;
|
||||||
|
context.config = CONFIG.daggerheart;
|
||||||
|
context.tabs = super._getTabs(this.constructor.TABS);
|
||||||
|
|
||||||
|
return context;
|
||||||
|
}
|
||||||
|
|
||||||
|
static async updateForm(event, _, formData) {
|
||||||
|
await this.document.update(formData.object);
|
||||||
|
this.render();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -489,7 +489,7 @@ export default class PCSheet extends DaggerheartSheet(ActorSheetV2) {
|
||||||
|
|
||||||
static async rollAttribute(event, button) {
|
static async rollAttribute(event, button) {
|
||||||
const { roll, hope, fear, advantage, disadvantage, modifiers } = await this.document.dualityRoll(
|
const { roll, hope, fear, advantage, disadvantage, modifiers } = await this.document.dualityRoll(
|
||||||
{ title: 'Attribute Bonus', value: button.dataset.value },
|
{ title: game.i18n.localize(abilities[button.dataset.attribute].label), value: button.dataset.value },
|
||||||
event.shiftKey
|
event.shiftKey
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,63 +0,0 @@
|
||||||
// import DhpApplicationMixin from '../daggerheart-sheet.mjs';
|
|
||||||
|
|
||||||
// export default class WeaponSheet extends DhpApplicationMixin(ItemSheet) {
|
|
||||||
// static documentType = "weapon";
|
|
||||||
|
|
||||||
// /** @override */
|
|
||||||
// static get defaultOptions() {
|
|
||||||
// return foundry.utils.mergeObject(super.defaultOptions, {
|
|
||||||
// classes: ["daggerheart", "sheet", "weapon"],
|
|
||||||
// width: 400,
|
|
||||||
// height: 'auto',
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
|
|
||||||
// /** @override */
|
|
||||||
// getData() {
|
|
||||||
// const context = super.getData();
|
|
||||||
// context.config = CONFIG.daggerheart;
|
|
||||||
|
|
||||||
// return context;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// async _handleAction(action, event, button) {
|
|
||||||
// switch(action){
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
import DaggerheartSheet from './daggerheart-sheet.mjs';
|
|
||||||
|
|
||||||
const { ItemSheetV2 } = foundry.applications.sheets;
|
|
||||||
export default class WeaponSheet extends DaggerheartSheet(ItemSheetV2) {
|
|
||||||
static DEFAULT_OPTIONS = {
|
|
||||||
tag: 'form',
|
|
||||||
classes: ['daggerheart', 'sheet', 'weapon'],
|
|
||||||
position: { width: 400 },
|
|
||||||
form: {
|
|
||||||
handler: this.updateForm,
|
|
||||||
submitOnChange: true,
|
|
||||||
closeOnSubmit: false
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
static PARTS = {
|
|
||||||
form: {
|
|
||||||
id: 'feature',
|
|
||||||
template: 'systems/daggerheart/templates/sheets/weapon.hbs'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
async _prepareContext(_options) {
|
|
||||||
const context = await super._prepareContext(_options);
|
|
||||||
context.document = this.document;
|
|
||||||
context.config = CONFIG.daggerheart;
|
|
||||||
|
|
||||||
return context;
|
|
||||||
}
|
|
||||||
|
|
||||||
static async updateForm(event, _, formData) {
|
|
||||||
await this.document.update(formData.object);
|
|
||||||
this.render();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,77 +1,77 @@
|
||||||
export const abilities = {
|
export const abilities = {
|
||||||
agility: {
|
agility: {
|
||||||
label: 'DAGGERHEART.Abilities.Agility.Name',
|
label: 'DAGGERHEART.Abilities.agility.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Agility.Verb.Sprint',
|
'DAGGERHEART.Abilities.agility.verb.sprint',
|
||||||
'DAGGERHEART.Abilities.Agility.Verb.Leap',
|
'DAGGERHEART.Abilities.agility.verb.leap',
|
||||||
'DAGGERHEART.Abilities.Agility.Verb.Maneuver'
|
'DAGGERHEART.Abilities.agility.verb.maneuver'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
strength: {
|
strength: {
|
||||||
label: 'DAGGERHEART.Abilities.Strength.Name',
|
label: 'DAGGERHEART.Abilities.strength.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Strength.Verb.Lift',
|
'DAGGERHEART.Abilities.strength.verb.lift',
|
||||||
'DAGGERHEART.Abilities.Strength.Verb.Smash',
|
'DAGGERHEART.Abilities.strength.verb.smash',
|
||||||
'DAGGERHEART.Abilities.Strength.Verb.Grapple'
|
'DAGGERHEART.Abilities.strength.verb.grapple'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
finesse: {
|
finesse: {
|
||||||
label: 'DAGGERHEART.Abilities.Finesse.Name',
|
label: 'DAGGERHEART.Abilities.finesse.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Finesse.Verb.Control',
|
'DAGGERHEART.Abilities.finesse.verb.control',
|
||||||
'DAGGERHEART.Abilities.Finesse.Verb.Hide',
|
'DAGGERHEART.Abilities.finesse.verb.hide',
|
||||||
'DAGGERHEART.Abilities.Finesse.Verb.Tinker'
|
'DAGGERHEART.Abilities.finesse.verb.tinker'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
instinct: {
|
instinct: {
|
||||||
label: 'DAGGERHEART.Abilities.Instinct.Name',
|
label: 'DAGGERHEART.Abilities.instinct.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Instinct.Verb.Perceive',
|
'DAGGERHEART.Abilities.instinct.verb.perceive',
|
||||||
'DAGGERHEART.Abilities.Instinct.Verb.Sense',
|
'DAGGERHEART.Abilities.instinct.verb.sense',
|
||||||
'DAGGERHEART.Abilities.Instinct.Verb.Navigate'
|
'DAGGERHEART.Abilities.instinct.verb.navigate'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
presence: {
|
presence: {
|
||||||
label: 'DAGGERHEART.Abilities.Presence.Name',
|
label: 'DAGGERHEART.Abilities.presence.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Presence.Verb.Charm',
|
'DAGGERHEART.Abilities.presence.verb.charm',
|
||||||
'DAGGERHEART.Abilities.Presence.Verb.Perform',
|
'DAGGERHEART.Abilities.presence.verb.perform',
|
||||||
'DAGGERHEART.Abilities.Presence.Verb.Deceive'
|
'DAGGERHEART.Abilities.presence.verb.deceive'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
knowledge: {
|
knowledge: {
|
||||||
label: 'DAGGERHEART.Abilities.Knowledge.Name',
|
label: 'DAGGERHEART.Abilities.knowledge.name',
|
||||||
verbs: [
|
verbs: [
|
||||||
'DAGGERHEART.Abilities.Knowledge.Verb.Recall',
|
'DAGGERHEART.Abilities.knowledge.verb.recall',
|
||||||
'DAGGERHEART.Abilities.Knowledge.Verb.Analyze',
|
'DAGGERHEART.Abilities.knowledge.verb.analyze',
|
||||||
'DAGGERHEART.Abilities.Knowledge.Verb.Comprehend'
|
'DAGGERHEART.Abilities.knowledge.verb.comprehend'
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export const featureProperties = {
|
export const featureProperties = {
|
||||||
agility: {
|
agility: {
|
||||||
name: 'DAGGERHEART.Abilities.Agility.Name',
|
name: 'DAGGERHEART.Abilities.agility.name',
|
||||||
path: actor => actor.system.traits.agility.data.value
|
path: actor => actor.system.traits.agility.data.value
|
||||||
},
|
},
|
||||||
strength: {
|
strength: {
|
||||||
name: 'DAGGERHEART.Abilities.Strength.Name',
|
name: 'DAGGERHEART.Abilities.strength.name',
|
||||||
path: actor => actor.system.traits.strength.data.value
|
path: actor => actor.system.traits.strength.data.value
|
||||||
},
|
},
|
||||||
finesse: {
|
finesse: {
|
||||||
name: 'DAGGERHEART.Abilities.Finesse.Name',
|
name: 'DAGGERHEART.Abilities.finesse.name',
|
||||||
path: actor => actor.system.traits.finesse.data.value
|
path: actor => actor.system.traits.finesse.data.value
|
||||||
},
|
},
|
||||||
instinct: {
|
instinct: {
|
||||||
name: 'DAGGERHEART.Abilities.Instinct.Name',
|
name: 'DAGGERHEART.Abilities.instinct.name',
|
||||||
path: actor => actor.system.traits.instinct.data.value
|
path: actor => actor.system.traits.instinct.data.value
|
||||||
},
|
},
|
||||||
presence: {
|
presence: {
|
||||||
name: 'DAGGERHEART.Abilities.Presence.Name',
|
name: 'DAGGERHEART.Abilities.presence.name',
|
||||||
path: actor => actor.system.traits.presence.data.value
|
path: actor => actor.system.traits.presence.data.value
|
||||||
},
|
},
|
||||||
knowledge: {
|
knowledge: {
|
||||||
name: 'DAGGERHEART.Abilities.Knowledge.Name',
|
name: 'DAGGERHEART.Abilities.knowledge.name',
|
||||||
path: actor => actor.system.traits.knowledge.data.value
|
path: actor => actor.system.traits.knowledge.data.value
|
||||||
},
|
},
|
||||||
spellcastingTrait: {
|
spellcastingTrait: {
|
||||||
|
|
|
||||||
|
|
@ -1,27 +1,27 @@
|
||||||
export const range = {
|
export const range = {
|
||||||
melee: {
|
melee: {
|
||||||
label: 'DAGGERHEART.Range.Melee.Name',
|
label: 'DAGGERHEART.Range.melee.name',
|
||||||
description: 'DAGGERHEART.Range.Melee.Description',
|
description: 'DAGGERHEART.Range.melee.description',
|
||||||
distance: 1
|
distance: 1
|
||||||
},
|
},
|
||||||
veryClose: {
|
veryClose: {
|
||||||
label: 'DAGGERHEART.Range.VeryClose.Name',
|
label: 'DAGGERHEART.Range.veryClose.name',
|
||||||
description: 'DAGGERHEART.Range.VeryClose.Description',
|
description: 'DAGGERHEART.Range.veryClose.description',
|
||||||
distance: 3
|
distance: 3
|
||||||
},
|
},
|
||||||
close: {
|
close: {
|
||||||
label: 'DAGGERHEART.Range.Close.Name',
|
label: 'DAGGERHEART.Range.close.name',
|
||||||
description: 'DAGGERHEART.Range.Close.Description',
|
description: 'DAGGERHEART.Range.close.description',
|
||||||
distance: 10
|
distance: 10
|
||||||
},
|
},
|
||||||
far: {
|
far: {
|
||||||
label: 'DAGGERHEART.Range.Far.Name',
|
label: 'DAGGERHEART.Range.far.name',
|
||||||
description: 'DAGGERHEART.Range.Far.Description',
|
description: 'DAGGERHEART.Range.far.description',
|
||||||
distance: 20
|
distance: 20
|
||||||
},
|
},
|
||||||
veryFar: {
|
veryFar: {
|
||||||
label: 'DAGGERHEART.Range.VeryFar.Name',
|
label: 'DAGGERHEART.Range.veryFar.name',
|
||||||
description: 'DAGGERHEART.Range.VeryFar.Description',
|
description: 'DAGGERHEART.Range.veryFar.description',
|
||||||
distance: 30
|
distance: 30
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -29,24 +29,24 @@ export const range = {
|
||||||
export const burden = {
|
export const burden = {
|
||||||
oneHanded: {
|
oneHanded: {
|
||||||
value: 'oneHanded',
|
value: 'oneHanded',
|
||||||
label: 'DAGGERHEART.Burden.OneHanded'
|
label: 'DAGGERHEART.Burden.oneHanded'
|
||||||
},
|
},
|
||||||
twoHanded: {
|
twoHanded: {
|
||||||
value: 'twoHanded',
|
value: 'twoHanded',
|
||||||
label: 'DAGGERHEART.Burden.TwoHanded'
|
label: 'DAGGERHEART.Burden.twoHanded'
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export const damageTypes = {
|
export const damageTypes = {
|
||||||
physical: {
|
physical: {
|
||||||
id: 'physical',
|
id: 'physical',
|
||||||
label: 'DAGGERHEART.DamageType.Physical.Name',
|
label: 'DAGGERHEART.DamageType.physical.name',
|
||||||
abbreviation: 'DAGGERHEART.DamageType.Physical.Abbreviation'
|
abbreviation: 'DAGGERHEART.DamageType.physical.abbreviation'
|
||||||
},
|
},
|
||||||
magical: {
|
magical: {
|
||||||
id: 'magical',
|
id: 'magical',
|
||||||
label: 'DAGGERHEART.DamageType.Magical.Name',
|
label: 'DAGGERHEART.DamageType.magical.name',
|
||||||
abbreviation: 'DAGGERHEART.DamageType.Magical.Abbreviation'
|
abbreviation: 'DAGGERHEART.DamageType.magical.abbreviation'
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -247,6 +247,45 @@ export const diceTypes = {
|
||||||
d20: 'd20'
|
d20: 'd20'
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const getDiceSoNicePresets = () => {
|
||||||
|
const { diceSoNice } = game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance);
|
||||||
|
|
||||||
|
return {
|
||||||
|
hope: {
|
||||||
|
...diceSoNice.hope,
|
||||||
|
colorset: 'inspired',
|
||||||
|
texture: 'bloodmoon',
|
||||||
|
material: 'metal',
|
||||||
|
font: 'Arial Black',
|
||||||
|
system: 'standard'
|
||||||
|
},
|
||||||
|
fear: {
|
||||||
|
...diceSoNice.fear,
|
||||||
|
colorset: 'bloodmoon',
|
||||||
|
texture: 'bloodmoon',
|
||||||
|
material: 'metal',
|
||||||
|
font: 'Arial Black',
|
||||||
|
system: 'standard'
|
||||||
|
},
|
||||||
|
advantage: {
|
||||||
|
...diceSoNice.advantage,
|
||||||
|
colorset: 'bloodmoon',
|
||||||
|
texture: 'bloodmoon',
|
||||||
|
material: 'metal',
|
||||||
|
font: 'Arial Black',
|
||||||
|
system: 'standard'
|
||||||
|
},
|
||||||
|
disadvantage: {
|
||||||
|
...diceSoNice.disadvantage,
|
||||||
|
colorset: 'bloodmoon',
|
||||||
|
texture: 'bloodmoon',
|
||||||
|
material: 'metal',
|
||||||
|
font: 'Arial Black',
|
||||||
|
system: 'standard'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
export const refreshTypes = {
|
export const refreshTypes = {
|
||||||
session: {
|
session: {
|
||||||
id: 'session',
|
id: 'session',
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,8 @@ export const gameSettings = {
|
||||||
RangeMeasurement: 'RangeMeasurement'
|
RangeMeasurement: 'RangeMeasurement'
|
||||||
},
|
},
|
||||||
DualityRollColor: 'DualityRollColor',
|
DualityRollColor: 'DualityRollColor',
|
||||||
LevelTiers: 'LevelTiers'
|
LevelTiers: 'LevelTiers',
|
||||||
|
appearance: 'Appearance'
|
||||||
};
|
};
|
||||||
|
|
||||||
export const DualityRollColor = {
|
export const DualityRollColor = {
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ export default class DhpArmor extends foundry.abstract.TypeDataModel {
|
||||||
const fields = foundry.data.fields;
|
const fields = foundry.data.fields;
|
||||||
return {
|
return {
|
||||||
equipped: new fields.BooleanField({ initial: false }),
|
equipped: new fields.BooleanField({ initial: false }),
|
||||||
baseScore: new fields.NumberField({ initial: 1, integer: true }),
|
baseScore: new fields.NumberField({ integer: true, initial: 0 }),
|
||||||
feature: new fields.StringField({
|
feature: new fields.StringField({
|
||||||
choices: SYSTEM.ITEM.armorFeatures,
|
choices: SYSTEM.ITEM.armorFeatures,
|
||||||
integer: false,
|
integer: false,
|
||||||
|
|
@ -14,10 +14,10 @@ export default class DhpArmor extends foundry.abstract.TypeDataModel {
|
||||||
value: new fields.NumberField({ initial: 0, integer: true })
|
value: new fields.NumberField({ initial: 0, integer: true })
|
||||||
}),
|
}),
|
||||||
baseThresholds: new fields.SchemaField({
|
baseThresholds: new fields.SchemaField({
|
||||||
major: new fields.NumberField({ initial: 0, integer: true }),
|
major: new fields.NumberField({ integer: true, initial: 0 }),
|
||||||
severe: new fields.NumberField({ initial: 0, integer: true })
|
severe: new fields.NumberField({ integer: true, initial: 0 })
|
||||||
}),
|
}),
|
||||||
quantity: new fields.NumberField({ initial: 1, integer: true }),
|
quantity: new fields.NumberField({ integer: true, initial: 1 }),
|
||||||
description: new fields.HTMLField({})
|
description: new fields.HTMLField({})
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { DualityRollColor } from '../config/settingsConfig.mjs';
|
import { DualityRollColor } from './settings/Appearance.mjs';
|
||||||
|
|
||||||
const fields = foundry.data.fields;
|
const fields = foundry.data.fields;
|
||||||
const diceField = () =>
|
const diceField = () =>
|
||||||
|
|
@ -81,7 +81,7 @@ export default class DhpDualityRoll extends foundry.abstract.TypeDataModel {
|
||||||
const total = this.modifiers.reduce((acc, x) => acc + x.value, 0);
|
const total = this.modifiers.reduce((acc, x) => acc + x.value, 0);
|
||||||
return {
|
return {
|
||||||
value: total,
|
value: total,
|
||||||
label: total > 0 ? `+${total}` : total < 0 ? `-${total}` : ''
|
label: total > 0 ? `+${total}` : total < 0 ? `${total}` : ''
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -106,7 +106,7 @@ export default class DhpDualityRoll extends foundry.abstract.TypeDataModel {
|
||||||
|
|
||||||
get colorful() {
|
get colorful() {
|
||||||
return (
|
return (
|
||||||
game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.DualityRollColor) ===
|
game.settings.get(SYSTEM.id, SYSTEM.SETTINGS.gameSettings.appearance).dualityColorScheme ===
|
||||||
DualityRollColor.colorful.value
|
DualityRollColor.colorful.value
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
51
module/data/settings/Appearance.mjs
Normal file
51
module/data/settings/Appearance.mjs
Normal file
|
|
@ -0,0 +1,51 @@
|
||||||
|
export default class DhAppearance extends foundry.abstract.DataModel {
|
||||||
|
static defineSchema() {
|
||||||
|
const fields = foundry.data.fields;
|
||||||
|
return {
|
||||||
|
dualityColorScheme: new fields.StringField({
|
||||||
|
required: true,
|
||||||
|
choices: DualityRollColor,
|
||||||
|
initial: DualityRollColor.normal.value
|
||||||
|
}),
|
||||||
|
diceSoNice: new fields.SchemaField({
|
||||||
|
hope: new fields.SchemaField({
|
||||||
|
foreground: new fields.ColorField({ required: true, initial: '#ffffff' }),
|
||||||
|
background: new fields.ColorField({ required: true, initial: '#ffe760' }),
|
||||||
|
outline: new fields.ColorField({ required: true, initial: '#000000' }),
|
||||||
|
edge: new fields.ColorField({ required: true, initial: '#ffffff' })
|
||||||
|
}),
|
||||||
|
fear: new fields.SchemaField({
|
||||||
|
foreground: new fields.ColorField({ required: true, initial: '#000000' }),
|
||||||
|
background: new fields.ColorField({ required: true, initial: '#0032b1' }),
|
||||||
|
outline: new fields.ColorField({ required: true, initial: '#ffffff' }),
|
||||||
|
edge: new fields.ColorField({ required: true, initial: '#000000' })
|
||||||
|
}),
|
||||||
|
advantage: new fields.SchemaField({
|
||||||
|
foreground: new fields.ColorField({ required: true, initial: '#ffffff' }),
|
||||||
|
background: new fields.ColorField({ required: true, initial: '#008000' }),
|
||||||
|
outline: new fields.ColorField({ required: true, initial: '#000000' }),
|
||||||
|
edge: new fields.ColorField({ required: true, initial: '#ffffff' })
|
||||||
|
}),
|
||||||
|
disadvantage: new fields.SchemaField({
|
||||||
|
foreground: new fields.ColorField({ required: true, initial: '#000000' }),
|
||||||
|
background: new fields.ColorField({ required: true, initial: '#b30000' }),
|
||||||
|
outline: new fields.ColorField({ required: true, initial: '#ffffff' }),
|
||||||
|
edge: new fields.ColorField({ required: true, initial: '#000000' })
|
||||||
|
})
|
||||||
|
})
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
static defaultSchema = {};
|
||||||
|
}
|
||||||
|
|
||||||
|
export const DualityRollColor = {
|
||||||
|
colorful: {
|
||||||
|
value: 'colorful',
|
||||||
|
label: 'DAGGERHEART.Settings.DualityRollColor.Options.Colorful'
|
||||||
|
},
|
||||||
|
normal: {
|
||||||
|
value: 'normal',
|
||||||
|
label: 'DAGGERHEART.Settings.DualityRollColor.Options.Normal'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
@ -5,13 +5,17 @@ export default class DhpWeapon extends foundry.abstract.TypeDataModel {
|
||||||
equipped: new fields.BooleanField({ initial: false }),
|
equipped: new fields.BooleanField({ initial: false }),
|
||||||
inventoryWeapon: new fields.NumberField({ initial: null, nullable: true, integer: true }),
|
inventoryWeapon: new fields.NumberField({ initial: null, nullable: true, integer: true }),
|
||||||
secondary: new fields.BooleanField({ initial: false }),
|
secondary: new fields.BooleanField({ initial: false }),
|
||||||
trait: new fields.StringField({ choices: SYSTEM.ACTOR.abilities, integer: false }),
|
trait: new fields.StringField({ choices: SYSTEM.ACTOR.abilities, integer: false, initial: 'agility' }),
|
||||||
range: new fields.StringField({ choices: SYSTEM.GENERAL.range, integer: false }),
|
range: new fields.StringField({ choices: SYSTEM.GENERAL.range, integer: false, initial: 'melee' }),
|
||||||
damage: new fields.SchemaField({
|
damage: new fields.SchemaField({
|
||||||
value: new fields.StringField({}),
|
value: new fields.StringField({ initial: 'd6' }),
|
||||||
type: new fields.StringField({ choices: SYSTEM.GENERAL.damageTypes, integer: false })
|
type: new fields.StringField({
|
||||||
|
choices: SYSTEM.GENERAL.damageTypes,
|
||||||
|
integer: false,
|
||||||
|
initial: 'physical'
|
||||||
|
})
|
||||||
}),
|
}),
|
||||||
burden: new fields.StringField({ choices: SYSTEM.GENERAL.burden, integer: false }),
|
burden: new fields.StringField({ choices: SYSTEM.GENERAL.burden, integer: false, initial: 'oneHanded' }),
|
||||||
feature: new fields.StringField({ choices: SYSTEM.ITEM.weaponFeatures, integer: false, blank: true }),
|
feature: new fields.StringField({ choices: SYSTEM.ITEM.weaponFeatures, integer: false, blank: true }),
|
||||||
quantity: new fields.NumberField({ initial: 1, integer: true }),
|
quantity: new fields.NumberField({ initial: 1, integer: true }),
|
||||||
description: new fields.HTMLField({})
|
description: new fields.HTMLField({})
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ import DamageSelectionDialog from '../applications/damageSelectionDialog.mjs';
|
||||||
import NpcRollSelectionDialog from '../applications/npcRollSelectionDialog.mjs';
|
import NpcRollSelectionDialog from '../applications/npcRollSelectionDialog.mjs';
|
||||||
import RollSelectionDialog from '../applications/rollSelectionDialog.mjs';
|
import RollSelectionDialog from '../applications/rollSelectionDialog.mjs';
|
||||||
import { GMUpdateEvent, socketEvent } from '../helpers/socket.mjs';
|
import { GMUpdateEvent, socketEvent } from '../helpers/socket.mjs';
|
||||||
|
import { setDiceSoNiceForDualityRoll } from '../helpers/utils.mjs';
|
||||||
|
|
||||||
export default class DhpActor extends Actor {
|
export default class DhpActor extends Actor {
|
||||||
_preCreate(data, changes, user) {
|
_preCreate(data, changes, user) {
|
||||||
|
|
@ -116,16 +117,19 @@ export default class DhpActor extends Actor {
|
||||||
disadvantageDice = null,
|
disadvantageDice = null,
|
||||||
bonusDamageString = '';
|
bonusDamageString = '';
|
||||||
|
|
||||||
const modifiers = [
|
const modifiers =
|
||||||
{
|
modifier.value !== null
|
||||||
value: modifier.value ? Number.parseInt(modifier.value) : 0,
|
? [
|
||||||
label:
|
{
|
||||||
modifier.value >= 0
|
value: modifier.value ? Number.parseInt(modifier.value) : 0,
|
||||||
? `${modifier.title} +${modifier.value}`
|
label:
|
||||||
: `${modifier.title} -${modifier.value}`,
|
modifier.value >= 0
|
||||||
title: modifier.title
|
? `${modifier.title} +${modifier.value}`
|
||||||
}
|
: `${modifier.title} ${modifier.value}`,
|
||||||
];
|
title: modifier.title
|
||||||
|
}
|
||||||
|
]
|
||||||
|
: [];
|
||||||
if (!shiftKey) {
|
if (!shiftKey) {
|
||||||
const dialogClosed = new Promise((resolve, _) => {
|
const dialogClosed = new Promise((resolve, _) => {
|
||||||
new RollSelectionDialog(
|
new RollSelectionDialog(
|
||||||
|
|
@ -161,53 +165,7 @@ export default class DhpActor extends Actor {
|
||||||
`1${hopeDice} + 1${fearDice}${advantageDice ? ` + 1${advantageDice}` : disadvantageDice ? ` - 1${disadvantageDice}` : ''} ${modifiers.map(x => `+ ${x.value}`).join(' ')}`
|
`1${hopeDice} + 1${fearDice}${advantageDice ? ` + 1${advantageDice}` : disadvantageDice ? ` - 1${disadvantageDice}` : ''} ${modifiers.map(x => `+ ${x.value}`).join(' ')}`
|
||||||
);
|
);
|
||||||
let rollResult = await roll.evaluate();
|
let rollResult = await roll.evaluate();
|
||||||
rollResult.dice[0].options.appearance = {
|
setDiceSoNiceForDualityRoll(rollResult, advantageDice, disadvantageDice);
|
||||||
colorset: 'inspired',
|
|
||||||
foreground: '#FFFFFF',
|
|
||||||
background: '#008080',
|
|
||||||
outline: '#000000',
|
|
||||||
edge: '#806400',
|
|
||||||
texture: 'bloodmoon',
|
|
||||||
material: 'metal',
|
|
||||||
font: 'Arial Black',
|
|
||||||
system: 'standard'
|
|
||||||
};
|
|
||||||
if (advantageDice || disadvantageDice) {
|
|
||||||
rollResult.dice[1].options.appearance = {
|
|
||||||
colorset: 'inspired',
|
|
||||||
foreground: disadvantageDice ? '#b30000' : '#FFFFFF',
|
|
||||||
background: '#008080',
|
|
||||||
outline: disadvantageDice ? '#000000' : '#000000',
|
|
||||||
edge: '#806400',
|
|
||||||
texture: 'bloodmoon',
|
|
||||||
material: 'metal',
|
|
||||||
font: 'Arial Black',
|
|
||||||
system: 'standard'
|
|
||||||
};
|
|
||||||
rollResult.dice[2].options.appearance = {
|
|
||||||
colorset: 'bloodmoon',
|
|
||||||
foreground: '#000000',
|
|
||||||
background: '#430070',
|
|
||||||
outline: '#b30000',
|
|
||||||
edge: '#000000',
|
|
||||||
texture: 'bloodmoon',
|
|
||||||
material: 'metal',
|
|
||||||
font: 'Arial Black',
|
|
||||||
system: 'standard'
|
|
||||||
};
|
|
||||||
} else {
|
|
||||||
rollResult.dice[1].options.appearance = {
|
|
||||||
colorset: 'bloodmoon',
|
|
||||||
foreground: '#000000',
|
|
||||||
background: '#430070',
|
|
||||||
outline: '#b30000',
|
|
||||||
edge: '#000000',
|
|
||||||
texture: 'bloodmoon',
|
|
||||||
material: 'metal',
|
|
||||||
font: 'Arial Black',
|
|
||||||
system: 'standard'
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
const hope = rollResult.dice[0].results[0].result;
|
const hope = rollResult.dice[0].results[0].result;
|
||||||
const fear = rollResult.dice[1].results[0].result;
|
const fear = rollResult.dice[1].results[0].result;
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
import { diceSoNicePresets, getDiceSoNicePresets } from '../config/generalConfig.mjs';
|
||||||
|
|
||||||
export const loadCompendiumOptions = async compendiums => {
|
export const loadCompendiumOptions = async compendiums => {
|
||||||
const compendiumValues = [];
|
const compendiumValues = [];
|
||||||
|
|
||||||
|
|
@ -118,3 +120,14 @@ export const getCommandTarget = () => {
|
||||||
|
|
||||||
return target;
|
return target;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const setDiceSoNiceForDualityRoll = (rollResult, advantage, disadvantage) => {
|
||||||
|
const diceSoNicePresets = getDiceSoNicePresets();
|
||||||
|
rollResult.dice[0].options.appearance = diceSoNicePresets.hope;
|
||||||
|
rollResult.dice[1].options.appearance = diceSoNicePresets.fear;
|
||||||
|
if (advantage) {
|
||||||
|
rollResult.dice[2].options.appearance = diceSoNicePresets.advantage;
|
||||||
|
} else if (disadvantage) {
|
||||||
|
rollResult.dice[2].options.appearance = diceSoNicePresets.disadvantage;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
|
||||||
|
|
@ -21,15 +21,6 @@
|
||||||
align-items: end;
|
align-items: end;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
padding: 0 8px;
|
padding: 0 8px;
|
||||||
|
|
||||||
.duality-result-value {
|
|
||||||
border: 1px solid var(--color-dark-5);
|
|
||||||
padding: 2px;
|
|
||||||
font-weight: bold;
|
|
||||||
background: var(--color-dark-1);
|
|
||||||
margin-bottom: 4px;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.duality-modifiers {
|
.duality-modifiers {
|
||||||
|
|
@ -211,7 +202,7 @@
|
||||||
text-shadow: 0 0 1px black;
|
text-shadow: 0 0 1px black;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
background: var(--color-dark-1);
|
background: var(--color-dark-1);
|
||||||
padding: 4px;
|
padding: 4px 4px 0 4px;
|
||||||
border-radius: 6px 0 0 0;
|
border-radius: 6px 0 0 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -506,6 +497,15 @@
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dice-actions {
|
||||||
|
margin-top: 5px;
|
||||||
|
display: flex;
|
||||||
|
|
||||||
|
button {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.domain-card {
|
&.domain-card {
|
||||||
|
|
|
||||||
|
|
@ -1369,14 +1369,6 @@
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
padding: 0 8px;
|
padding: 0 8px;
|
||||||
}
|
}
|
||||||
.chat-message.duality .duality-data .duality-title .duality-result-value {
|
|
||||||
border: 1px solid var(--color-dark-5);
|
|
||||||
padding: 2px;
|
|
||||||
font-weight: bold;
|
|
||||||
background: var(--color-dark-1);
|
|
||||||
margin-bottom: 4px;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
.chat-message.duality .duality-data .duality-modifiers {
|
.chat-message.duality .duality-data .duality-modifiers {
|
||||||
display: flex;
|
display: flex;
|
||||||
gap: 2px;
|
gap: 2px;
|
||||||
|
|
@ -1504,7 +1496,7 @@
|
||||||
text-shadow: 0 0 1px black;
|
text-shadow: 0 0 1px black;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
background: var(--color-dark-1);
|
background: var(--color-dark-1);
|
||||||
padding: 4px;
|
padding: 4px 4px 0 4px;
|
||||||
border-radius: 6px 0 0 0;
|
border-radius: 6px 0 0 0;
|
||||||
}
|
}
|
||||||
.chat-message.duality .duality-actions {
|
.chat-message.duality .duality-actions {
|
||||||
|
|
@ -1736,6 +1728,13 @@
|
||||||
.daggerheart.chat.roll .dice-result .damage-button {
|
.daggerheart.chat.roll .dice-result .damage-button {
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
}
|
}
|
||||||
|
.daggerheart.chat.roll .dice-actions {
|
||||||
|
margin-top: 5px;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
.daggerheart.chat.roll .dice-actions button {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
.daggerheart.chat.domain-card {
|
.daggerheart.chat.domain-card {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
@ -3117,6 +3116,11 @@ div.daggerheart.views.multiclass {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
}
|
}
|
||||||
|
.application.sheet.dh-style fieldset .form-group label {
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: smaller;
|
||||||
|
}
|
||||||
.application.sheet.dh-style line-div {
|
.application.sheet.dh-style line-div {
|
||||||
display: block;
|
display: block;
|
||||||
height: 1px;
|
height: 1px;
|
||||||
|
|
@ -3136,6 +3140,39 @@ div.daggerheart.views.multiclass {
|
||||||
transform: translateY(-20px);
|
transform: translateY(-20px);
|
||||||
transform-origin: top;
|
transform-origin: top;
|
||||||
}
|
}
|
||||||
|
.application.setting.dh-style fieldset h2,
|
||||||
|
.application.setting.dh-style fieldset h3,
|
||||||
|
.application.setting.dh-style fieldset h4 {
|
||||||
|
margin: 8px 0 4px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style fieldset .title-hint {
|
||||||
|
font-size: 12px;
|
||||||
|
font-variant: small-caps;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style fieldset .field-section .split-section {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
gap: 10px;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style fieldset .label-container {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
gap: 10px;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style fieldset .label-container label {
|
||||||
|
align-self: center;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style footer {
|
||||||
|
margin-top: 8px;
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
.application.setting.dh-style footer button {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
.sheet.daggerheart.dh-style .tab-navigation {
|
.sheet.daggerheart.dh-style .tab-navigation {
|
||||||
margin: 5px 0;
|
margin: 5px 0;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
|
|
@ -3186,6 +3223,7 @@ div.daggerheart.views.multiclass {
|
||||||
}
|
}
|
||||||
.application.sheet.daggerheart.dh-style .item-sheet-header .item-info .item-description {
|
.application.sheet.daggerheart.dh-style .item-sheet-header .item-info .item-description {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
.application.sheet.daggerheart.dh-style .item-sheet-header .item-info h3 {
|
.application.sheet.daggerheart.dh-style .item-sheet-header .item-info h3 {
|
||||||
|
|
|
||||||
|
|
@ -1,161 +1,214 @@
|
||||||
@import '../utils/colors.less';
|
@import '../utils/colors.less';
|
||||||
@import '../utils/fonts.less';
|
@import '../utils/fonts.less';
|
||||||
|
|
||||||
.application.sheet.dh-style {
|
.application.sheet.dh-style {
|
||||||
border: 1px solid light-dark(@dark-blue, @golden);
|
border: 1px solid light-dark(@dark-blue, @golden);
|
||||||
|
|
||||||
input[type='text'],
|
input[type='text'],
|
||||||
input[type='number'] {
|
input[type='number'] {
|
||||||
background: light-dark(transparent, transparent);
|
background: light-dark(transparent, transparent);
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
box-shadow: 0 4px 30px @soft-shadow;
|
box-shadow: 0 4px 30px @soft-shadow;
|
||||||
backdrop-filter: blur(9.5px);
|
backdrop-filter: blur(9.5px);
|
||||||
-webkit-backdrop-filter: blur(9.5px);
|
-webkit-backdrop-filter: blur(9.5px);
|
||||||
outline: none;
|
outline: none;
|
||||||
color: light-dark(@dark-blue, @golden);
|
color: light-dark(@dark-blue, @golden);
|
||||||
border: 1px solid light-dark(@dark, @beige);
|
border: 1px solid light-dark(@dark, @beige);
|
||||||
|
|
||||||
&:hover[type='text'],
|
&:hover[type='text'],
|
||||||
&:hover[type='number'],
|
&:hover[type='number'],
|
||||||
&:focus[type='text'],
|
&:focus[type='text'],
|
||||||
&:focus[type='number'] {
|
&:focus[type='number'] {
|
||||||
background: light-dark(@soft-shadow, @semi-transparent-dark-blue);
|
background: light-dark(@soft-shadow, @semi-transparent-dark-blue);
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
outline: 2px solid light-dark(@dark, @beige);
|
outline: 2px solid light-dark(@dark, @beige);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type='checkbox'] {
|
input[type='checkbox'] {
|
||||||
&:checked::after {
|
&:checked::after {
|
||||||
color: light-dark(@dark, @golden);
|
color: light-dark(@dark, @golden);
|
||||||
}
|
}
|
||||||
&:checked::before {
|
&:checked::before {
|
||||||
color: light-dark(transparent, @dark-blue);
|
color: light-dark(transparent, @dark-blue);
|
||||||
}
|
}
|
||||||
&::before {
|
&::before {
|
||||||
color: light-dark(@dark, @beige);
|
color: light-dark(@dark, @beige);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
button {
|
button {
|
||||||
background: light-dark(transparent, @golden);
|
background: light-dark(transparent, @golden);
|
||||||
border: 1px solid light-dark(@dark-blue, @dark-blue);
|
border: 1px solid light-dark(@dark-blue, @dark-blue);
|
||||||
color: light-dark(@dark-blue, @dark-blue);
|
color: light-dark(@dark-blue, @dark-blue);
|
||||||
outline: none;
|
outline: none;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background: light-dark(@light-black, @dark-blue);
|
background: light-dark(@light-black, @dark-blue);
|
||||||
color: light-dark(@dark-blue, @golden);
|
color: light-dark(@dark-blue, @golden);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
select {
|
select {
|
||||||
background: light-dark(transparent, transparent);
|
background: light-dark(transparent, transparent);
|
||||||
color: light-dark(@dark, @beige);
|
color: light-dark(@dark, @beige);
|
||||||
font-family: @font-body;
|
font-family: @font-body;
|
||||||
outline: 2px solid transparent;
|
outline: 2px solid transparent;
|
||||||
border: 1px solid light-dark(@dark, @beige);
|
border: 1px solid light-dark(@dark, @beige);
|
||||||
|
|
||||||
&:focus,
|
&:focus,
|
||||||
&:hover {
|
&:hover {
|
||||||
outline: 2px solid light-dark(@dark, @beige);
|
outline: 2px solid light-dark(@dark, @beige);
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
& option {
|
& option {
|
||||||
color: @beige;
|
color: @beige;
|
||||||
background-color: @dark-blue;
|
background-color: @dark-blue;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
p {
|
p {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
ul {
|
ul {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
list-style: none;
|
list-style: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
li {
|
li {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset {
|
fieldset {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
border-color: light-dark(@dark-blue, @golden);
|
border-color: light-dark(@dark-blue, @golden);
|
||||||
|
|
||||||
&.one-column {
|
&.one-column {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: start;
|
align-items: start;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
min-height: 64px;
|
min-height: 64px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.two-columns {
|
&.two-columns {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: 1fr 2fr;
|
grid-template-columns: 1fr 2fr;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
legend {
|
legend {
|
||||||
font-family: @font-body;
|
font-family: @font-body;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
color: light-dark(@dark-blue, @golden);
|
color: light-dark(@dark-blue, @golden);
|
||||||
|
|
||||||
a {
|
a {
|
||||||
text-shadow: none;
|
text-shadow: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type='text'],
|
input[type='text'],
|
||||||
input[type='number'] {
|
input[type='number'] {
|
||||||
color: light-dark(@dark, @beige);
|
color: light-dark(@dark, @beige);
|
||||||
font-family: @font-body;
|
font-family: @font-body;
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
outline: 2px solid transparent;
|
outline: 2px solid transparent;
|
||||||
|
|
||||||
&:focus,
|
&:focus,
|
||||||
&:hover {
|
&:hover {
|
||||||
outline: 2px solid light-dark(@dark, @beige);
|
outline: 2px solid light-dark(@dark, @beige);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.nest-inputs {
|
.nest-inputs {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
.form-group {
|
||||||
line-div {
|
label {
|
||||||
display: block;
|
font-family: @font-body;
|
||||||
height: 1px;
|
font-weight: bold;
|
||||||
width: 100%;
|
font-size: smaller;
|
||||||
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
}
|
||||||
mask-image: linear-gradient(270deg, transparent 0%, black 50%, transparent 100%);
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-description {
|
line-div {
|
||||||
opacity: 1;
|
display: block;
|
||||||
transform: translateY(0);
|
height: 1px;
|
||||||
|
width: 100%;
|
||||||
transition:
|
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
||||||
opacity 0.3s ease-out,
|
mask-image: linear-gradient(270deg, transparent 0%, black 50%, transparent 100%);
|
||||||
transform 0.3s ease-out;
|
}
|
||||||
}
|
|
||||||
|
.item-description {
|
||||||
.item-description.invisible {
|
opacity: 1;
|
||||||
height: 0;
|
transform: translateY(0);
|
||||||
opacity: 0;
|
|
||||||
overflow: hidden;
|
transition:
|
||||||
transform: translateY(-20px);
|
opacity 0.3s ease-out,
|
||||||
transform-origin: top;
|
transform 0.3s ease-out;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
.item-description.invisible {
|
||||||
|
height: 0;
|
||||||
|
opacity: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
transform: translateY(-20px);
|
||||||
|
transform-origin: top;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.application.setting.dh-style {
|
||||||
|
fieldset {
|
||||||
|
h2,
|
||||||
|
h3,
|
||||||
|
h4 {
|
||||||
|
margin: 8px 0 4px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.title-hint {
|
||||||
|
font-size: 12px;
|
||||||
|
font-variant: small-caps;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-section {
|
||||||
|
.split-section {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
gap: 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.label-container {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
gap: 10px;
|
||||||
|
|
||||||
|
label {
|
||||||
|
align-self: center;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
footer {
|
||||||
|
margin-top: 8px;
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
|
||||||
|
button {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,52 +1,53 @@
|
||||||
@import '../utils/colors.less';
|
@import '../utils/colors.less';
|
||||||
|
|
||||||
.application.sheet.daggerheart.dh-style {
|
.application.sheet.daggerheart.dh-style {
|
||||||
.item-sheet-header {
|
.item-sheet-header {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
.profile {
|
.profile {
|
||||||
height: 150px;
|
height: 150px;
|
||||||
width: 150px;
|
width: 150px;
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
border-right: 1px solid light-dark(@dark-blue, @golden);
|
border-right: 1px solid light-dark(@dark-blue, @golden);
|
||||||
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-info {
|
.item-info {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
margin-top: 36px;
|
margin-top: 36px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
width: 80%;
|
width: 80%;
|
||||||
|
|
||||||
.item-name input[type='text'] {
|
.item-name input[type='text'] {
|
||||||
font-size: 32px;
|
font-size: 32px;
|
||||||
height: 42px;
|
height: 42px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
width: 90%;
|
width: 90%;
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
outline: 2px solid transparent;
|
outline: 2px solid transparent;
|
||||||
border: 1px solid transparent;
|
border: 1px solid transparent;
|
||||||
|
|
||||||
&:hover[type='text'],
|
&:hover[type='text'],
|
||||||
&:focus[type='text'] {
|
&:focus[type='text'] {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
outline: 2px solid light-dark(@dark-blue, @golden);
|
outline: 2px solid light-dark(@dark-blue, @golden);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-description {
|
.item-description {
|
||||||
display: flex;
|
display: flex;
|
||||||
gap: 10px;
|
flex-direction: column;
|
||||||
}
|
gap: 10px;
|
||||||
|
}
|
||||||
h3 {
|
|
||||||
font-size: 1rem;
|
h3 {
|
||||||
}
|
font-size: 1rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,8 @@
|
||||||
<div class="daggerheart chat roll" data-action="expandRoll">
|
{{#if this.colorful}}
|
||||||
{{#if this.colorful}}
|
<div class="daggerheart chat roll" data-action="expandRoll">
|
||||||
<div class="duality-data">
|
<div class="duality-data">
|
||||||
<div class="duality-title">
|
<div class="duality-title">
|
||||||
<div>{{localize "DAGGERHEART.Chat.AttackRoll.Title" attack=this.title}}</div>
|
<div>{{localize "DAGGERHEART.Chat.AttackRoll.Title" attack=this.title}}</div>
|
||||||
<div class="duality-result-value">{{this.total}}</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="duality-modifiers">
|
<div class="duality-modifiers">
|
||||||
{{#each this.modifiers}}
|
{{#each this.modifiers}}
|
||||||
|
|
@ -62,7 +61,7 @@
|
||||||
</div>
|
</div>
|
||||||
{{#if (not this.damage.value)}}
|
{{#if (not this.damage.value)}}
|
||||||
<div class="duality-result">
|
<div class="duality-result">
|
||||||
<div>{{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
<div>{{this.total}} {{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -83,90 +82,90 @@
|
||||||
<div class="duality-actions">
|
<div class="duality-actions">
|
||||||
<button class="duality-action" data-value="{{this.total}}" data-damage="{{this.damage.value}}" data-damage-type="{{this.damage.type}}" {{#if this.damage.disabled}}disabled{{/if}}><span>Roll Damage</span></button>
|
<button class="duality-action" data-value="{{this.total}}" data-damage="{{this.damage.value}}" data-damage-type="{{this.damage.type}}" {{#if this.damage.disabled}}disabled{{/if}}><span>Roll Damage</span></button>
|
||||||
<div class="duality-result">
|
<div class="duality-result">
|
||||||
<div>{{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
<div>{{this.total}} {{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{else}}
|
</div>
|
||||||
<div class="dice-roll daggerheart chat roll" data-action="expandRoll">
|
{{else}}
|
||||||
<div class="dice-flavor">{{localize "DAGGERHEART.Chat.AttackRoll.Title" attack=this.title}}</div>
|
<div class="dice-roll daggerheart chat roll" data-action="expandRoll">
|
||||||
<div class="dice-result">
|
<div class="dice-flavor">{{localize "DAGGERHEART.Chat.AttackRoll.Title" attack=this.title}}</div>
|
||||||
<div class="dice-formula">{{roll}}</div>
|
<div class="dice-result">
|
||||||
|
<div class="dice-formula">{{roll}}</div>
|
||||||
|
|
||||||
<div class="dice-tooltip">
|
<div class="dice-tooltip">
|
||||||
<div class="wrapper">
|
<div class="wrapper">
|
||||||
<section class="tooltip-part">
|
<section class="tooltip-part">
|
||||||
|
<div class="dice">
|
||||||
|
<header class="part-header flexrow">
|
||||||
|
<span class="part-formula">
|
||||||
|
<span>1{{hope.dice}}</span>
|
||||||
|
|
|
||||||
|
<span>1{{fear.dice}}</span>
|
||||||
|
</span>
|
||||||
|
<span class="part-total">{{this.diceTotal}}</span>
|
||||||
|
</header>
|
||||||
|
<div class="flexrow">
|
||||||
|
<ol class="dice-rolls duality">
|
||||||
|
<li class="roll die {{hope.dice}} {{#if hope.discarded}}discarded{{/if}} hope min" title="{{localize "DAGGERHEART.General.Hope"}}">{{hope.value}}</li>
|
||||||
|
<li class="roll die {{fear.dice}} {{#if fear.discarded}}discarded{{/if}} fear min" title="{{localize "DAGGERHEART.General.Fear"}}">{{fear.value}}</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{#if advantage.value}}
|
||||||
<div class="dice">
|
<div class="dice">
|
||||||
<header class="part-header flexrow">
|
<header class="part-header flexrow">
|
||||||
<span class="part-formula">
|
<span class="part-formula">
|
||||||
<span>1{{hope.dice}}</span>
|
<span>1{{advantage.dice}}</span>
|
||||||
|
|
|
||||||
<span>1{{fear.dice}}</span>
|
|
||||||
</span>
|
</span>
|
||||||
<span class="part-total">{{this.diceTotal}}</span>
|
<span class="part-total">{{advantage.value}}</span>
|
||||||
</header>
|
</header>
|
||||||
<div class="flexrow">
|
<div class="flexrow">
|
||||||
<ol class="dice-rolls duality">
|
<ol class="dice-rolls">
|
||||||
<li class="roll die {{hope.dice}} {{#if hope.discarded}}discarded{{/if}} hope min" title="{{localize "DAGGERHEART.General.Hope"}}">{{hope.value}}</li>
|
<li class="roll die {{advantage.dice}} hope min">{{advantage.value}}</li>
|
||||||
<li class="roll die {{fear.dice}} {{#if fear.discarded}}discarded{{/if}} fear min" title="{{localize "DAGGERHEART.General.Fear"}}">{{fear.value}}</li>
|
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{#if advantage.value}}
|
{{/if}}
|
||||||
<div class="dice">
|
{{#if disadvantage.value}}
|
||||||
<header class="part-header flexrow">
|
<div class="dice">
|
||||||
<span class="part-formula">
|
<header class="part-header flexrow">
|
||||||
<span>1{{advantage.dice}}</span>
|
<span class="part-formula">
|
||||||
</span>
|
<span>1{{disadvantage.dice}}</span>
|
||||||
<span class="part-total">{{advantage.value}}</span>
|
</span>
|
||||||
</header>
|
<span class="part-total">{{disadvantage.value}}</span>
|
||||||
<div class="flexrow">
|
</header>
|
||||||
<ol class="dice-rolls">
|
<div class="flexrow">
|
||||||
<li class="roll die {{advantage.dice}} hope min">{{advantage.value}}</li>
|
<ol class="dice-rolls">
|
||||||
</ol>
|
<li class="roll die {{disadvantage.dice}} hope min">{{disadvantage.value}}</li>
|
||||||
</div>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
|
||||||
{{#if disadvantage.value}}
|
|
||||||
<div class="dice">
|
|
||||||
<header class="part-header flexrow">
|
|
||||||
<span class="part-formula">
|
|
||||||
<span>1{{disadvantage.dice}}</span>
|
|
||||||
</span>
|
|
||||||
<span class="part-total">{{disadvantage.value}}</span>
|
|
||||||
</header>
|
|
||||||
<div class="flexrow">
|
|
||||||
<ol class="dice-rolls">
|
|
||||||
<li class="roll die {{disadvantage.dice}} hope min">{{disadvantage.value}}</li>
|
|
||||||
</ol>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{{/if}}
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="dice-total duality {{#if fear.discarded}}hope{{else}}{{#if hope.discarded}}fear{{else}}critical{{/if}}{{/if}}">
|
|
||||||
<div class="dice-total-label">{{totalLabel}}</div>
|
|
||||||
<div class="dice-total-value">
|
|
||||||
{{this.total}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{{#if (gt targets.length 0)}}
|
|
||||||
<div class="target-section">
|
|
||||||
{{#each targets as |target|}}
|
|
||||||
<div class="dice-total target-container {{#if target.hit}}hit{{else}}{{#if (not ../total.alternate)}}miss{{/if}}{{/if}}" data-token="{{target.id}}">
|
|
||||||
<img src="{{target.img}}" />
|
|
||||||
<div class="target-inner-container">
|
|
||||||
{{#if target.hit}}{{localize "Hit"}}{{else}}{{#if (not ../total.alternate)}}{{localize "Miss"}}{{else}}?{{/if}}{{/if}}
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
{{/each}}
|
{{/if}}
|
||||||
</div>
|
</section>
|
||||||
{{/if}}
|
|
||||||
<div class="flexrow">
|
|
||||||
<button class="roll-damage-button" data-value="{{this.total}}" data-damage="{{this.damage.value}}" data-damage-type="{{this.damage.type}}" {{#if this.damage.disabled}}disabled{{/if}}><span>Roll Damage</span></button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="dice-total duality {{#if fear.discarded}}hope{{else}}{{#if hope.discarded}}fear{{else}}critical{{/if}}{{/if}}">
|
||||||
|
<div class="dice-total-label">{{totalLabel}}</div>
|
||||||
|
<div class="dice-total-value">
|
||||||
|
{{this.total}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{#if (gt targets.length 0)}}
|
||||||
|
<div class="target-section">
|
||||||
|
{{#each targets as |target|}}
|
||||||
|
<div class="dice-total target-container {{#if target.hit}}hit{{else}}{{#if (not ../total.alternate)}}miss{{/if}}{{/if}}" data-token="{{target.id}}">
|
||||||
|
<img src="{{target.img}}" />
|
||||||
|
<div class="target-inner-container">
|
||||||
|
{{#if target.hit}}{{localize "Hit"}}{{else}}{{#if (not ../total.alternate)}}{{localize "Miss"}}{{else}}?{{/if}}{{/if}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{/each}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
<div class="dice-actions">
|
||||||
|
<button class="duality-action" data-value="{{this.total}}" data-damage="{{this.damage.value}}" data-damage-type="{{this.damage.type}}" {{#if this.damage.disabled}}disabled{{/if}}><span>Roll Damage</span></button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
</div>
|
||||||
</div>
|
{{/if}}
|
||||||
|
|
@ -1,9 +1,8 @@
|
||||||
<div class="daggerheart chat roll" data-action="expandRoll">
|
{{#if this.colorful}}
|
||||||
{{#if this.colorful}}
|
<div class="daggerheart chat roll" data-action="expandRoll">
|
||||||
<div class="duality-data">
|
<div class="duality-data">
|
||||||
<div class="duality-title">
|
<div class="duality-title">
|
||||||
<div>{{this.title}}</div>
|
<div>{{this.title}}</div>
|
||||||
<div class="duality-result-value">{{this.total}}</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="duality-modifiers">
|
<div class="duality-modifiers">
|
||||||
{{#each this.modifiers}}
|
{{#each this.modifiers}}
|
||||||
|
|
@ -62,7 +61,7 @@
|
||||||
</div>
|
</div>
|
||||||
{{#if (not this.damage.value)}}
|
{{#if (not this.damage.value)}}
|
||||||
<div class="duality-result">
|
<div class="duality-result">
|
||||||
<div>{{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
<div>{{this.total}} {{#if (eq dualityResult 1)}}With Hope{{else}}{{#if (eq dualityResult 2)}}With Fear{{else}}Critical Success{{/if}}{{/if}}</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -75,7 +74,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{else}}
|
</div>
|
||||||
|
{{else}}
|
||||||
|
<div class="dice-roll daggerheart chat roll" data-action="expandRoll">
|
||||||
<div class="dice-flavor">{{this.title}}</div>
|
<div class="dice-flavor">{{this.title}}</div>
|
||||||
<div class="dice-result">
|
<div class="dice-result">
|
||||||
<div class="dice-formula">{{roll}}</div>
|
<div class="dice-formula">{{roll}}</div>
|
||||||
|
|
@ -138,5 +139,5 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
</div>
|
||||||
</div>
|
{{/if}}
|
||||||
|
|
|
||||||
119
templates/settings/appearance-settings.hbs
Normal file
119
templates/settings/appearance-settings.hbs
Normal file
|
|
@ -0,0 +1,119 @@
|
||||||
|
<div>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{localize "DAGGERHEART.Settings.Menu.Appearance.duality"}}</legend>
|
||||||
|
|
||||||
|
{{formInput settingFields.schema.fields.dualityColorScheme value=settingFields._source.dualityColorScheme localize=true}}
|
||||||
|
|
||||||
|
<h2>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.title"}}</h2>
|
||||||
|
<div class="title-hint">{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.hint"}}</div>
|
||||||
|
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{localize "DAGGERHEART.General.Hope"}}</legend>
|
||||||
|
|
||||||
|
<div class="field-section">
|
||||||
|
<div class="split-section">
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.foreground"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.hope.fields.foreground value=settingFields._source.diceSoNice.hope.foreground localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.background"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.hope.fields.background value=settingFields._source.diceSoNice.hope.background localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.outline"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.hope.fields.outline value=settingFields._source.diceSoNice.hope.outline localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.edge"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.hope.fields.edge value=settingFields._source.diceSoNice.hope.edge localize=true}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{localize "DAGGERHEART.General.Fear"}}</legend>
|
||||||
|
|
||||||
|
<div class="field-section">
|
||||||
|
<div class="split-section">
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.foreground"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.fear.fields.foreground value=settingFields._source.diceSoNice.fear.foreground localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.background"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.fear.fields.background value=settingFields._source.diceSoNice.fear.background localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.outline"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.fear.fields.outline value=settingFields._source.diceSoNice.fear.outline localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.edge"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.fear.fields.edge value=settingFields._source.diceSoNice.fear.edge localize=true}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{localize "DAGGERHEART.General.Advantage.Full"}}</legend>
|
||||||
|
|
||||||
|
<div class="field-section">
|
||||||
|
<div class="split-section">
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.foreground"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.advantage.fields.foreground value=settingFields._source.diceSoNice.advantage.foreground localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.background"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.advantage.fields.background value=settingFields._source.diceSoNice.advantage.background localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.outline"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.advantage.fields.outline value=settingFields._source.diceSoNice.advantage.outline localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.edge"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.advantage.fields.edge value=settingFields._source.diceSoNice.advantage.edge localize=true}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<legend>{{localize "DAGGERHEART.General.Disadvantage.Full"}}</legend>
|
||||||
|
|
||||||
|
<div class="field-section">
|
||||||
|
<div class="split-section">
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.foreground"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.disadvantage.fields.foreground value=settingFields._source.diceSoNice.disadvantage.foreground localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.background"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.disadvantage.fields.background value=settingFields._source.diceSoNice.disadvantage.background localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.outline"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.disadvantage.fields.outline value=settingFields._source.diceSoNice.disadvantage.outline localize=true}}
|
||||||
|
</div>
|
||||||
|
<div class="label-container">
|
||||||
|
<label>{{localize "DAGGERHEART.Settings.Menu.Appearance.DiceSoNice.edge"}}</label>
|
||||||
|
{{formInput settingFields.schema.fields.diceSoNice.fields.disadvantage.fields.edge value=settingFields._source.diceSoNice.disadvantage.edge localize=true}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
</fieldset>
|
||||||
|
|
||||||
|
<footer class="form-footer">
|
||||||
|
<button data-action="reset">
|
||||||
|
<i class="fa-solid fa-arrow-rotate-left"></i>
|
||||||
|
<span>{{localize "Reset"}}</span>
|
||||||
|
</button>
|
||||||
|
<button data-action="save" >
|
||||||
|
<i class="fa-solid fa-floppy-disk"></i>
|
||||||
|
<span>{{localize "Save Changes"}}</span>
|
||||||
|
</button>
|
||||||
|
</footer>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
@ -1,42 +0,0 @@
|
||||||
<div>
|
|
||||||
<header class="flexcol">
|
|
||||||
<div class="title-container">
|
|
||||||
<img class="flex0" src="{{document.img}}" data-edit="img" data-action="onEditImage" title="{{document.name}}" height="64" width="64"/>
|
|
||||||
<div class="title-name">
|
|
||||||
{{formInput fields.name value=source.name rootId=partId}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<section class="sheet-body">
|
|
||||||
{{formField systemFields.baseScore value=source.system.baseScore label=(localize "DAGGERHEART.Sheets.Armor.BaseScore") }}
|
|
||||||
{{formField systemFields.feature value=source.system.feature label=(localize "DAGGERHEART.Sheets.Armor.Feature") localize=true blank=""}}
|
|
||||||
<div class="armor-thresholds">
|
|
||||||
<h2>{{localize "DAGGERHEART.Sheets.Armor.BaseThresholds.Base"}}</h2>
|
|
||||||
{{ formField systemFields.baseThresholds.fields.major value=source.system.baseThresholds.major label=(localize "DAGGERHEART.Sheets.Armor.BaseThresholds.Major") }}/
|
|
||||||
{{ formField systemFields.baseThresholds.fields.severe value=source.system.baseThresholds.severe label=(localize "DAGGERHEART.Sheets.Armor.BaseThresholds.Severe") }}
|
|
||||||
</div>
|
|
||||||
<div class="feature-description">
|
|
||||||
<h2>{{localize "DAGGERHEART.Sheets.Armor.Description"}}</h2>
|
|
||||||
{{formInput systemFields.description value=source.system.description enriched=source.system.description localize=true toggled=true}}
|
|
||||||
</div>
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Armor.BaseScore"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<input type="text" name="system.baseScore" value={{item.system.baseScore}} data-dtype="Number" />
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Armor.Feature"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<select name="system.feature">
|
|
||||||
{{selectOptions config.ITEM.armorFeatures selected=item.system.feature labelAttr="name" localize=true blank="" }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="feature-description">
|
|
||||||
<h2>{{localize "DAGGERHEART.Sheets.Armor.Description"}}</h2>
|
|
||||||
{{editor item.system.description target="system.description" button=true}}
|
|
||||||
</div> --}}
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
|
|
@ -80,13 +80,13 @@
|
||||||
</legend>
|
</legend>
|
||||||
|
|
||||||
<div class="form-group flexrow">
|
<div class="form-group flexrow">
|
||||||
<label>{{localize "DAGGERHEART.Abilities.Agility.Name"}}</label>
|
<label>{{localize "DAGGERHEART.Abilities.agility.name"}}</label>
|
||||||
<div class="form-fields flex0 trait-input">
|
<div class="form-fields flex0 trait-input">
|
||||||
<input type="text" name="system.characterGuide.suggestedTraits.agility" value="{{source.system.characterGuide.suggestedTraits.agility}}" />
|
<input type="text" name="system.characterGuide.suggestedTraits.agility" value="{{source.system.characterGuide.suggestedTraits.agility}}" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group flexrow">
|
<div class="form-group flexrow">
|
||||||
<label>{{localize "DAGGERHEART.Abilities.Strength.Name"}}</label>
|
<label>{{localize "DAGGERHEART.Abilities.strength.Name"}}</label>
|
||||||
<div class="form-fields flex0 trait-input">
|
<div class="form-fields flex0 trait-input">
|
||||||
<input type="text" name="system.characterGuide.suggestedTraits.strength" value="{{source.system.characterGuide.suggestedTraits.strength}}" />
|
<input type="text" name="system.characterGuide.suggestedTraits.strength" value="{{source.system.characterGuide.suggestedTraits.strength}}" />
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
21
templates/sheets/items/armor/header.hbs
Normal file
21
templates/sheets/items/armor/header.hbs
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
<header class='item-sheet-header'>
|
||||||
|
<img class='profile' src='{{source.img}}' data-action='editImage' data-edit='img' />
|
||||||
|
<div class='item-info'>
|
||||||
|
<line-div></line-div>
|
||||||
|
<h1 class='item-name'><input type='text' name='name' value='{{source.name}}' /></h1>
|
||||||
|
<div class='item-description'>
|
||||||
|
<h3>
|
||||||
|
{{localize 'TYPES.Item.armor'}}
|
||||||
|
</h3>
|
||||||
|
<h3>
|
||||||
|
{{localize "DAGGERHEART.Sheets.Armor.baseScore"}}:
|
||||||
|
{{source.system.baseScore}}
|
||||||
|
<span>-</span>
|
||||||
|
{{localize "DAGGERHEART.Sheets.Armor.baseThresholds.base"}}:
|
||||||
|
{{source.system.baseThresholds.major}}
|
||||||
|
<span>/</span>
|
||||||
|
{{source.system.baseThresholds.severe}}
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
21
templates/sheets/items/armor/settings.hbs
Normal file
21
templates/sheets/items/armor/settings.hbs
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
<section
|
||||||
|
class='tab {{tabs.settings.cssClass}} {{tabs.settings.id}}'
|
||||||
|
data-tab='{{tabs.settings.id}}'
|
||||||
|
data-group='{{tabs.settings.group}}'
|
||||||
|
>
|
||||||
|
|
||||||
|
<fieldset class="two-columns">
|
||||||
|
<legend>{{localize tabs.settings.label}}</legend>
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Armor.baseScore"}}</span>
|
||||||
|
{{formField systemFields.baseScore value=source.system.baseScore}}
|
||||||
|
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Armor.feature"}}</span>
|
||||||
|
{{formField systemFields.feature value=source.system.feature localize=true blank=""}}
|
||||||
|
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Armor.baseThresholds.base"}}</span>
|
||||||
|
<div class="nest-inputs">
|
||||||
|
{{ formField systemFields.baseThresholds.fields.major value=source.system.baseThresholds.major label=(localize "DAGGERHEART.Sheets.Armor.baseThresholds.major") }}
|
||||||
|
{{ formField systemFields.baseThresholds.fields.severe value=source.system.baseThresholds.severe label=(localize "DAGGERHEART.Sheets.Armor.baseThresholds.severe") }}
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
</section>
|
||||||
24
templates/sheets/items/weapon/header.hbs
Normal file
24
templates/sheets/items/weapon/header.hbs
Normal file
|
|
@ -0,0 +1,24 @@
|
||||||
|
<header class='item-sheet-header'>
|
||||||
|
<img class='profile' src='{{source.img}}' data-action='editImage' data-edit='img' />
|
||||||
|
<div class='item-info'>
|
||||||
|
<line-div></line-div>
|
||||||
|
<h1 class='item-name'><input type='text' name='name' value='{{source.name}}' /></h1>
|
||||||
|
<div class='item-description'>
|
||||||
|
{{#if source.system.secondary}}
|
||||||
|
<h3>{{localize "DAGGERHEART.Sheets.Weapon.SecondaryWeapon"}}</h3>
|
||||||
|
{{else}}
|
||||||
|
<h3>{{localize "DAGGERHEART.Sheets.Weapon.PrimaryWeapon"}}</h3>
|
||||||
|
{{/if}}
|
||||||
|
<h3>
|
||||||
|
{{localize (concat 'DAGGERHEART.Abilities.' source.system.trait '.short')}}
|
||||||
|
<span>-</span>
|
||||||
|
{{localize (concat 'DAGGERHEART.Range.' source.system.range '.name')}}
|
||||||
|
<span>-</span>
|
||||||
|
{{source.system.damage.value}}
|
||||||
|
({{localize (concat 'DAGGERHEART.DamageType.' source.system.damage.type '.abbreviation')}})
|
||||||
|
<span>-</span>
|
||||||
|
{{localize (concat 'DAGGERHEART.Burden.' source.system.burden)}}
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
30
templates/sheets/items/weapon/settings.hbs
Normal file
30
templates/sheets/items/weapon/settings.hbs
Normal file
|
|
@ -0,0 +1,30 @@
|
||||||
|
<section
|
||||||
|
class='tab {{tabs.settings.cssClass}} {{tabs.settings.id}}'
|
||||||
|
data-tab='{{tabs.settings.id}}'
|
||||||
|
data-group='{{tabs.settings.group}}'
|
||||||
|
>
|
||||||
|
<fieldset class="two-columns">
|
||||||
|
<legend>{{localize tabs.settings.label}}</legend>
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.SecondaryWeapon"}}</span>
|
||||||
|
{{formField systemFields.secondary value=source.system.secondary}}
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Trait"}}</span>
|
||||||
|
{{formField systemFields.trait value=source.system.trait localize=true}}
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Range"}}</span>
|
||||||
|
{{formField systemFields.range value=source.system.range localize=true}}
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Burden"}}</span>
|
||||||
|
{{formField systemFields.burden value=source.system.burden localize=true}}
|
||||||
|
</fieldset>
|
||||||
|
|
||||||
|
<fieldset class="two-columns">
|
||||||
|
<legend>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Title"}}</legend>
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Value"}}</span>
|
||||||
|
{{formGroup systemFields.damage.fields.value value=source.system.damage.value}}
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Type"}}</span>
|
||||||
|
{{formGroup systemFields.damage.fields.type value=source.system.damage.type localize=true}}
|
||||||
|
</fieldset>
|
||||||
|
<fieldset class="two-columns">
|
||||||
|
<legend>{{localize "DAGGERHEART.Sheets.Weapon.Feature"}}</legend>
|
||||||
|
<span>{{localize "DAGGERHEART.Sheets.Weapon.Feature"}}</span>
|
||||||
|
{{formField systemFields.feature value=source.system.feature localize=true}}
|
||||||
|
</fieldset>
|
||||||
|
</section>
|
||||||
|
|
@ -1,86 +0,0 @@
|
||||||
<div>
|
|
||||||
<header class="flexcol">
|
|
||||||
{{!-- <div class="flexrow">
|
|
||||||
<img class="flex0" src="{{item.img}}" data-edit="img" title="{{item.name}}" height="64" width="64"/>
|
|
||||||
<div class="title-name">
|
|
||||||
<h2><input name="name" type="text" value="{{item.name}}" placeholder="{{ localize 'Name' }}"/></h2>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
<div class="title-container">
|
|
||||||
<img class="flex0" src="{{document.img}}" data-edit="img" data-action="onEditImage" title="{{document.name}}" height="64" width="64"/>
|
|
||||||
<div class="title-name">
|
|
||||||
{{formInput fields.name value=source.name rootId=partId}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<section class="sheet-body">
|
|
||||||
{{formField systemFields.secondary value=source.system.secondary label=(localize "DAGGERHEART.Sheets.Weapon.SecondaryWeapon") }}
|
|
||||||
{{formField systemFields.trait value=source.system.trait label=(localize "DAGGERHEART.Sheets.Weapon.Trait") localize=true }}
|
|
||||||
{{formField systemFields.range value=source.system.range label=(localize "DAGGERHEART.Sheets.Weapon.Range") localize=true }}
|
|
||||||
<div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Title"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
{{formGroup systemFields.damage.fields.value value=source.system.damage.value label=(localize "DAGGERHEART.Sheets.Weapon.Damage.Value") }}
|
|
||||||
{{formGroup systemFields.damage.fields.type value=source.system.damage.type label=(localize "DAGGERHEART.Sheets.Weapon.Damage.Type") localize=true }}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{{formField systemFields.burden value=source.system.burden label=(localize "DAGGERHEART.Sheets.Weapon.Burden") localize=true }}
|
|
||||||
{{formField systemFields.feature value=source.system.feature label=(localize "DAGGERHEART.Sheets.Weapon.Feature") localize=true }}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.SecondaryWeapon"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<input type="checkbox" name="system.secondary" {{checked item.system.secondary}} />
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Trait"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<select name="system.trait">
|
|
||||||
{{selectOptions config.ACTOR.abilities selected=item.system.trait labelAttr="name" localize=true }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Range"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<select name="system.range">
|
|
||||||
{{selectOptions config.GENERAL.range selected=item.system.range labelAttr="name" localize=true }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Title"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Value"}}</label>
|
|
||||||
<input type="text" name="system.damage.value" value="{{item.system.damage.value}}" />
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Damage.Type"}}</label>
|
|
||||||
<select name="system.damage.type">
|
|
||||||
{{selectOptions config.GENERAL.damageTypes selected=item.system.damage.type labelAttr="name" localize=true }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Burden"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<select name="system.burden">
|
|
||||||
{{selectOptions config.GENERAL.burden selected=item.system.burden localize=true }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
{{!-- <div class="form-group">
|
|
||||||
<label>{{localize "DAGGERHEART.Sheets.Weapon.Feature"}}</label>
|
|
||||||
<div class="form-fields">
|
|
||||||
<select name="system.feature">
|
|
||||||
{{selectOptions config.ITEM.weaponFeatures selected=item.system.feature labelAttr="name" localize=true blank="" }}
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div> --}}
|
|
||||||
<div class="feature-description">
|
|
||||||
<h2>{{localize "DAGGERHEART.Sheets.Weapon.Description"}}</h2>
|
|
||||||
{{formInput systemFields.description value=source.system.description enriched=source.system.description localize=true toggled=true}}
|
|
||||||
{{!-- {{editor item.system.description target="system.description" button=true}} --}}
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<div>
|
<div>
|
||||||
<header>
|
<header>
|
||||||
{{formField fields.name value=source.name label="Name" rootId=partId}}
|
{{formField fields.name value=source.name label="Name" name="name" rootId=partId}}
|
||||||
<nav class="sheet-tabs tabs">
|
<nav class="sheet-tabs tabs">
|
||||||
{{#each tabs as |tab|}}
|
{{#each tabs as |tab|}}
|
||||||
<a class="{{tab.cssClass}}" data-action="tab" data-group="{{tab.group}}" data-tab="{{tab.id}}">
|
<a class="{{tab.cssClass}}" data-action="tab" data-group="{{tab.group}}" data-tab="{{tab.id}}">
|
||||||
|
|
@ -15,23 +15,21 @@
|
||||||
<fieldset class="action-category">
|
<fieldset class="action-category">
|
||||||
<legend class="action-category-label" data-action="toggleSection" data-section="damage">
|
<legend class="action-category-label" data-action="toggleSection" data-section="damage">
|
||||||
<div>Damage</div>
|
<div>Damage</div>
|
||||||
<i class="fa-solid {{#if (eq openSection 'damage')}}fa-angle-up{{else}}fa-angle-down{{/if}}"></i>
|
|
||||||
</legend>
|
</legend>
|
||||||
|
|
||||||
<div class="action-category-data {{#if (eq openSection 'damage')}}open{{/if}}">
|
<div class="action-category-data open">
|
||||||
{{formField fields.damage.fields.type value=source.damage.type label="Damage Type" rootId=partId localize=true}}
|
{{formField fields.damage.fields.type value=source.damage.type label="Damage Type" name="damage.type" rootId=partId localize=true}}
|
||||||
{{formField fields.damage.fields.value value=source.damage.value label="Damage" rootId=partId localize=true}}
|
{{formField fields.damage.fields.value value=source.damage.value label="Damage" name="damage.value" rootId=partId localize=true}}
|
||||||
</div>
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset class="action-category">
|
<fieldset class="action-category">
|
||||||
<legend class="action-category-label" data-action="toggleSection" data-section="healing">
|
<legend class="action-category-label" data-action="toggleSection" data-section="healing">
|
||||||
<div>Healing</div>
|
<div>Healing</div>
|
||||||
<i class="fa-solid {{#if (eq openSection 'healing')}}fa-angle-up{{else}}fa-angle-down{{/if}}"></i>
|
|
||||||
</legend>
|
</legend>
|
||||||
|
|
||||||
<div class="action-category-data {{#if (eq openSection 'healing')}}open{{/if}}">
|
<div class="action-category-data open ">
|
||||||
{{formField fields.healing.fields.type value=source.healing.type label="Healing Type" rootId=partId localize=true}}
|
{{formField fields.healing.fields.type value=source.healing.type label="Healing Type" name="healing.type" rootId=partId localize=true}}
|
||||||
{{formField fields.healing.fields.value value=source.healing.value label="Healing" rootId=partId localize=true}}
|
{{formField fields.healing.fields.value value=source.healing.value label="Healing" name="healing.value" rootId=partId localize=true}}
|
||||||
</div>
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -39,16 +37,15 @@
|
||||||
<fieldset class="action-category">
|
<fieldset class="action-category">
|
||||||
<legend class="action-category-label" data-action="toggleSection" data-section="cost">
|
<legend class="action-category-label" data-action="toggleSection" data-section="cost">
|
||||||
<div>Cost</div>
|
<div>Cost</div>
|
||||||
<i class="fa-solid {{#if (eq openSection 'cost')}}fa-angle-up{{else}}fa-angle-down{{/if}}"></i>
|
|
||||||
</legend>
|
</legend>
|
||||||
|
|
||||||
<div class="action-category-data {{#if (eq openSection 'cost')}}open{{/if}}">
|
<div class="action-category-data open ">
|
||||||
{{formField fields.cost.fields.type value=source.cost.type label="Cost Type" rootId=partId}}
|
{{formField fields.cost.fields.type value=source.cost.type label="Cost Type" name="cost.type" rootId=partId}}
|
||||||
{{formField fields.cost.fields.value value=source.cost.value label="Value" rootId=partId}}
|
{{formField fields.cost.fields.value value=source.cost.value label="Value" name="cost.value" rootId=partId}}
|
||||||
</div>
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
{{formField fields.target.fields.type value=source.target.type label="Target Type" rootId=partId}}
|
{{formField fields.target.fields.type value=source.target.type label="Target Type" name="target.type" rootId=partId}}
|
||||||
</div>
|
</div>
|
||||||
<div class="tab {{this.tabs.conditions.cssClass}}" data-group="primary" data-tab="conditions">
|
<div class="tab {{this.tabs.conditions.cssClass}}" data-group="primary" data-tab="conditions">
|
||||||
{{!-- <h2>
|
{{!-- <h2>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue