add disguise

This commit is contained in:
Mike Bloy 2024-05-15 22:03:35 -05:00
parent 1877b048d2
commit 486a7d4167
2 changed files with 57 additions and 46 deletions

View File

@ -0,0 +1,56 @@
import { PowerEffect } from './basePowers.js';
export class DisguiseEffect extends PowerEffect {
get name() {
return 'Disguise';
}
get icon() {
return 'icons/equipment/head/mask-carved-wood-white.webp';
}
get duration() {
return 100;
}
get basePowerPoints() {
return 2;
}
get isTargeted() {
return true;
}
get hasAdditionalRecipients() {
return true;
}
get additionalRecipientCost() {
return 1;
}
get modifiers() {
return [
...super.modifiers,
{
name: 'Size',
type: 'checkbox',
value: 1,
id: 'size',
epic: false,
effect: false,
},
];
}
get description() {
const size = this.data.size ? 'within two sizes of' : 'of the same size as';
return (
super.description +
`
<p>Assume the appearance of another person ${size} the recipient. Anyone
who has cause to doubt the disguise may make a Notice roll at ${this.data.raise ? -4 : -2}
as a free action to see through the disguise.</p>`
);
}
}

View File

@ -1,6 +1,5 @@
/* globals warpgate */
import { moduleName } from '../globals.js';
import { PowerEffect } from './basePowers.js';
import { ArcaneProtectionEffect } from './arcaneProtection.js';
import { BanishEffect } from './banish.js';
import { BarrierEffect } from './barrier.js';
@ -17,51 +16,7 @@ import { DamageFieldEffect } from './damageField.js';
import { DarksightEffect } from './darksight.js';
import { DeflectionEffect } from './deflection.js';
import { DetectConcealArcanaEffect } from './detectConcealArcana.js';
class DisguiseEffect extends PowerEffect {
get name() {
return 'Disguise';
}
get icon() {
return 'icons/equipment/head/mask-carved-wood-white.webp';
}
get duration() {
return 100;
}
get basePowerPoints() {
return 2;
}
get isTargeted() {
return true;
}
get hasAdditionalRecipients() {
return true;
}
get additionalRecipientCost() {
return 1;
}
get modifiers() {
return [...super.modifiers, { name: 'Size', value: 1, id: 'size', epic: false, effect: false }];
}
get description() {
const size = this.data.mods.has('size') ? 'of the same size as' : 'within two sizes of';
return (
super.description +
`
<p>Assume the appearance of another person ${size} the recipient. Anyone
who has cause to doubt the disguise may make a Notice roll at ${this.data.raise ? -4 : -4}
as a free action to see through the disguise.</p>`
);
}
}
import { DisguiseEffect } from './disguise.js';
const PowerClasses = {
'arcane-protection': ArcaneProtectionEffect,