fire-eggs / CivOne

An open source implementation of Sid Meier's Civilization 1 using C# and .NET.
Creative Commons Zero v1.0 Universal
21 stars 4 forks source link

Barbarian ship disappeared too fast #66

Open fire-eggs opened 5 years ago

fire-eggs commented 5 years ago
  1. get 'barbarian invasion' warning at turn x; barbarians don't land
  2. get 'barbarian invasion' warning at turn x+1; barbarians land
  3. barbarian ship disappears

A: don't double-warn: barbarians should land at turn x B: barbarian ship should not disappear until turn AFTER barbarians land

fire-eggs commented 4 years ago

RE: item A: see issue #103

RE: item B: In AI.Barbarians.cs, BarbarianMoveWater, the first check is to see if the ship is empty, and if it is, the ship is destroyed. This logic may take effect the same turn as when the units on the ship disembark.

I think a "passengers disembarked" tracker is needed, set to the turn # all units disembarked. Until that turn # is exceeded, the ship should not disband.