Extraction des settings dans une méthode dédiée
This commit is contained in:
parent
2ca601b5f8
commit
fbd3aa7121
@ -77,80 +77,7 @@ export class SystemReveDeDragon {
|
|||||||
RdDUtility.preloadHandlebarsTemplates();
|
RdDUtility.preloadHandlebarsTemplates();
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
game.settings.register(SYSTEM_RDD, "accorder-entite-cauchemar", {
|
this.initSystemSettings();
|
||||||
name: "Accorder le rêve aux entités",
|
|
||||||
hint: "A quel moment les personnages doivent accorder leur rêve aux entités de cauchemar",
|
|
||||||
scope: "world",
|
|
||||||
config: true,
|
|
||||||
type: String,
|
|
||||||
choices: { // If choices are defined, the resulting setting will be a select menu
|
|
||||||
"avant-attaque": "Avant l'attaque",
|
|
||||||
"avant-defense": "Avant la défense",
|
|
||||||
"avant-encaissement": "Avant l'encaissement",
|
|
||||||
},
|
|
||||||
default: "avant-encaissement"
|
|
||||||
});
|
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "calendrier", {
|
|
||||||
name: "calendrier",
|
|
||||||
scope: "world",
|
|
||||||
config: false,
|
|
||||||
default: RdDCalendrier.createCalendrierInitial(),
|
|
||||||
type: Object
|
|
||||||
});
|
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "liste-nombre-astral", {
|
|
||||||
name: "liste-nombre-astral",
|
|
||||||
scope: "world",
|
|
||||||
config: false,
|
|
||||||
default: [],
|
|
||||||
type: Object
|
|
||||||
});
|
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "calendrier-pos", {
|
|
||||||
name: "calendrierPos",
|
|
||||||
scope: "client",
|
|
||||||
config: false,
|
|
||||||
default: RdDCalendrier.createCalendrierPos(),
|
|
||||||
type: Object
|
|
||||||
});
|
|
||||||
|
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "supprimer-dialogues-combat-chat", {
|
|
||||||
name: "Supprimer les dialogues de combat",
|
|
||||||
hint: "Si désactivée, tous les dialogues de combat sont conservés dans la conversation",
|
|
||||||
scope: "world",
|
|
||||||
config: true,
|
|
||||||
default: true,
|
|
||||||
type: Boolean
|
|
||||||
});
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "activer-sons-audio", {
|
|
||||||
name: "Activer les bruitages intégrés",
|
|
||||||
hint: "Si activé, certaines actions en jeu déclenchent un son d'ambiance",
|
|
||||||
scope: "world",
|
|
||||||
config: true,
|
|
||||||
default: true,
|
|
||||||
type: Boolean
|
|
||||||
});
|
|
||||||
/* -------------------------------------------- */
|
|
||||||
game.settings.register(SYSTEM_RDD, "appliquer-famine-soif", {
|
|
||||||
name: "Notifier de la famine et la soif pour",
|
|
||||||
hint: "Indique si les cas de famine et de soif seront indiqués durant Château Dormant",
|
|
||||||
scope: "world",
|
|
||||||
config: true,
|
|
||||||
type: String,
|
|
||||||
choices: {
|
|
||||||
"aucun": "ni la famine, ni la soif",
|
|
||||||
"famine": "seulement la famine",
|
|
||||||
"famine-soif": "la famine et la soif",
|
|
||||||
},
|
|
||||||
default: "aucun"
|
|
||||||
});
|
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
// Set an initiative formula for the system
|
// Set an initiative formula for the system
|
||||||
@ -235,6 +162,84 @@ export class SystemReveDeDragon {
|
|||||||
Hooks.once('ready', () => this.onReady());
|
Hooks.once('ready', () => this.onReady());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
initSystemSettings() {
|
||||||
|
game.settings.register(SYSTEM_RDD, "accorder-entite-cauchemar", {
|
||||||
|
name: "Accorder le rêve aux entités",
|
||||||
|
hint: "A quel moment les personnages doivent accorder leur rêve aux entités de cauchemar",
|
||||||
|
scope: "world",
|
||||||
|
config: true,
|
||||||
|
type: String,
|
||||||
|
choices: {
|
||||||
|
"avant-attaque": "Avant l'attaque",
|
||||||
|
"avant-defense": "Avant la défense",
|
||||||
|
"avant-encaissement": "Avant l'encaissement",
|
||||||
|
},
|
||||||
|
default: "avant-encaissement"
|
||||||
|
});
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "calendrier", {
|
||||||
|
name: "calendrier",
|
||||||
|
scope: "world",
|
||||||
|
config: false,
|
||||||
|
default: RdDCalendrier.createCalendrierInitial(),
|
||||||
|
type: Object
|
||||||
|
});
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "liste-nombre-astral", {
|
||||||
|
name: "liste-nombre-astral",
|
||||||
|
scope: "world",
|
||||||
|
config: false,
|
||||||
|
default: [],
|
||||||
|
type: Object
|
||||||
|
});
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "calendrier-pos", {
|
||||||
|
name: "calendrierPos",
|
||||||
|
scope: "client",
|
||||||
|
config: false,
|
||||||
|
default: RdDCalendrier.createCalendrierPos(),
|
||||||
|
type: Object
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "supprimer-dialogues-combat-chat", {
|
||||||
|
name: "Supprimer les dialogues de combat",
|
||||||
|
hint: "Si désactivée, tous les dialogues de combat sont conservés dans la conversation",
|
||||||
|
scope: "world",
|
||||||
|
config: true,
|
||||||
|
default: true,
|
||||||
|
type: Boolean
|
||||||
|
});
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "activer-sons-audio", {
|
||||||
|
name: "Activer les bruitages intégrés",
|
||||||
|
hint: "Si activé, certaines actions en jeu déclenchent un son d'ambiance",
|
||||||
|
scope: "world",
|
||||||
|
config: true,
|
||||||
|
default: true,
|
||||||
|
type: Boolean
|
||||||
|
});
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
game.settings.register(SYSTEM_RDD, "appliquer-famine-soif", {
|
||||||
|
name: "Notifier de la famine et la soif pour",
|
||||||
|
hint: "Indique si les cas de famine et de soif seront indiqués durant Château Dormant",
|
||||||
|
scope: "world",
|
||||||
|
config: true,
|
||||||
|
type: String,
|
||||||
|
choices: {
|
||||||
|
"aucun": "ni la famine, ni la soif",
|
||||||
|
"famine": "seulement la famine",
|
||||||
|
"famine-soif": "la famine et la soif",
|
||||||
|
},
|
||||||
|
default: "aucun"
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
async onReady() {
|
async onReady() {
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
|
Loading…
Reference in New Issue
Block a user