2021-02-05 01:38:40 +01:00
|
|
|
import { Misc } from "./misc.js";
|
2021-01-04 00:17:22 +01:00
|
|
|
|
|
|
|
/* -------------------------------------------- */
|
|
|
|
export class RdDItem {
|
|
|
|
|
2021-02-06 01:34:49 +01:00
|
|
|
static isQueueDragon(item) {
|
|
|
|
return item.type == 'queue' || item.type == 'ombre';
|
2021-01-08 22:23:50 +01:00
|
|
|
}
|
|
|
|
|
2021-02-06 01:34:49 +01:00
|
|
|
static isSouffleDragon(item) {
|
|
|
|
return item.type == 'souffle';
|
2021-02-05 23:51:12 +01:00
|
|
|
}
|
|
|
|
|
2021-02-06 01:34:49 +01:00
|
|
|
static isHRPontImpraticable(item) {
|
|
|
|
return RdDItem.isSouffleDragon(item) && item.name.toLowerCase().includes(' des ponts');
|
|
|
|
}
|
|
|
|
|
|
|
|
static isHRDoubleResistanceFleuve(item) {
|
|
|
|
return RdDItem.isSouffleDragon(item) && item.name.toLowerCase().includes('résistance du fleuve')
|
|
|
|
}
|
|
|
|
static isHRPeage(item) {
|
|
|
|
return RdDItem.isSouffleDragon(item) && item.name.toLowerCase().includes('péage')
|
|
|
|
}
|
|
|
|
|
|
|
|
static isHRMauvaiseRencontreEnPerspective(item) {
|
|
|
|
return (RdDItem.isQueueDragon(item) || RdDItem.isSouffleDragon(item)) && item.name.toLowerCase().includes('mauvaise rencontre')
|
|
|
|
}
|
|
|
|
|
|
|
|
static isHRInertieDraconique(item) {
|
|
|
|
return RdDItem.isQueueDragon(item) && item.name.toLowerCase().includes('inertie draconique')
|
2021-01-08 22:23:50 +01:00
|
|
|
}
|
|
|
|
|
2021-02-05 01:38:40 +01:00
|
|
|
static isCaseTMR(item) {
|
|
|
|
return item.type == 'casetmr';
|
|
|
|
}
|
2021-02-05 23:51:12 +01:00
|
|
|
|
2021-02-06 01:34:49 +01:00
|
|
|
static isHRCaseInnondee(item) {
|
|
|
|
return RdDItem.isCaseTMR(item) && item.data.specific == 'debordement';
|
2021-02-05 23:51:12 +01:00
|
|
|
}
|
2021-02-06 01:34:49 +01:00
|
|
|
|
2021-01-04 00:17:22 +01:00
|
|
|
}
|