[Freeciv-Dev] Re: Diplomat menu popup on goto
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
At 2000/04/03 09:30 , David Pfitzner wrote:
>Jeff Mallatt wrote:
>
>> Attached is a patch which does the following:
>
>(Gui-independent process_caravan_arrival(), and similar
>process_diplomat_arrival() and related.)
>
>Great, thanks!
>
>> I didn't test this exhaustively; it could still easily contain a few bugs.
>
>I haven't actually tested, but from reading the code:
>(testing by inspection ;-)
>
>-- Still missing capabilities handling (easiest to be mandatory).
>
>-- Notice in caravan "while (genlist_size)" loop, there is a return
>after popup_caravan_dialog(), and the dialog functions then re-call
>process_caravan_arrival() to do more. (The "while" is just for
>caravans which may have died etc. I think the diplomat code should
>do the same: ie, return after popup_diplomat_dialog() (patch already
>does the re-call stuff).
>
>+ if (diplomat_can_do_action(punit, DIPLOMAT_ANY_ACTION,
>+ pcity->x, pcity->y)) {
>+ popup_diplomat_dialog(punit, pcity->x, pcity->y);
>+ } else {
>+ append_output_window(_("Game: You don't have enough movement
left."));
>+ }
>
>-- Also, the "movement left" case seems wrong to me: its what the
>old client-side code had, but now shouldn't the server only send
>the diplo action if there is movement left? In which case if
>diplomat_can_do_action() fails it could be for some other reason
>(eg, the city was conquered by the player in the meantime)
>(so in similar case caravan code silently ignores).
Thanks for the bug reports! The attached patch addresses these three
problems, and updates to the latest CVS.
diplomat_goto_popup-4.diff.gz
Description: Binary data
jjm
[Freeciv-Dev] Re: Diplomat menu popup on goto,
Jeff Mallatt <=
|
|