forked from public/foundryvtt-reve-de-dragon
#103 : Gerer les augmentations de niveaux en comp et carac
This commit is contained in:
@ -45,6 +45,8 @@ const carac_array = [ "taille", "apparence", "constitution", "force", "agilite",
|
||||
const difficultesLibres = [0, -1, -2, -3, -4, -5, -6, -7, -8, -9, -10];
|
||||
const ajustementsConditions = [-10, -9, -8, -7, -6, -5, -4, -3, -2, -1, 0, +1, +2, +3, +4, +5, +6, +7, +8, +9, +10];
|
||||
const ajustementsEncaissement = [-10, -9, -8, -7, -6, -5, -4, -3, -2, -1, 0, +1, +2, +3, +4, +5, +6, +7, +8, +9, +10, +11, +12, +13, +14, +15, +16, +17, +18, +19, +20, +21, +22, +23, +24, +25];
|
||||
const carac_xp_par_valeur = [6, 6, 7, 7, 8, 8, 9, 9, 10, 20, 30, 40, 50, 60, 70];
|
||||
const XP_CARAC_OFFSET = 7;
|
||||
|
||||
/* -------------------------------------------- */
|
||||
function _buildAllSegmentsFatigue(max) {
|
||||
@ -208,7 +210,8 @@ export class RdDUtility {
|
||||
'systems/foundryvtt-reve-de-dragon/templates/chat-resultat-tache.html',
|
||||
'systems/foundryvtt-reve-de-dragon/templates/chat-resultat-sort.html',
|
||||
'systems/foundryvtt-reve-de-dragon/templates/chat-actor-turn-summary.html',
|
||||
|
||||
'systems/foundryvtt-reve-de-dragon/templates/chat-actor-competence-xp.html',
|
||||
'systems/foundryvtt-reve-de-dragon/templates/chat-actor-carac-xp.html'
|
||||
];
|
||||
|
||||
return loadTemplates(templatePaths);
|
||||
@ -406,6 +409,16 @@ export class RdDUtility {
|
||||
return false;
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static getCaracNextXp( value ) {
|
||||
return carac_xp_par_valeur[value - XP_CARAC_OFFSET];
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static getCompetenceNextXp( niveau ) {
|
||||
return competence_xp_par_niveau[niveau+10];
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static computeCompetenceXPCost( competence )
|
||||
{
|
||||
|
Reference in New Issue
Block a user