Complete.Org: Mailing Lists: Archives: freeciv-dev: July 2003:
[Freeciv-Dev] Re: (PR#4536) pcity->ai.urgency not updated after reload
Home

[Freeciv-Dev] Re: (PR#4536) pcity->ai.urgency not updated after reload

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: jdorje@xxxxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#4536) pcity->ai.urgency not updated after reload
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Fri, 11 Jul 2003 08:14:46 -0700
Reply-to: rt@xxxxxxxxxxxxxx

On Fri, 11 Jul 2003, Jason Short wrote:
> > Please add it to the savegame instead. Just a handful of extra lines of
> > code.
>
> Patch attached.
>
> But doesn't this start us down some sort of slippery slope where all AI
> data is saved rather than recalculated from scratch when the saved game is
> loaded?

It is a tough call. Saving AI data gives us a better tool for debugging,
but at the cost of inflating the size of the savegames.

The reason is that when the savegame is created, things may have changed
since last time the AI generated its data, and hence, a regeneration of
these data will give different results.

Again, encapsulating the AI's turn actions into an atomistic sequence
where all data is either stored for later and therefore saved, or thrown
away and regenerated, and no in between cases like now, will significantly
clean up this issue.

  - Per




[Prev in Thread] Current Thread [Next in Thread]