mwg API
    Preparing search index...

    Function endTacticalTurn

    • Hands the turn to the next owner with units on the board, refreshing their action points and clearing overwatch.

      Parameters

      Returns void

      import { startingTactics, addTacticalUnit, endTacticalTurn } from '@datamoc/mw_games/board';

      const state = startingTactics(6, 6, 'square');
      addTacticalUnit(state, { id: 'ranger', owner: 'blue', x: 0, y: 0, hp: 10, maxHp: 10, actions: 2 });
      addTacticalUnit(state, { id: 'raider', owner: 'red', x: 3, y: 0, hp: 10, maxHp: 10, actions: 2 });

      endTacticalTurn(state);
      console.log(state.turn, state.round); // 'red' 1