Register some settings for the system, including some developer-only settings
This commit is contained in:
parent
a2a72792a2
commit
2026785b09
6 changed files with 43 additions and 0 deletions
|
|
@ -1,4 +1,8 @@
|
||||||
{
|
{
|
||||||
|
"dotdungeon.settings.showAvatarOnSheet.name": "Show Avatar On Player Sheet",
|
||||||
|
"dotdungeon.settings.showAvatarOnSheet.description": "Determines whether or not to show the avatar to you on the Player Character sheets, turning this off will replace the image with a file picker so that you can still change the image from the character sheet.",
|
||||||
|
|
||||||
|
|
||||||
"dotdungeon.sheet.PlayerSheet": "PC Sheet",
|
"dotdungeon.sheet.PlayerSheet": "PC Sheet",
|
||||||
"dotdungeon.sheet.AspectSheet": "Aspect Sheet",
|
"dotdungeon.sheet.AspectSheet": "Aspect Sheet",
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -18,8 +18,15 @@ import * as hbs from "./handlebars.mjs";
|
||||||
import "./hooks/hotReload.mjs";
|
import "./hooks/hotReload.mjs";
|
||||||
|
|
||||||
|
|
||||||
|
// Misc Imports
|
||||||
|
import loadSettings from "./settings/index.mjs";
|
||||||
|
|
||||||
|
|
||||||
Hooks.once(`init`, () => {
|
Hooks.once(`init`, () => {
|
||||||
console.debug(`.dungeon | Initializing`);
|
console.debug(`.dungeon | Initializing`);
|
||||||
|
|
||||||
|
loadSettings();
|
||||||
|
|
||||||
game.boilerplate = {
|
game.boilerplate = {
|
||||||
PlayerActor,
|
PlayerActor,
|
||||||
AspectItem,
|
AspectItem,
|
||||||
|
|
|
||||||
11
module/settings/client_settings.mjs
Normal file
11
module/settings/client_settings.mjs
Normal file
|
|
@ -0,0 +1,11 @@
|
||||||
|
export default function() {
|
||||||
|
game.settings.register(`dotdungeon`, `showAvatarOnSheet`, {
|
||||||
|
name: `dotdungeon.settings.showAvatarOnSheet.name`,
|
||||||
|
hint: `dotdungeon.settings.showAvatarOnSheet.description`,
|
||||||
|
scope: `client`,
|
||||||
|
type: Boolean,
|
||||||
|
config: true,
|
||||||
|
default: true,
|
||||||
|
requiresReload: false,
|
||||||
|
});
|
||||||
|
};
|
||||||
9
module/settings/dev_settings.mjs
Normal file
9
module/settings/dev_settings.mjs
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
export default function() {
|
||||||
|
game.settings.register(`dotdungeon`, `devMode`, {
|
||||||
|
scope: `client`,
|
||||||
|
type: Boolean,
|
||||||
|
config: false,
|
||||||
|
default: false,
|
||||||
|
requiresReload: false,
|
||||||
|
});
|
||||||
|
};
|
||||||
7
module/settings/index.mjs
Normal file
7
module/settings/index.mjs
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
import registerClientSettings from "./client_settings.mjs";
|
||||||
|
import registerDevSettings from "./dev_settings.mjs";
|
||||||
|
|
||||||
|
export default function registerSettings() {
|
||||||
|
registerClientSettings();
|
||||||
|
registerDevSettings();
|
||||||
|
};
|
||||||
|
|
@ -43,6 +43,11 @@
|
||||||
select, select:hover {
|
select, select:hover {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.debug-data {
|
||||||
|
opacity: 60%;
|
||||||
|
font-family: $body-font;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Styling that doesn't belong to any particular part of my sheet
|
// Styling that doesn't belong to any particular part of my sheet
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue