Complete.Org: Mailing Lists: Archives: freeciv-dev: January 2005:
[Freeciv-Dev] (PR#9856) RFC: caravans advisor
Home

[Freeciv-Dev] (PR#9856) RFC: caravans advisor

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] (PR#9856) RFC: caravans advisor
From: "Benoit Hudson" <bh@xxxxxxxxxxxxxxxxxxx>
Date: Sun, 9 Jan 2005 15:38:31 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=9856 >

> [per - Sun Jan 09 20:36:29 2005]:
>         handle_unit_help_build_wonder(pplayer, punit->id);
> -      }
> +      freelog(LOG_CARAVAN, "%s's caravan %d helped build wonder in %s",
> +          pplayer->name, punit->id, wonder_city->name);
> 
> This does not look sane. After handle_unit_help_build_wonder() punit has
> likely been freed.

Fixed.

> You do not touch ai_choose_help_wonder(). What role does it play now?
>
> You do not check if the caravan might have died during goto. This is
> necessary (autoattack, huts).

The old code didn't do either of these, so I don't really have an 
answer for you.  Why would it have worked before?  Was it buggy?

Attachment: caravan_ai.diff
Description: Binary data


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