[Freeciv-Dev] [patch #3447] map_claim_base()
Update of patch #3447 (project freeciv): Status: In Progress = Ready For Test ___ Follow-up Comment #3: - Updated against current svn - Rearranged code so that bases on the same tile are not claimed recursively, but only from outer iteration (file #16778) ___ Additional Item Attachment: File name: ClaimBase-2.patch Size:8 KB ___ Reply to this item at: http://gna.org/patch/?3447 ___ Message sent via/by Gna! http://gna.org/ ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev
[Freeciv-Dev] [patch #3447] map_claim_base()
Follow-up Comment #2, patch #3447 (project freeciv): This patch (transitional state it produces) has some chicken-and-egg design problems with territory claiming bases. Though the version I finally submitted avoided (in a hackish way - code recurses more than it needs to, but changes between rounds make it to avoid infinite recursion) most obvious problems, I now think that it doesn't work correctly when tile has multiple bases. When the recursion causes other bases to change owner, tile is already owned by new owner and as tile owner is in this transtional phase used as base owner, new owner is considered old base owner - base is not cleared from real old owner, and as it seems like base is not changing hands at all, some base capturing stuff is skipped too. ___ Reply to this item at: http://gna.org/patch/?3447 ___ Message sent via/by Gna! http://gna.org/ ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev
[Freeciv-Dev] [patch #3447] map_claim_base()
URL: http://gna.org/patch/?3447 Summary: map_claim_base() Project: Freeciv Submitted by: cazfi Submitted on: Fri 27 Jul 2012 02:03:35 AM EEST Category: general Priority: 5 - Normal Status: In Progress Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any Planned Release: 2.5.0 ___ Details: Attached WIP patch moves base ownership changes to central function of their own, map_claim_base(). This is going to be first one in series of base ownership patches. Goal of the series is to separate base ownership from border ownership. Primary reason is fixing problems related to vision providing bases (buoy). My current plan: - All bases in a tile have same owner (which can be nobody) - Bases on a tile can be owned even when tile is not (buoy can work on unowned territory) I'm not certain about other border ownership and base ownership interactions. - Can bases have no owner even if tile has owner (in a scenario with preset unowned bases) - If both tile and bases have owner, can bases be owned by player other than tile owner (unit walking to base claims base even if not territory) ___ File Attachments: --- Date: Fri 27 Jul 2012 02:03:35 AM EEST Name: ClaimBase.patch Size: 9kB By: cazfi http://gna.org/patch/download.php?file_id=16204 ___ Reply to this item at: http://gna.org/patch/?3447 ___ Message sent via/by Gna! http://gna.org/ ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev
[Freeciv-Dev] [patch #3447] map_claim_base()
Follow-up Comment #1, patch #3447 (project freeciv): This sounds a lot like what I was thinking of in bug #16385 (but I never got further than design). - All bases in a tile have same owner (which can be nobody) That's clearly what I was thinking before, but I don't think I'd thought about what happens if B's Engineer builds a new ownable base on a tile which already has A's ownable base of a different kind. - Can bases have no owner even if tile has owner (in a scenario with preset unowned bases) - If both tile and bases have owner, can bases be owned by player other than tile owner (unit walking to base claims base even if not territory) For the latter, I convinced myself that base and tile should have separate owners (after originally thinking the opposite) -- see ticket. I think that implies that the answer to the first question is yes. ___ Reply to this item at: http://gna.org/patch/?3447 ___ Message sent via/by Gna! http://gna.org/ ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev