Enhance sheets
This commit is contained in:
30
module/sos-combat.js
Normal file
30
module/sos-combat.js
Normal file
@ -0,0 +1,30 @@
|
||||
import { SoSCardDeck } from "./sos-card-deck.js";
|
||||
import { SoSUtility } from "./sos-utility.js";
|
||||
import { SoSFlipDialog } from "./sos-flip-dialog.js";
|
||||
import { SoSDialogCombatActions } from "./sos-dialog-combat-actions.js";
|
||||
|
||||
/* -------------------------------------------- */
|
||||
export class SoSCombat extends Combat {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async nextRound() {
|
||||
console.log("NEXT ROUND !!!!");
|
||||
|
||||
if ( game.user.isGM ) {
|
||||
ChatMessage.create( { content: `New round !! Click on the button below to declare your actions for round ${this.round} !<br>
|
||||
<a class='chat-card-button' id='button-declare-actions' data-combat-id='${this._id} data-round='${this.round}'>Declare actions</a>`,
|
||||
whisper: game.users.map(user => user.data._id) } );
|
||||
}
|
||||
super.nextRound();
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
setupActorActions(actionConf) {
|
||||
if ( !this.phaseSetup) this.phaseSetup = []; // Opportunistic init
|
||||
if ( !this.phaseSetup[this.round] ) this.phaseSetup[this.round] = {}; // Bis
|
||||
|
||||
// Keep track
|
||||
this.phaseSetup[this.round][actionConf.userId] = actionConf;
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user