Reply To ihnatus
{{{ bool walls = city_got_defense_effect(pcity, NULL); }}} Since defense effects are mostly unit class related, we get FALSE here.
Has city_got_defense_effect() changed to do the checking with "Certain"? I think the problem here used to be that it could not tell Coastal Defense apart from City Walls, and some comments still refer to that.
Reply To cazfi
Has city_got_defense_effect() changed to do the checking with "Certain"?
Has it ever been different? It uses, underlyingly, get_target_bonus_effects() that evaluates to RPT_CERTAIN.
Reply To ihnatus
Reply To cazfi
Has city_got_defense_effect() changed to do the checking with "Certain"?
Has it ever been different? It uses, underlyingly, get_target_bonus_effects() that evaluates to RPT_CERTAIN.
Ok. Then there has been wrong assumptions (likely by me, but thankfully so long ago that I don't remember. :-)
More a meta-task related to HRM923112 and #45592, maybe I have missed some more tickets. Just some code location2s seem totally unworking. In autogames, I see whole continents conquered by a handful of barbarians because tbe cities are too busy building libraries or too failed to upkeep a lame warrior. Now, one of places that I'm almost sure does not work, dai_process_defender_want in daimilitary.c:
Since defense effects are mostly unit class related, we get FALSE here. This variable is not modified, some redundant check. Also, I have already noticed some stange treatment of UTYF_BADCITYDEFENDER across the code.