Savegame conversion for irrigation/cultivate & mine/plant from 2.6 broken
This is due to next_extra_for_tile() -> can_build_extra() not checking if irrigation_time/mining_time for the terrain is zero to disable extra building. Thus they propose converting some activities to extra building ones (they think they find suitable extra target) when they should not.
Fix should consider multi-cause extras, i.e., we should not simply add checks similar to existing road_time/base_time checks in can_build_extra() - I think those are already wrong.
Reply To cazfi
Fix should consider multi-cause extras, i.e., we should not simply add checks similar to existing road_time/base_time checks in can_build_extra() - I think those are already wrong.
Looking at EC_PLACE stuff, they are the correct way. The rule is that even for multi-cause extras (such as EC_PLACE + EC_ROAD), simply having EC_ROAD as one of the causes makes the extra to require that it's possible to build a road to the tile. Well, that does make a sense too - if something counts as a road, it can't be built where a road cannot be built. Especially the EC_BASE conflict with city tile even for multi-cause extra is absolutely necessary (EC_BASE can bring functionality that is prohibited at city tile)
Loading savegame from #44419 to master produces errors. The savegame has been saved from 2.6.5.
Looks like a problem in terrain transforming irrigate / mine conversion to cultivate / plant.
1: Unit doing illegal activity in savegame!
1: Activity: Mine, Target: Mine
and
1: Unit doing illegal activity in savegame!
1: Activity: Irrigate, Target: Irrigation