2023-01-05 00:55:04 +01:00
|
|
|
import { RdDItem } from "../item.js";
|
|
|
|
|
|
|
|
export class RdDItemQueue extends RdDItem {
|
|
|
|
|
|
|
|
static get defaultIcon() {
|
|
|
|
return "systems/foundryvtt-reve-de-dragon/icons/queue_dragon.webp";
|
|
|
|
}
|
|
|
|
|
2025-01-19 01:17:38 +01:00
|
|
|
async calculerFinPeriodeTemporel(timestamp) {
|
|
|
|
// décaller le début pour calcul correct si la queue dure 12h
|
|
|
|
const debut = timestamp.addMinutes(timestamp.indexMinute == 0 ? -1 : 0);
|
2023-01-05 00:55:04 +01:00
|
|
|
return await debut.appliquerDuree(this.system.duree, this.parent);
|
|
|
|
}
|
|
|
|
}
|