When fighting alone, especially 1V1, due to the lack of a spreader, AI resources are actually limited.
After some changes in 3.3.5, AI seems to not like to break through FOOD, often around 70 and not reaching 100. Even if the technology level is high and the food is small, it still defeat
When setting the food limit, it is necessary to determine whether this limit is the game limit or the food building limit, and whether there are any food buildings under construction or if there are resource buildings
When possible, prioritize breaking through food
When the construction fails, such as due to insufficient resources, the total_gold value is not restored and has already been modified. Does this have any impact?
In the old version, total_XXXupdata would not skip due to insufficient resources
Now there is a food limit ,afford_qty<=0 prevent updates
Should it look completely symmetrical here? maybe no need set afford_qty = need_qty
if gold_cost == 0 then
set afford_gold = need_qty
else
set afford_gold = total_gold / gold_cost
endif
if afford_gold < need_qty then
set afford_qty = afford_gold
else
set afford_qty = need_qty
endif
if wood_cost == 0 then
set afford_wood = need_qty
else
set afford_wood = total_wood / wood_cost
endif
if afford_wood < afford_qty then
set afford_qty = afford_wood
endif
if food_cost == 0 then
set afford_food = need_qty
else
set afford_food = total_food / food_cost
endif
if afford_food < afford_qty then
set afford_qty = afford_food
endif
When fighting alone, especially 1V1, due to the lack of a spreader, AI resources are actually limited. After some changes in 3.3.5, AI seems to not like to break through FOOD, often around 70 and not reaching 100. Even if the technology level is high and the food is small, it still defeat
When setting the food limit, it is necessary to determine whether this limit is the game limit or the food building limit, and whether there are any food buildings under construction or if there are resource buildings When possible, prioritize breaking through food
When the construction fails, such as due to insufficient resources, the total_gold value is not restored and has already been modified. Does this have any impact?
In the old version,
total_XXXupdata
would not skip due to insufficient resources Now there is afood limit ,afford_qty<=0
prevent updatesShould it look completely symmetrical here? maybe no need
set afford_qty = need_qty