Start combat management
This commit is contained in:
@ -6,7 +6,7 @@ export default class LethalFantasyCharacterSheet extends LethalFantasyActorSheet
|
||||
static DEFAULT_OPTIONS = {
|
||||
classes: ["character"],
|
||||
position: {
|
||||
width: 1150,
|
||||
width: 1080,
|
||||
height: 780,
|
||||
},
|
||||
window: {
|
||||
@ -15,6 +15,7 @@ export default class LethalFantasyCharacterSheet extends LethalFantasyActorSheet
|
||||
actions: {
|
||||
createEquipment: LethalFantasyCharacterSheet.#onCreateEquipment,
|
||||
rangedAttackDefense: LethalFantasyCharacterSheet.#onRangedAttackDefense,
|
||||
rollInitiative: LethalFantasyCharacterSheet.#onRollInitiative,
|
||||
armorHitPointsPlus: LethalFantasyCharacterSheet.#onArmorHitPointsPlus,
|
||||
armorHitPointsMinus: LethalFantasyCharacterSheet.#onArmorHitPointsMinus,
|
||||
},
|
||||
@ -149,10 +150,30 @@ export default class LethalFantasyCharacterSheet extends LethalFantasyActorSheet
|
||||
|
||||
static async #onRangedAttackDefense(event, target) {
|
||||
const hasTarget = false
|
||||
|
||||
let roll = await LethalFantasyRoll.promptRangedDefense({
|
||||
actorId: this.actor.id,
|
||||
actorName: this.actor.name,
|
||||
actorImage: this.actor.img
|
||||
actorImage: this.actor.img,
|
||||
})
|
||||
if (!roll) return null
|
||||
|
||||
await roll.toMessage({}, { rollMode: roll.options.rollMode })
|
||||
}
|
||||
|
||||
static async #onRollInitiative(event, target) {
|
||||
const hasTarget = false
|
||||
let actorClass = this.actor.system.biodata.class;
|
||||
|
||||
let wisDef = SYSTEM.CHARACTERISTICS_TABLES.wis.find((c) => c.value === this.actor.system.characteristics.wis.value)
|
||||
let maxInit = Number(wisDef.init_cap) || 1000
|
||||
|
||||
let roll = await LethalFantasyRoll.promptInitiative({
|
||||
actorId: this.actor.id,
|
||||
actorName: this.actor.name,
|
||||
actorImage: this.actor.img,
|
||||
actorClass,
|
||||
maxInit,
|
||||
})
|
||||
if (!roll) return null
|
||||
|
||||
|
Reference in New Issue
Block a user