bugFreeciv - Bugs: bug #21415, AI city want for buildings not...

 
 
Show feedback again

bug #21415: AI city want for buildings not evaluated for alliance- and world-ranged effects?

Submitted by:  Jacob Nevins <jtn>
Submitted on:  Thu 02 Jan 2014 01:27:18 PM UTC  
 
Category: aiSeverity: 3 - Normal
Priority: 5 - NormalStatus: None
Assigned to: NoneOpen/Closed: Open
Release: trunk r23973Operating System: None
Planned Release: 2.5.0,2.6.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sun 05 Oct 2014 01:43:47 PM UTC, comment #1:

Anyone got an opinion on the simple fix?:
Currently AI doesn't consider building things if they might also benefit anyone else (even if only allies). Fix would be for AI to blindly consider their benefits like other buildings, and ignore the strategic implications of benefiting other players.

Jacob Nevins <jtn>
Project Administrator
Thu 02 Jan 2014 01:27:18 PM UTC, original submission:

aicity.c:base_want() invokes city_range_iterate() ("Iterate over cities within a certain range around a given city (city_here) that exist within a given city list") to get votes from each city about the usefulness of a building.

This takes account of REQ_RANGE_LOCAL/CITY/CONTINENT/PLAYER, but will never fire for ALLIANCE or WORLD, so I don't think any buildings which have (city-benefiting) effects with these ranges will be considered. (I don't know if empire-benefiting or strategic effects are considered elsewhere.)

It would be easy to add these to city_range_iterate(). However, these buildings potentially have a negative impact since they benefit other players, so perhaps the AI needs to somehow evaluate the impact of building things which benefit other players. Don't know if this is important enough to not apply the simple fix in the meantime.

(For buildings with effects at multiple ranges, only the "widest" range is considered, so a building which had one effect on the local player and a different effect worldwide would fall in this category.)

Jacob Nevins <jtn>
Project Administrator

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jtn (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 03 Jan 2014 05:24:18 AM UTCjtnPlanned Release=>2.5.0,2.6.0
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup