forked from public/foundryvtt-reve-de-dragon
		
	Encaissement jusqu'à +25
This commit is contained in:
		@@ -118,7 +118,7 @@ export class RdDActorSheet extends ActorSheet {
 | 
				
			|||||||
  
 | 
					  
 | 
				
			||||||
  /* -------------------------------------------- */
 | 
					  /* -------------------------------------------- */
 | 
				
			||||||
  async displayDialogEncaisser( ) {
 | 
					  async displayDialogEncaisser( ) {
 | 
				
			||||||
    let data = { ajustementsConditions: CONFIG.RDD.ajustementsConditions /* techniquement on peut encaisser à +20 */ };
 | 
					    let data = { ajustementsEncaissement: RdDUtility.getAjustementsEncaissement() };
 | 
				
			||||||
    let html = await renderTemplate('systems/foundryvtt-reve-de-dragon/templates/dialog-roll-encaisser.html', data );
 | 
					    let html = await renderTemplate('systems/foundryvtt-reve-de-dragon/templates/dialog-roll-encaisser.html', data );
 | 
				
			||||||
    new RdDEncaisser(html, this.actor ).render(true);
 | 
					    new RdDEncaisser(html, this.actor ).render(true);
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -28,6 +28,8 @@ const competence_xp_par_niveau = [ 5, 5, 5, 10, 10, 10, 10, 15, 15, 15, 15, 20,
 | 
				
			|||||||
const carac_array = [ "taille", "apparence", "constitution", "force", "agilite", "dexterite", "vue", "ouie", "odoratgout", "volonte", "intellect", "empathie", "reve", "chance", "melee", "tir", "lancer", "derobee"];
 | 
					const carac_array = [ "taille", "apparence", "constitution", "force", "agilite", "dexterite", "vue", "ouie", "odoratgout", "volonte", "intellect", "empathie", "reve", "chance", "melee", "tir", "lancer", "derobee"];
 | 
				
			||||||
const difficultesLibres  = [0, -1, -2, -3, -4, -5, -6, -7, -8, -9, -10];
 | 
					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 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];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function _buildAllSegmentsFatigue(max) {
 | 
					function _buildAllSegmentsFatigue(max) {
 | 
				
			||||||
  const cycle = [5, 2, 4, 1, 3, 0];
 | 
					  const cycle = [5, 2, 4, 1, 3, 0];
 | 
				
			||||||
@@ -298,6 +300,10 @@ export class RdDUtility  {
 | 
				
			|||||||
  {
 | 
					  {
 | 
				
			||||||
    return ajustementsConditions;
 | 
					    return ajustementsConditions;
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  static getAjustementsEncaissement()
 | 
				
			||||||
 | 
					  {
 | 
				
			||||||
 | 
					    return ajustementsEncaissement;
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  static getDefinitionsBlessures() {
 | 
					  static getDefinitionsBlessures() {
 | 
				
			||||||
    return definitionsBlessures;
 | 
					    return definitionsBlessures;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -4,7 +4,7 @@
 | 
				
			|||||||
  <label class="competence-label">Modificateurs aux Dommages:</label>
 | 
					  <label class="competence-label">Modificateurs aux Dommages:</label>
 | 
				
			||||||
  <select class="competence-value" name="modificateurDegats" id="modificateurDegats" data-dtype="number">
 | 
					  <select class="competence-value" name="modificateurDegats" id="modificateurDegats" data-dtype="number">
 | 
				
			||||||
      {{#select modificateurDegats}}
 | 
					      {{#select modificateurDegats}}
 | 
				
			||||||
      {{#each ajustementsConditions as |key|}}
 | 
					      {{#each ajustementsEncaissement as |key|}}
 | 
				
			||||||
      <option value={{key}}>{{numberFormat key decimals=0 sign=true}}</option>
 | 
					      <option value={{key}}>{{numberFormat key decimals=0 sign=true}}</option>
 | 
				
			||||||
      {{/each}}
 | 
					      {{/each}}
 | 
				
			||||||
      {{/select}}
 | 
					      {{/select}}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user