forked from GitHub-Mirrors/foundry-sw5e
Initial styling config and auto-format of files
This commit is contained in:
parent
e8d4153333
commit
42ddf4b0d0
33 changed files with 2965 additions and 2566 deletions
|
@ -24,8 +24,8 @@ export default class LongRestDialog extends Dialog {
|
|||
getData() {
|
||||
const data = super.getData();
|
||||
const variant = game.settings.get("sw5e", "restVariant");
|
||||
data.promptNewDay = variant !== "gritty"; // It's always a new day when resting 1 week
|
||||
data.newDay = variant === "normal"; // It's probably a new day when resting normally (8 hours)
|
||||
data.promptNewDay = variant !== "gritty"; // It's always a new day when resting 1 week
|
||||
data.newDay = variant === "normal"; // It's probably a new day when resting normally (8 hours)
|
||||
return data;
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,7 @@ export default class LongRestDialog extends Dialog {
|
|||
* @param {Actor5e} actor
|
||||
* @return {Promise}
|
||||
*/
|
||||
static async longRestDialog({ actor } = {}) {
|
||||
static async longRestDialog({actor} = {}) {
|
||||
return new Promise((resolve, reject) => {
|
||||
const dlg = new this(actor, {
|
||||
title: "Long Rest",
|
||||
|
@ -49,8 +49,7 @@ export default class LongRestDialog extends Dialog {
|
|||
let newDay = false;
|
||||
if (game.settings.get("sw5e", "restVariant") === "normal")
|
||||
newDay = html.find('input[name="newDay"]')[0].checked;
|
||||
else if(game.settings.get("sw5e", "restVariant") === "gritty")
|
||||
newDay = true;
|
||||
else if (game.settings.get("sw5e", "restVariant") === "gritty") newDay = true;
|
||||
resolve(newDay);
|
||||
}
|
||||
},
|
||||
|
@ -60,10 +59,10 @@ export default class LongRestDialog extends Dialog {
|
|||
callback: reject
|
||||
}
|
||||
},
|
||||
default: 'rest',
|
||||
default: "rest",
|
||||
close: reject
|
||||
});
|
||||
dlg.render(true);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue