foundry-sw5e/module/settings.js
supervj 68a1b6a9f0 System 1.1.1 ** Requires Foundry 0.7.6
System main update to be inline with dnd5e 1.1.1

Added active effects to as many sheets as I thought applicable. Please check loot, I made an attempt but it may be broken

All .less .css and actor .html updates were made to the old actors.  New actors may be broken with this update

removed templates\actors\oldActor\parts\actor-effects.html for newer templates\actors\parts\active-effects.html

removed module\apps\cast-dialog, templates\apps\cast-cast.html, and templates\items\cast.html.  I do not think they are used, I think they were deprecated when powers were treated as items, if not we can add them back in.

**NOTE** REQUIRES Foundry 0.7.6
2020-11-12 17:30:07 -05:00

145 lines
3.3 KiB
JavaScript

export const registerSystemSettings = function() {
/**
* Track the system version upon which point a migration was last applied
*/
game.settings.register("sw5e", "systemMigrationVersion", {
name: "System Migration Version",
scope: "world",
config: false,
type: String,
default: ""
});
/**
* Register resting variants
*/
game.settings.register("sw5e", "restVariant", {
name: "SETTINGS.5eRestN",
hint: "SETTINGS.5eRestL",
scope: "world",
config: true,
default: "normal",
type: String,
choices: {
"normal": "SETTINGS.5eRestPHB",
"gritty": "SETTINGS.5eRestGritty",
"epic": "SETTINGS.5eRestEpic",
}
});
/**
* Register diagonal movement rule setting
*/
game.settings.register("sw5e", "diagonalMovement", {
name: "SETTINGS.5eDiagN",
hint: "SETTINGS.5eDiagL",
scope: "world",
config: true,
default: "555",
type: String,
choices: {
"555": "SETTINGS.5eDiagPHB",
"5105": "SETTINGS.5eDiagDMG",
"EUCL": "SETTINGS.5eDiagEuclidean",
},
onChange: rule => canvas.grid.diagonalRule = rule
});
/**
* Register Initiative formula setting
*/
game.settings.register("sw5e", "initiativeDexTiebreaker", {
name: "SETTINGS.5eInitTBN",
hint: "SETTINGS.5eInitTBL",
scope: "world",
config: true,
default: false,
type: Boolean
});
/**
* Require Currency Carrying Weight
*/
game.settings.register("sw5e", "currencyWeight", {
name: "SETTINGS.5eCurWtN",
hint: "SETTINGS.5eCurWtL",
scope: "world",
config: true,
default: true,
type: Boolean
});
/**
* Option to disable XP bar for session-based or story-based advancement.
*/
game.settings.register("sw5e", "disableExperienceTracking", {
name: "SETTINGS.5eNoExpN",
hint: "SETTINGS.5eNoExpL",
scope: "world",
config: true,
default: false,
type: Boolean,
});
/**
* Option to automatically collapse Item Card descriptions
*/
game.settings.register("sw5e", "autoCollapseItemCards", {
name: "SETTINGS.5eAutoCollapseCardN",
hint: "SETTINGS.5eAutoCollapseCardL",
scope: "client",
config: true,
default: false,
type: Boolean,
onChange: s => {
ui.chat.render();
}
});
/**
* Option to allow GMs to restrict polymorphing to GMs only.
*/
game.settings.register('sw5e', 'allowPolymorphing', {
name: 'SETTINGS.5eAllowPolymorphingN',
hint: 'SETTINGS.5eAllowPolymorphingL',
scope: 'world',
config: true,
default: false,
type: Boolean
});
/**
* Remember last-used polymorph settings.
*/
game.settings.register('sw5e', 'polymorphSettings', {
scope: 'client',
default: {
keepPhysical: false,
keepMental: false,
keepSaves: false,
keepSkills: false,
mergeSaves: false,
mergeSkills: false,
keepClass: false,
keepFeats: false,
keepPowers: false,
keepItems: false,
keepBio: false,
keepVision: true,
transformTokens: true
}
});
game.settings.register("sw5e", "colorTheme", {
name: "SETTINGS.SWColorN",
hint: "SETTINGS.SWColorL",
scope: "world",
config: true,
default: "light",
type: String,
choices: {
"light": "SETTINGS.SWColorLight",
"dark": "SETTINGS.SWColorDark"
}
});
};