チケット #42567

AI: support sea caravans

登録: 2021-06-25 07:13 最終更新: 2021-11-17 01:53

報告者:
担当者:
チケットの種類:
状況:
完了
コンポーネント:
マイルストーン:
優先度:
5 - 中
重要度:
5 - 中
解決法:
修正済み
ファイル:
3

詳細

AI tries to get boats for caravans that can propel themselves to other continents. It should not try to give boats to unts that can't be transported by anything.

Tested at an Aviation ruleset version for FC3.0. It was designed to improve support for Merchant Ships and they do move sanely now but for some reason reduced in number of production in the period when Zeppelin Liners are caravans for establishing routes, but they come back after Zeps get obsoleted, probably it's the ruleset's quirk.

チケットの履歴 (11 件中 3 件表示)

2021-06-25 07:13 更新者: ihnatus
  • 新しいチケット "AI: support sea caravans" が作成されました
2021-09-07 11:28 更新者: cazfi
コメント

- Style: Some empty lines missing

- Check the logic about not "requiring" a boat when "can't have one". In that case one should consider establishing trade route over sea impossible, not possible even without a boat.

2021-09-15 02:21 更新者: ihnatus
コメント

Sorry, you mean blank lines out of the patch? I can't find ~:-() No jealousy if you delete what you don't like and commit yourself. Well, the logic seems to me as such: if we can't find a boat, the caravan just tries to go by itself where it can, if it is actually a plane or a ship, it can reach other continents, if it's a camel, it just walks to a neighboring oasis. It worked in my tests with ruleset mentioned, may I have missed some other case?

2021-09-27 09:54 更新者: cazfi
コメント

Reply To ihnatus

No jealousy if you delete what you don't like and commit yourself.

Ok, I'll make a modified version of the patch as my own proposal.

2021-09-27 10:01 更新者: cazfi
コメント

First needs to fix compile problem -> #42930 (I assume you have not compiled with --enable-debug as you've not encountered the error. Please test your future patches with that)

2021-09-27 10:48 更新者: cazfi
コメント

Patch proposal for S3_0 attached. Porting it to S3_1/master with proper civ_map handling would take some effort.

- Changed logic so that if speculated caravan can neither reach the destination by itself nor can it have a ferry for itself, we don't build it at all. Equivalent change for attempts to move existing caravan. - Worked on style (e.g. *added* missing blank lines, more of them than strictly dictated by Coding Style guideline) - Set continent number variable's type to Continent_id

What do you think? So far I've only tested that this compiles....

2021-11-14 20:28 更新者: cazfi
コメント

Reply To cazfi

Porting it to S3_1/master with proper civ_map handling would take some effort.

Checking it through, we can currently hardcode it to use wld.map. In the attached master/S3_1 version I've done that, and added a comment to uclass_need_trans_between() function header that it cannot be used for other maps. This is not ideal, but should do for now.

2021-11-17 01:53 更新者: cazfi
  • 状況オープン から 完了 に更新されました
  • 担当者(未割り当て) から cazfi に更新されました
  • 解決法受領 から 修正済み に更新されました

編集

このチケットにコメントを追加するには、ログインが必要です » ログインする