-
Notifications
You must be signed in to change notification settings - Fork 228
Pirates
This is only representing the AI for the pirate ships self, nothing about the isle infrastructure or trading.
The pirates will be shipping around. They can capture ships to increase their fleet or destroy ships of the other players. With special ships (with large cannons) they also are able to attack buildings coastlines like fishers or branch offices. The possibility's of pirates are linked to the tier of the player/players. A higher tier for the player results in stronger or more pirates. Pirate ships can increase their arming like other ships. Maybe the player cant see what arming a pirate ship has, so a fight become more exiting.
- the AI should depend on the players skills, maybe on:
- game difficulty
- amount of gold / acount balance
- inhabitants
- amount of battleships
- used area of the map
- bigger area of the player -> stronger AI
- ability to define the pirate AI skills, a good place could be the map file
! NOTE: all this stuff depends on battleship's speed !
attack time interval becomes shorter for higher stages
Stage 1:
- one pirate ship
- drive around
- follow the players ship
Stage 2:
- up to 3 pirate ships
- drive around
- follow the players ship, attack from time to time player ships, but doesn’t destroy them
Stage 3:
- up to 5 pirate ships
- drive around
- follow the players ship, attack from time to time player ships, destroy them
- start attacking buildings in the near of the coast
Stage 4 :
- up to 10 pirate ships (only for really large maps)
- drive around
- follow the players ship, attack from time to time player ships, destroy them
- start attacking buildings in the near of the coast and destroy them
Following methods are needed for the AI of pirates:
- driveAround
- the ship will be drive around randomly
- maybe theres something like this alreaady implemented for the trader ?!
- follow
- follow another ship, this can be every ship, expect of ships of there own pirate clan
- example: traders, player ships, another pirate ship (from another clans) can be followed, same for attack and destroy
- -> new method: need to specify if a ship belongs to a friendly or an enemy's side
- tryToAttack(target,intensity,suicidal=0)
- targets might be players at all, attacking certain structures or ships as well as attacking everybody hostile to protect others. If suicidal, no escape calculations are needed which might alter the AI behaviour. A low intensity will not cause sunk ships.
- driveBack
- after an attack attempt the ship will want to drive to the fortress or cave on the home isle
- first pirate ship https://github.com/unknown-horizons/unknown-horizons/blob/master/content/gfx/units/ships/pirates/as_pirate0/idle/0/0.png
- a cave
- old fortress