Merge pull request 'v11.1.6 - Les dissections de Werther de Zloth' (#682) from VincentVk/foundryvtt-reve-de-dragon:v11 into v11

Reviewed-on: #682
This commit is contained in:
uberwald 2023-11-12 22:15:26 +01:00
commit 9ff68884ce
6 changed files with 17 additions and 11 deletions

View File

@ -1,6 +1,8 @@
# v11.0 # v11.0
## v11.1.5 - Les dissections de Werther de Zloth ## v11.1.6 - Les dissections de Werther de Zloth
- Fix: on peut de nouveau donner des compétences aux créatures - Fix: on peut de nouveau donner des compétences aux créatures
- Fix: le délai de guérison d'une blessure rétrogradée est correctement appliqué
- Fix: l'encaissement à valider par le MJ fonctionne de nouveau
## v11.1.5 - Werther de Zloth l'Onirique ## v11.1.5 - Werther de Zloth l'Onirique
- Fixes: - Fixes:

View File

@ -256,7 +256,7 @@ export class RdDActor extends RdDBaseActorSang {
const isMaladeEmpoisonne = maladiesPoisons.length > 0; const isMaladeEmpoisonne = maladiesPoisons.length > 0;
this._messageRecuperationMaladiePoisons(maladiesPoisons, message); this._messageRecuperationMaladiePoisons(maladiesPoisons, message);
await this._recuperationBlessures(message, isMaladeEmpoisonne); await this._recupererBlessures(message, isMaladeEmpoisonne);
await this._recupererVie(message, isMaladeEmpoisonne); await this._recupererVie(message, isMaladeEmpoisonne);
} }
@ -367,7 +367,7 @@ export class RdDActor extends RdDBaseActorSang {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
async _recuperationBlessures(message, isMaladeEmpoisonne) { async _recupererBlessures(message, isMaladeEmpoisonne) {
const timestamp = game.system.rdd.calendrier.getTimestamp() const timestamp = game.system.rdd.calendrier.getTimestamp()
const blessures = this.filterItems(it => it.system.gravite > 0, TYPES.blessure).sort(Misc.ascending(it => it.system.gravite)) const blessures = this.filterItems(it => it.system.gravite > 0, TYPES.blessure).sort(Misc.ascending(it => it.system.gravite))
@ -661,7 +661,7 @@ export class RdDActor extends RdDBaseActorSang {
/* -------------------------------------------- */ /* -------------------------------------------- */
async sortMisEnReserve(sort, draconic, coord, ptreve) { async sortMisEnReserve(sort, draconic, coord, ptreve) {
await this.createEmbeddedDocuments("Item", [{ await this.createEmbeddedDocuments("Item", [{
type: 'sortreserve', type: TYPES.sortreserve,
name: sort.name, name: sort.name,
img: sort.img, img: sort.img,
system: { sortid: sort._id, draconic: (draconic?.name ?? sort.system.draconic), ptreve: ptreve, coord: coord, heurecible: 'Vaisseau' } system: { sortid: sort._id, draconic: (draconic?.name ?? sort.system.draconic), ptreve: ptreve, coord: coord, heurecible: 'Vaisseau' }

View File

@ -427,7 +427,7 @@ export class RdDBaseActorReve extends RdDBaseActor {
RdDBaseActor.remoteActorCall({ RdDBaseActor.remoteActorCall({
tokenId: this.token?.id, tokenId: this.token?.id,
actorId: this.id, actorId: this.id,
method: 'appliquerEncaissement', method: 'encaisserDommages',
args: [rollData, show, attackerId] args: [rollData, show, attackerId]
}); });
return; return;

View File

@ -115,7 +115,10 @@ export class RdDItemBlessure extends RdDItem {
if (!isMaladeEmpoisonne && rolled.isSuccess && this.peutRetrograder(graviteMoindre, moindres)) { if (!isMaladeEmpoisonne && rolled.isSuccess && this.peutRetrograder(graviteMoindre, moindres)) {
message.content += ` -- une blessure ${label} cicatrise`; message.content += ` -- une blessure ${label} cicatrise`;
mergeObject(update, { mergeObject(update, {
system: { gravite: graviteMoindre, fin: { indexDate: timestamp.addJours(graviteMoindre).indexDate } } system: {
gravite: graviteMoindre,
temporel: { fin: { indexDate: timestamp.addJours(graviteMoindre).indexDate } }
}
}); });
} }
else { else {

View File

@ -16,6 +16,7 @@ import { RdDDice } from "./rdd-dice.js";
import { STATUSES } from "./settings/status-effects.js"; import { STATUSES } from "./settings/status-effects.js";
import { RdDRencontre } from "./item/rencontre.js"; import { RdDRencontre } from "./item/rencontre.js";
import { RdDTimestamp } from "./time/rdd-timestamp.js"; import { RdDTimestamp } from "./time/rdd-timestamp.js";
import { TYPES } from "./item.js";
/* -------------------------------------------- */ /* -------------------------------------------- */
@ -110,11 +111,11 @@ export class RdDTMRDialog extends Dialog {
} }
get sortsReserve() { get sortsReserve() {
return this.actor.itemTypes['sortreserve']; return this.actor.itemTypes[TYPES.sortreserve];
} }
getSortsReserve(coord) { getSortsReserve(coord) {
return this.actor.itemTypes['sortreserve'].filter(// Reserve sur une case fleuve ou normale return this.actor.itemTypes[TYPES.sortreserve].filter(// Reserve sur une case fleuve ou normale
TMRUtility.getTMR(coord).type == 'fleuve' TMRUtility.getTMR(coord).type == 'fleuve'
? it => TMRUtility.getTMR(it.system.coord).type == 'fleuve' ? it => TMRUtility.getTMR(it.system.coord).type == 'fleuve'
: it => it.system.coord == coord : it => it.system.coord == coord
@ -166,7 +167,7 @@ export class RdDTMRDialog extends Dialog {
return this.rencontresExistantes.map(it => this._tokenRencontre(it)); return this.rencontresExistantes.map(it => this._tokenRencontre(it));
} }
_getTokensSortsReserve() { _getTokensSortsReserve() {
return this.actor.itemTypes['sortreserve'].map(it => this._tokenSortEnReserve(it)); return this.actor.itemTypes[TYPES.sortreserve].map(it => this._tokenSortEnReserve(it));
} }
/* -------------------------------------------- */ /* -------------------------------------------- */

View File

@ -1,8 +1,8 @@
{ {
"id": "foundryvtt-reve-de-dragon", "id": "foundryvtt-reve-de-dragon",
"title": "Rêve de Dragon", "title": "Rêve de Dragon",
"version": "11.1.5", "version": "11.1.6",
"download": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/archive/foundryvtt-reve-de-dragon-11.1.5.zip", "download": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/archive/foundryvtt-reve-de-dragon-11.1.6.zip",
"manifest": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/v11/system.json", "manifest": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/v11/system.json",
"changelog": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/branch/v11/changelog.md", "changelog": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/branch/v11/changelog.md",
"compatibility": { "compatibility": {