[Freeciv-Dev] Re: (PR#10336) citymap cleanup
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=10336 >
Per I. Mathisen wrote:
> <URL: http://rt.freeciv.org/Ticket/Display.html?id=10336 >
>
> On Sat, 25 Sep 2004, Jason Short wrote:
>
>>- Another major bug is fixed: the citymap is never initialized. It
>>starts out as 0 but if you play multiple games it gets filled with
>>garbage. This is a severe bug and will probably never show up in any
>>tests.
>
> ...
>
>>(Side note: is this really the way it's supposed to be?Shouldn't the
>>citymap be resetat some point during the game?Shouldn't there be one
>>citymap per player?Etc., etc.)
>
> What are you talking about? citymap_turn_init() remakes the citymap every
> turn.
Ahh yes. However I forgot to change that call...it will need a new patch.
>> - citymap[x1][y1] = citymap[x1][y1]++;
>> + CITYMAP(x1, y1)++;
>>
>>the former is clearly not what was intended since it does nothing (I
>>think). I assume the latter is what was meant.
>
>
> If this was broken, I can't see how it would work at all. Do you get
> autogame differences? If this was a bug and you fixed it, AI would behave
> quite differently when choosing cities.
Savegames are identical in the one autogame I ran.
I can't see where this value is ever checked. Nobody seems to care if
the value is greater than 0. But I have no idea what this value is
supposed to mean (there is *no* documentation for citymap that I can
see) so really I have no idea what is going on.
It's also possible that the two lines of code give the same results. Is
the ++ evaluated after the = or before it? I have no idea.
jason
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Per I. Mathisen, 2004/09/25
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup,
Jason Short <=
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Jason Short, 2004/09/25
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Per I. Mathisen, 2004/09/26
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Gregory Berkolaiko, 2004/09/28
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Jason Short, 2004/09/28
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Jason Short, 2004/09/28
- [Freeciv-Dev] Re: (PR#10336) citymap cleanup, Per I. Mathisen, 2004/09/29
|
|