Fix rolls and various glitches
This commit is contained in:
parent
26a5cdcffb
commit
da5b2bf785
@ -505,8 +505,10 @@ export class YggdrasillActor extends Actor {
|
|||||||
rollMode: game.settings.get("core", "rollMode"),
|
rollMode: game.settings.get("core", "rollMode"),
|
||||||
title: title,
|
title: title,
|
||||||
isBlesse: this.data.data.etat.etat == "blesse",
|
isBlesse: this.data.data.etat.etat == "blesse",
|
||||||
optionsBonusMalus: YggdrasillUtility.buildListOptions(-6, +6),
|
optionsBonusMalus: YggdrasillUtility.buildListOptions(-15, +15),
|
||||||
bonusMalus: 0,
|
bonusMalus: 0,
|
||||||
|
bonusdefense: 0,
|
||||||
|
optionsBD: YggdrasillUtility.buildListOptions(0, +15),
|
||||||
optionsSR: YggdrasillUtility.buildSROptions( ),
|
optionsSR: YggdrasillUtility.buildSROptions( ),
|
||||||
sr: 0
|
sr: 0
|
||||||
}
|
}
|
||||||
@ -535,11 +537,12 @@ export class YggdrasillActor extends Actor {
|
|||||||
isEpuise: this.isEpuise(),
|
isEpuise: this.isEpuise(),
|
||||||
isBlesse: this.isBlesse(),
|
isBlesse: this.isBlesse(),
|
||||||
isMeurtri: this.isMeurtri(),
|
isMeurtri: this.isMeurtri(),
|
||||||
optionsBonusMalus: YggdrasillUtility.buildListOptions(-6, +6),
|
optionsBonusMalus: YggdrasillUtility.buildListOptions(-15, +15),
|
||||||
bonusMalus: 0,
|
bonusMalus: 0,
|
||||||
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
||||||
furorUsage: 0,
|
furorUsage: 0,
|
||||||
optionsSR: YggdrasillUtility.buildSROptions( ),
|
optionsSR: YggdrasillUtility.buildSROptions( ),
|
||||||
|
optionsBD: YggdrasillUtility.buildListOptions(0, +15),
|
||||||
sr: 0
|
sr: 0
|
||||||
}
|
}
|
||||||
let rollDialog = await YggdrasillRoll.create( this, rollData);
|
let rollDialog = await YggdrasillRoll.create( this, rollData);
|
||||||
@ -567,7 +570,7 @@ export class YggdrasillActor extends Actor {
|
|||||||
isEpuise: this.isEpuise(),
|
isEpuise: this.isEpuise(),
|
||||||
isBlesse: this.isBlesse(),
|
isBlesse: this.isBlesse(),
|
||||||
isMeurtri: this.isMeurtri(),
|
isMeurtri: this.isMeurtri(),
|
||||||
optionsBonusMalus: YggdrasillUtility.buildListOptions(-6, +6),
|
optionsBonusMalus: YggdrasillUtility.buildListOptions(-15, +15),
|
||||||
bonusMalus: 0,
|
bonusMalus: 0,
|
||||||
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
||||||
furorUsage: 0,
|
furorUsage: 0,
|
||||||
@ -645,6 +648,7 @@ export class YggdrasillActor extends Actor {
|
|||||||
|
|
||||||
let rollData = {
|
let rollData = {
|
||||||
mode: magie,
|
mode: magie,
|
||||||
|
isMagie: true,
|
||||||
alias: this.name,
|
alias: this.name,
|
||||||
actorImg: this.img,
|
actorImg: this.img,
|
||||||
actorId: this.id,
|
actorId: this.id,
|
||||||
@ -663,8 +667,8 @@ export class YggdrasillActor extends Actor {
|
|||||||
isEpuise: this.isEpuise(),
|
isEpuise: this.isEpuise(),
|
||||||
isBlesse: this.isBlesse(),
|
isBlesse: this.isBlesse(),
|
||||||
isMeurtri: this.isMeurtri(),
|
isMeurtri: this.isMeurtri(),
|
||||||
optionsBonusMalus: YggdrasillUtility.buildListOptions(-6, +6),
|
optionsBonusMalus: YggdrasillUtility.buildListOptions(-15, +15),
|
||||||
optionsBD: YggdrasillUtility.buildListOptions(0, +6),
|
optionsBD: YggdrasillUtility.buildListOptions(0, +15),
|
||||||
bonusMalus: 0,
|
bonusMalus: 0,
|
||||||
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
||||||
furorUsage: 0,
|
furorUsage: 0,
|
||||||
@ -714,8 +718,8 @@ export class YggdrasillActor extends Actor {
|
|||||||
isEpuise: this.isEpuise(),
|
isEpuise: this.isEpuise(),
|
||||||
isBlesse: this.isBlesse(),
|
isBlesse: this.isBlesse(),
|
||||||
isMeurtri: this.isMeurtri(),
|
isMeurtri: this.isMeurtri(),
|
||||||
optionsBonusMalus: YggdrasillUtility.buildListOptions(-6, +6),
|
optionsBonusMalus: YggdrasillUtility.buildListOptions(-15, +15),
|
||||||
optionsBD: YggdrasillUtility.buildListOptions(0, +6),
|
optionsBD: YggdrasillUtility.buildListOptions(0, +15),
|
||||||
bonusMalus: 0,
|
bonusMalus: 0,
|
||||||
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
optionsFuror: YggdrasillUtility.buildListOptions(0, this.getCurrentFuror() ),
|
||||||
furorUsage: 0,
|
furorUsage: 0,
|
||||||
|
@ -40,7 +40,7 @@ export class YggdrasillFigurantSheet extends ActorSheet {
|
|||||||
effetsmagiques: this.actor.getEffetsMagiques(),
|
effetsmagiques: this.actor.getEffetsMagiques(),
|
||||||
encTotal: this.actor.getEncTotal(),
|
encTotal: this.actor.getEncTotal(),
|
||||||
monnaies: this.actor.getMonnaies(),
|
monnaies: this.actor.getMonnaies(),
|
||||||
optionsAttr: new Array(21).fill('option'),
|
optionsAttr: new Array(41).fill('option'),
|
||||||
optionsBase: YggdrasillUtility.createDirectOptionList(0, 20),
|
optionsBase: YggdrasillUtility.createDirectOptionList(0, 20),
|
||||||
options: this.options,
|
options: this.options,
|
||||||
owner: this.document.isOwner,
|
owner: this.document.isOwner,
|
||||||
|
@ -91,27 +91,32 @@ export class YggdrasillRoll extends Dialog {
|
|||||||
if ( this.rollData.supportRune == "peau") {
|
if ( this.rollData.supportRune == "peau") {
|
||||||
support = 3;
|
support = 3;
|
||||||
this.rollData.echelleDuree = "Actions";
|
this.rollData.echelleDuree = "Actions";
|
||||||
|
this.rollData.echelleDureeVie = "Heures"
|
||||||
}
|
}
|
||||||
if ( this.rollData.supportRune == "tissu") {
|
if ( this.rollData.supportRune == "tissu") {
|
||||||
support = 6;
|
support = 6;
|
||||||
this.rollData.echelleDuree = "Tours";
|
this.rollData.echelleDuree = "Tours";
|
||||||
|
this.rollData.echelleDureeVie = "Jours"
|
||||||
}
|
}
|
||||||
if ( this.rollData.supportRune == "cuir") {
|
if ( this.rollData.supportRune == "cuir") {
|
||||||
support = 9;
|
support = 9;
|
||||||
this.rollData.echelleDuree = "Minutes";
|
this.rollData.echelleDuree = "Minutes";
|
||||||
|
this.rollData.echelleDureeVie = "Semaines"
|
||||||
}
|
}
|
||||||
if ( this.rollData.supportRune == "bois") {
|
if ( this.rollData.supportRune == "bois") {
|
||||||
support = 12;
|
support = 12;
|
||||||
this.rollData.echelleDuree = "Heures";
|
this.rollData.echelleDuree = "Heures";
|
||||||
|
this.rollData.echelleDureeVie = "Mois"
|
||||||
}
|
}
|
||||||
if ( this.rollData.supportRune == "pierremetal") {
|
if ( this.rollData.supportRune == "pierremetal") {
|
||||||
support = 15;
|
support = 15;
|
||||||
this.rollData.echelleDuree = "Jours";
|
this.rollData.echelleDuree = "Jours";
|
||||||
|
this.rollData.echelleDureeVie = "Années"
|
||||||
}
|
}
|
||||||
let SR = this.rollData.puissanceRune + (Number(this.rollData.sort.data.niveau)*3) + support;
|
let SR = this.rollData.puissanceRune + (Number(this.rollData.sort.data.niveau)*3) + support;
|
||||||
$("#srTotal").text(SR);
|
$("#srTotal").text(SR);
|
||||||
$("#runeDuree").text( this.rollData.dureeRune + " " + this.rollData.echelleDuree);
|
$("#runeDuree").text( this.rollData.dureeRune + " " + this.rollData.echelleDuree);
|
||||||
$("#runeDureeVie").text( this.rollData.puissanceRune + " " + this.rollData.echelleDuree);
|
$("#runeDureeVie").text( this.rollData.competence.data.niveau + " " + this.rollData.echelleDureeVie);
|
||||||
this.rollData.sr = SR;
|
this.rollData.sr = SR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -98,6 +98,38 @@ export class YggdrasillUtility {
|
|||||||
return compendiumData.filter(filter);
|
return compendiumData.filter(filter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
|
static async specificYggRoll( nbDice ) {
|
||||||
|
let rawDices = []
|
||||||
|
let rolls = []
|
||||||
|
let maxTab = []
|
||||||
|
|
||||||
|
maxTab[0] = {idx: 0, value: 0}
|
||||||
|
maxTab[1] = {idx: 0, value: 0}
|
||||||
|
|
||||||
|
for (let i=0; i<nbDice; i++) {
|
||||||
|
rolls[i] = new Roll("1d10x10").roll( {async: false}) //+sumDice+"+"+rollData.furorUsage+"d10+"+niveauCompetence+"+"+rollData.finalBM).roll( { async: false} );
|
||||||
|
if ( i == nbDice-1 ) {
|
||||||
|
await this.showDiceSoNice(rolls[i], game.settings.get("core", "rollMode") );
|
||||||
|
} else {
|
||||||
|
this.showDiceSoNice(rolls[i], game.settings.get("core", "rollMode") );
|
||||||
|
}
|
||||||
|
rawDices.push({ 'result': rolls[i].total});
|
||||||
|
|
||||||
|
if ( rolls[i].total > maxTab[0].value) {
|
||||||
|
if ( nbDice > 1 && maxTab[0].value > maxTab[1].value) {
|
||||||
|
maxTab[1].value = maxTab[0].value
|
||||||
|
}
|
||||||
|
maxTab[0].value = rolls[i].total
|
||||||
|
} else {
|
||||||
|
if ( nbDice > 1 && rolls[i].total > maxTab[1].value) {
|
||||||
|
maxTab[1].value = rolls[i].total
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return { rawDices: rawDices, maxTab: maxTab, rolls: rolls}
|
||||||
|
}
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
static async rollAttribute( rollData ) {
|
static async rollAttribute( rollData ) {
|
||||||
// Init stuff
|
// Init stuff
|
||||||
@ -114,31 +146,27 @@ export class YggdrasillUtility {
|
|||||||
rollData.finalBM -= 3;
|
rollData.finalBM -= 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
let rolls = []
|
let results = await this.specificYggRoll( 2 )
|
||||||
rollData.rawDices = []
|
rollData.rawDices = results.rawDices
|
||||||
for (let i=0; i < 2; i++) {
|
rollData.maxTab = results.maxTab
|
||||||
rolls[i] = new Roll("1d10x10").roll( { async: false} );
|
rollData.rolls = results.rolls
|
||||||
rollData.rawDices.push({ 'result': rolls[i].total});
|
|
||||||
}
|
|
||||||
this.showDiceSoNice(rolls[0], game.settings.get("core", "rollMode") );
|
|
||||||
await this.showDiceSoNice(rolls[1], game.settings.get("core", "rollMode") );
|
|
||||||
rollData.bonus = niveau + rollData.finalBM
|
rollData.bonus = niveau + rollData.finalBM
|
||||||
|
|
||||||
rollData.finalTotal = 0
|
rollData.finalTotal = rollData.maxTab[0].value + rollData.maxTab[1].value;
|
||||||
for (let i=0; i< 2; i++) {
|
|
||||||
rollData.finalTotal = rolls[i].dice[0].results[0].result
|
|
||||||
}
|
|
||||||
rollData.finalTotal += rollData.bonus
|
rollData.finalTotal += rollData.bonus
|
||||||
|
|
||||||
// Compute total SR
|
// Compute total SR
|
||||||
rollData.srFinal = rollData.sr;
|
rollData.srFinal = rollData.sr;
|
||||||
|
if ( rollData.bonusdefense ) {
|
||||||
|
rollData.srFinal += rollData.bonusdefense;
|
||||||
|
}
|
||||||
if ( rollData.srFinal > 0 ) {
|
if ( rollData.srFinal > 0 ) {
|
||||||
isCritical = rollData.finalTotal >= rollData.srFinal*2;
|
isCritical = rollData.finalTotal >= rollData.srFinal*2;
|
||||||
isSuccess = rollData.finalTotal >= rollData.srFinal;
|
isSuccess = rollData.finalTotal >= rollData.srFinal;
|
||||||
marge = rollData.finalTotal - rollData.srFinal;
|
marge = rollData.finalTotal - rollData.srFinal;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rolls[0].dice[0].results[0].result == 1 && rolls[1].dice[0].results[0].result == 1) {
|
if (rollData.rolls[0].dice[0].results[0].result == 1 && rollData.rolls[1].dice[0].results[0].result == 1) {
|
||||||
isFailure = true;
|
isFailure = true;
|
||||||
}
|
}
|
||||||
// Dégats
|
// Dégats
|
||||||
@ -154,7 +182,6 @@ export class YggdrasillUtility {
|
|||||||
rollData.isSuccess = isSuccess;
|
rollData.isSuccess = isSuccess;
|
||||||
rollData.isCritical = isCritical;
|
rollData.isCritical = isCritical;
|
||||||
rollData.marge = marge;
|
rollData.marge = marge;
|
||||||
rollData.rolls = rolls
|
|
||||||
|
|
||||||
console.log("ROLLLL ATTR!!!!", rollData);
|
console.log("ROLLLL ATTR!!!!", rollData);
|
||||||
|
|
||||||
@ -196,41 +223,30 @@ export class YggdrasillUtility {
|
|||||||
rollData.finalBM -= 3;
|
rollData.finalBM -= 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
rollData.rawDices = []
|
|
||||||
if (sumDice > nbDice) sumDice = nbDice;
|
if (sumDice > nbDice) sumDice = nbDice;
|
||||||
let rolls = []
|
let results = await this.specificYggRoll( nbDice )
|
||||||
let maxTab = [ {idx: 0, value: 0}, {idx: 0, value:0}]
|
rollData.rawDices = results.rawDices
|
||||||
for (let i=0; i<nbDice; i++) {
|
rollData.maxTab = results.maxTab
|
||||||
rolls[i] = new Roll("1d10x10").roll( {async: false}) //+sumDice+"+"+rollData.furorUsage+"d10+"+niveauCompetence+"+"+rollData.finalBM).roll( { async: false} );
|
rollData.rolls = results.rolls
|
||||||
if ( i == nbDice-1 ) {
|
console.log("RES", results, nbDice, sumDice)
|
||||||
await this.showDiceSoNice(rolls[nbDice-1], game.settings.get("core", "rollMode") );
|
|
||||||
} else {
|
|
||||||
this.showDiceSoNice(rolls[i], game.settings.get("core", "rollMode") );
|
|
||||||
}
|
|
||||||
rollData.rawDices.push({ 'result': rolls[i].total});
|
|
||||||
|
|
||||||
if ( rolls[i].total > maxTab[0].value) {
|
if ( rollData.furorUsage > 0 ) {
|
||||||
if ( maxTab[0].value > maxTab[1].value) {
|
results = await this.specificYggRoll( rollData.furorUsage )
|
||||||
maxTab[1].value = maxTab[0].value
|
rollData.furorRawDices = results.rawDices
|
||||||
maxTab[1].idx = maxTab[0].idx
|
rollData.furorMaxTab = results.maxTab
|
||||||
}
|
rollData.furorRolls = results.rolls
|
||||||
maxTab[0].value = rolls[i].total
|
let actor = game.actors.get(rollData.actorId);
|
||||||
maxTab[0].idx = i
|
actor.decrementFuror( rollData.furorUsage);
|
||||||
} else {
|
|
||||||
if ( rolls[i].total > maxTab[1].value) {
|
|
||||||
maxTab[1].value = rolls[i].total
|
|
||||||
maxTab[1].idx = i
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
let bonusRoll = new Roll(rollData.furorUsage+"d10x10+"+niveauCompetence+"+"+rollData.finalBM).roll( {async: false})
|
|
||||||
if ( rollData.furorUsage > 0) {
|
rollData.bonusTotal = niveauCompetence + rollData.finalBM
|
||||||
this.showDiceSoNice(bonusRoll, game.settings.get("core", "rollMode") );
|
rollData.finalTotal = (sumDice ==1) ? rollData.maxTab[0].value : rollData.maxTab[0].value + rollData.maxTab[1].value;
|
||||||
}
|
rollData.furorResult = 0
|
||||||
rollData.finalTotal = (sumDice ==1) ? maxTab[0].value : maxTab[0].value + maxTab[1].value;
|
for (let i=0; i<rollData.furorUsage; i++) {
|
||||||
rollData.finalTotal += bonusRoll.total;
|
rollData.furorResult += rollData.furorMaxTab[i].value
|
||||||
rollData.furorResult = (rollData.furorUsage >0 ) ? bonusRoll.dice[0].results[0].result : 0;
|
}
|
||||||
rollData.maxTab = maxTab
|
rollData.finalTotal += rollData.furorResult + rollData.bonusTotal;
|
||||||
|
rollData.niveauCompetence = niveauCompetence
|
||||||
|
|
||||||
// Compute total SR
|
// Compute total SR
|
||||||
rollData.srFinal = rollData.sr;
|
rollData.srFinal = rollData.sr;
|
||||||
@ -244,23 +260,19 @@ export class YggdrasillUtility {
|
|||||||
marge = rollData.finalTotal - rollData.srFinal;
|
marge = rollData.finalTotal - rollData.srFinal;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nbDice == 1 && rolls[0].dice[0].results[0].result == 1) {
|
if (nbDice == 1 && rollData.rolls[0].dice[0].results[0].result == 1) {
|
||||||
isFailure = true;
|
isFailure = true;
|
||||||
}
|
}
|
||||||
if (nbDice == 2 && rolls[0].dice[0].results[0].result == 1 && rolls[1].dice[0].results[0].result == 1) {
|
if (nbDice == 2 && rollData.rolls[0].dice[0].results[0].result == 1 && rollData.rolls[1].dice[0].results[0].result == 1) {
|
||||||
isFailure = true;
|
isFailure = true;
|
||||||
}
|
}
|
||||||
if (nbDice >= 3 ) {
|
if (nbDice >= 3 ) {
|
||||||
let nbOnes = 0
|
let nbOnes = 0
|
||||||
for (let roll of rolls) {
|
for (let roll of rollData.rolls) {
|
||||||
if (roll.dice[0].results[0].result == 1 ) nbOnes++;
|
if (roll.dice[0].results[0].result == 1 ) nbOnes++;
|
||||||
}
|
}
|
||||||
isFailure = nbOnes >= 3;
|
isFailure = nbOnes >= 3;
|
||||||
}
|
}
|
||||||
if ( rollData.furorUsage > 0 ) {
|
|
||||||
let actor = game.actors.get(rollData.actorId);
|
|
||||||
actor.decrementFuror( rollData.furorUsage);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Dégats
|
// Dégats
|
||||||
if ( isSuccess && (rollData.mode == "armecc" || rollData.mode == "armedist") ) {
|
if ( isSuccess && (rollData.mode == "armecc" || rollData.mode == "armedist") ) {
|
||||||
@ -269,7 +281,6 @@ export class YggdrasillUtility {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Stockage resultats
|
// Stockage resultats
|
||||||
rollData.rolls = rolls
|
|
||||||
rollData.sumDice = sumDice;
|
rollData.sumDice = sumDice;
|
||||||
rollData.isFailure = isFailure;
|
rollData.isFailure = isFailure;
|
||||||
rollData.isSuccess = isSuccess;
|
rollData.isSuccess = isSuccess;
|
||||||
|
@ -876,8 +876,7 @@ ul, li {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#sidebar.collapsed {
|
#sidebar.collapsed {
|
||||||
height: 430px !important;
|
height: 470px !important;
|
||||||
position: absolute;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#sidebar-tabs > .collapsed, #chat-controls .chat-control-icon {
|
#sidebar-tabs > .collapsed, #chat-controls .chat-control-icon {
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
"name": "fvtt-yggdrasill",
|
"name": "fvtt-yggdrasill",
|
||||||
"title": "Yggdrasill",
|
"title": "Yggdrasill",
|
||||||
"description": "Système non-officiel Yggdrasill (7ièm Cercle) pour FoundryVTT",
|
"description": "Système non-officiel Yggdrasill (7ièm Cercle) pour FoundryVTT",
|
||||||
"version": "1.1.10",
|
"version": "1.1.11",
|
||||||
"manifestPlusVersion": "1.0.0",
|
"manifestPlusVersion": "1.0.0",
|
||||||
"minimumCoreVersion": "0.8.0",
|
"minimumCoreVersion": "0.8.0",
|
||||||
"compatibleCoreVersion": "9",
|
"compatibleCoreVersion": "9",
|
||||||
|
@ -4,104 +4,118 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<img class="chat-icon" src="{{img}}" alt="{{alias}}" />
|
<div>
|
||||||
<h3>
|
<img class="chat-icon" src="{{img}}" alt="{{alias}}" />
|
||||||
{{#if (eq mode "attribut")}}
|
<h3>
|
||||||
Jet de {{attr.label}} {{subAttr.label}} (2d10+{{subAttr.value}})
|
{{#if (eq mode "attribut")}}
|
||||||
{{else}}
|
Jet de {{attr.label}} {{subAttr.label}} (2d10+{{subAttr.value}})
|
||||||
{{#if (eq mode "competence")}}
|
{{else}}
|
||||||
|
{{#if (eq mode "competence")}}
|
||||||
Jet de {{selectedCarac.label}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
Jet de {{selectedCarac.label}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
||||||
{{else}}
|
{{else}}
|
||||||
{{#if (eq mode "armecc")}}
|
{{#if (eq mode "armecc")}}
|
||||||
Attaque au corps à Corps {{attackDef.label}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
Attaque au corps à Corps {{attackDef.label}} ({{selectedCarac.value}}d10) / {{competence.name}}
|
||||||
{{else}}
|
({{competence.data.niveau}})
|
||||||
{{#if (eq mode "armedist")}}
|
{{else}}
|
||||||
Attaque à Distance {{attackDef.label}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
{{#if (eq mode "armedist")}}
|
||||||
{{else}}
|
Attaque à Distance {{attackDef.label}} ({{selectedCarac.value}}d10) / {{competence.name}}
|
||||||
{{#if (eq mode "sejdr")}}
|
({{competence.data.niveau}})
|
||||||
Lancer du Sort {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
{{else}}
|
||||||
{{else}}
|
{{#if (eq mode "sejdr")}}
|
||||||
{{#if (eq mode "rune")}}
|
Lancer du Sort {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
||||||
Gravure de la Rune {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
{{else}}
|
||||||
{{else}}
|
{{#if (eq mode "rune")}}
|
||||||
{{#if (eq mode "galdr")}}
|
Gravure de la Rune {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
||||||
Lancer du Domaine {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
{{else}}
|
||||||
{{else}}
|
{{#if (eq mode "galdr")}}
|
||||||
Jet de {{selectedCarac.label}} ({{selectedCarac.value}}d10)
|
Lancer du Domaine {{sort.name}} ({{selectedCarac.value}}d10) / {{competence.name}} ({{competence.data.niveau}})
|
||||||
{{/if}}
|
{{else}}
|
||||||
{{/if}}
|
Jet de {{selectedCarac.label}} ({{selectedCarac.value}}d10)
|
||||||
{{/if}}
|
|
||||||
{{/if}}
|
|
||||||
{{/if}}
|
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<ul>
|
||||||
|
<li>Dés :
|
||||||
|
{{#each rawDices as |roll key|}}
|
||||||
|
{{roll.result}}
|
||||||
|
{{/each}}
|
||||||
|
</li>
|
||||||
|
{{#if sumDice}}
|
||||||
|
<li>Nombre de dés additionnés : {{sumDice}}</li>
|
||||||
|
{{/if}}
|
||||||
|
<li>{{#if (eq mode "carac")}}Carac{{else}}Competence{{/if}} : {{niveauCompetence}}</li>
|
||||||
|
<li>Bonus/Malus Final : {{finalBM}}</li>
|
||||||
|
{{#if sr}}
|
||||||
|
<li>Seuil de Réussite final : {{srFinal}}</li>
|
||||||
|
{{/if}}
|
||||||
|
{{#if furorUsage}}
|
||||||
|
<li>Furor dépensée : {{furorUsage}}</li>
|
||||||
|
<li>Resultat de la Furor : {{furorResult}}</li>
|
||||||
|
{{/if}}
|
||||||
|
<li>
|
||||||
|
<h3>Total : {{finalTotal}}</h3>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
{{#if dureeGaldrText}}
|
||||||
|
<div>
|
||||||
|
Durée du Sort : {{dureeGaldrText}}
|
||||||
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div>
|
{{#if zoneGaldrText}}
|
||||||
<ul>
|
<div>
|
||||||
<li>Dés :
|
Volume Max de l'Illusion : {{zoneGaldrText}}
|
||||||
{{#each rawDices as |roll key|}}
|
</div>
|
||||||
{{roll.result}}
|
|
||||||
{{/each}}
|
|
||||||
</li>
|
|
||||||
{{#if sumDice}}
|
|
||||||
<li>Nombre de dés additionnés : {{sumDice}}</li>
|
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<li>{{#if (eq mode "carac")}}Carac{{else}}Competence{{/if}} : {{niveauCompetence}}</li>
|
|
||||||
<li>Bonus/Malus Final : {{finalBM}}</li>
|
{{#if ciblesGaldrText}}
|
||||||
{{#if sr}}
|
<div>
|
||||||
<li>Seuil de Réussite final : {{srFinal}}</li>
|
Nombre de Cibles : {{ciblesGaldrText}}
|
||||||
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if furorUsage}}
|
|
||||||
<li>Furor dépensée : {{furorUsage}}</li>
|
|
||||||
<li>Resultat de la Furor : {{furorResult}}</li>
|
{{#if degats}}
|
||||||
|
<div>
|
||||||
|
Degats : {{degats}} ({{degatsExplain}})
|
||||||
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<li><h3>Total : {{finalTotal}}</h3></li>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
{{#if dureeGaldrText}}
|
|
||||||
<div>
|
|
||||||
Durée du Sort : {{dureeGaldrText}}
|
|
||||||
</div>
|
|
||||||
{{/if}}
|
|
||||||
|
|
||||||
{{#if zoneGaldrText}}
|
{{#if attackDef.protection}}
|
||||||
<div>
|
<div>
|
||||||
Volume Max de l'Illusion : {{zoneGaldrText}}
|
Annuation de Protection du Défenseur : {{attackDef.protection}}
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
{{#if ciblesGaldrText}}
|
{{#if isCritical}}
|
||||||
<div>
|
<div class="chat-message-header">
|
||||||
Nombre de Cibles : {{ciblesGaldrText}}
|
<img class="chat-icon" src="systems/fvtt-yggdrasill/images/icons/icon_reussite_critique.png" alt="critique" />
|
||||||
</div>
|
Réussite Critique !
|
||||||
{{/if}}
|
</div>
|
||||||
|
|
||||||
|
|
||||||
{{#if degats}}
|
|
||||||
<div>
|
|
||||||
Degats : {{degats}} ({{degatsExplain}})
|
|
||||||
</div>
|
|
||||||
{{/if}}
|
|
||||||
|
|
||||||
{{#if attackDef.protection}}
|
|
||||||
<div>
|
|
||||||
Annuation de Protection du Défenseur : {{attackDef.protection}}
|
|
||||||
</div>
|
|
||||||
{{/if}}
|
|
||||||
|
|
||||||
{{#if isCritical}}
|
|
||||||
<div class="chat-message-header">
|
|
||||||
<img class="chat-icon" src="systems/fvtt-yggdrasill/images/icons/icon_reussite_critique.png" alt="critique" />
|
|
||||||
Réussite Critique !
|
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if isFailure}}
|
{{#if isFailure}}
|
||||||
<img class="chat-icon" src="systems/fvtt-yggdrasill/images/icons/icon_echec_critique.png" alt="echec" />
|
<div class="chat-message-header">
|
||||||
Echec Critique !
|
<img class="chat-icon" src="systems/fvtt-yggdrasill/images/icons/icon_echec_critique.png" alt="echec" />
|
||||||
</div>
|
Echec Critique !
|
||||||
{{/if}}
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
</div>
|
{{#if (and isSuccess isMagie)}}
|
||||||
|
<div>
|
||||||
|
<hr>
|
||||||
|
{{{sort.data.description}}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
@ -17,6 +17,15 @@
|
|||||||
{{/select}}
|
{{/select}}
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="flexrow">
|
||||||
|
<span class="competence-base flexrow" >Défense Physique du défenseur : </span>
|
||||||
|
<select class="competence-base flexrow" type="text" id="bonusdefense" name="bonusdefense" value="{{bonusdefense}}" data-dtype="Number">
|
||||||
|
{{#select bonusdefense}}
|
||||||
|
{{{optionsBD}}}
|
||||||
|
{{/select}}
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="flexrow">
|
<div class="flexrow">
|
||||||
<span class="competence-base flexrow" >Seuil de Réussite : </span>
|
<span class="competence-base flexrow" >Seuil de Réussite : </span>
|
||||||
|
Loading…
Reference in New Issue
Block a user