module/src/player-state.js
/**
     * Request fire on a specified opponent and position.
     * @param  {PlayerState} opponent - the player to fire upon
     * @param  {[number, number]} position - the position at which to fire
     */
Request fire on a specified opponent and position.
@param  {PlayerState} opponent - the player to fire upon
@param  {[number, number]} position - the position at which to fire
Request fire on a specified opponent and position . @param { PlayerState } opponent - the player to fire upon @param { [ number number ] } position - the position at which to fire
fire(opponent, position) {
        if (opponent == null) {
            throw new TypeError(`Parameter 'opponent' must be provided.`);
        }
        if (Array.isArray(position) !== true || position.length !== 2) {
            throw new TypeError(`Parameter 'position' must be a tuple of two values.`);
        }
        this.dispatchEvent({ type: 'request-fire', opponent, position });
    }
fire ( opponent , position ) { if ( opponent == null ) { throw new TypeError ( ` ` ) ; } if ( Array . isArray ( position ) !== true || position . length !== 2 ) { throw new TypeError ( ` ` ) ; } this . dispatchEvent ( { type : 'request-fire' , opponent , position } ) ; }
Request fire on a specified opponent and position.
Request fire on a specified opponent and position .