Class NextPatrolStation

    • Field Detail

      • player

        private final IPlayer player
      • deadline

        private final java.time.LocalDateTime deadline
      • date

        @Autowired
        private Date date
      • rnd

        @Autowired
        private java.util.Random rnd
    • Constructor Detail

      • NextPatrolStation

        public NextPatrolStation​(INavigableVessel ship,
                                 ICity city,
                                 PatrolInternalState state,
                                 IPlayer player,
                                 java.time.LocalDateTime deadline,
                                 AttackListener atackListener)
        Create the next patrol station listener. This listener adds itself to the event queue and removes the first city from the patrol state.
        Parameters:
        ship - on patrol
        city - next city
        state - patrol state
        player - current player (ship owner)
        deadline - until the ship has to arrive
        atackListener - attack listener