Package horizons :: Package ai :: Package aiplayer :: Package strategy :: Module strategymanager :: Class PirateStrategyManager
[hide private]
[frames] | no frames]

Class PirateStrategyManager

source code

StrategyManager --+
                  |
                 PirateStrategyManager

Instance Methods [hide private]
 
__init__(self, owner) source code
 
get_ships_for_mission(self) source code
 
__init(self, owner) source code
    Inherited from StrategyManager
 
_load(self, db) source code
collections.namedtuple
calculate_player_balance(self, player, trimming_factor=10.0, linear_boundary=10.0)
Calculate power balance between self.owner and other player.
source code
float
calculate_player_power_balance(self, other_player)
Calculates power balance between two players.
source code
 
calculate_player_terrain_balance(self, other_player)
Calculates balance between sizes of terrain, i.e.
source code
 
calculate_player_wealth_balance(self, other_player)
Calculates wealth balance between two players.
source code
 
conditions(self) source code
 
end(self) source code
 
end_mission(self, mission) source code
 
get_missions(self, condition=None)
Get missions filtered by certain condition (by default return all missions)
source code
 
handle_strategy(self) source code
 
lock_condition(self, condition, mission) source code
 
report_failure(self, mission, msg) source code
 
report_success(self, mission, msg) source code
bool
request_to_pause_mission(self, mission, **environment)
Returns: returns True if mission is allowed to pause, False otherwise
source code
 
save(self, db) source code
 
start_mission(self, mission) source code
 
tick(self) source code
 
unlock_condition(self, mission) source code
Class Methods [hide private]
 
load(cls, db, owner) source code
Class Variables [hide private]
    Inherited from StrategyManager
  log = logging.getLogger("ai.aiplayer.fleetmission")
Method Details [hide private]

__init__(self, owner)
(Constructor)

source code 
Overrides: StrategyManager.__init__

get_ships_for_mission(self)

source code 
Overrides: StrategyManager.get_ships_for_mission

load(cls, db, owner)
Class Method

source code 
Overrides: StrategyManager.load