Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2004:
[Freeciv-Dev] Re: (PR#6972) Wishlist: units lost on arctic
Home

[Freeciv-Dev] Re: (PR#6972) Wishlist: units lost on arctic

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] Re: (PR#6972) Wishlist: units lost on arctic
From: "Marcelo Burda" <mburda@xxxxxxxxx>
Date: Tue, 4 May 2004 17:27:59 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=6972 >

Le mer 05/05/2004 à 02:02, Jason Short a écrit :
> <URL: http://rt.freeciv.org/Ticket/Display.html?id=6972 >
> 
> A few minor issues:
> 
> In is_pos_dangerous you say:
> 
> +/**********************************************************************
> +  An example of position-dangerous callback.  For all units.
> +  FIXME: it cheats.
> +***********************************************************************/
> +static bool is_pos_dangerous(int x, int y, enum known_type known,
> +                                    struct pf_parameter *param)
> 
> this needs more explanation.  How are we cheating here?  Just by 
> bypassing the unit_loss_pct function?  Or by assuming this unit is not a 
> tririeme?
 bypassing the unit_loss_pct function is not good idea! the original
autor of this pf make some comment for triremes.(i think the original
autor think that!) 
actualy this is not a problem for TER_UNSAFE, there is a fixed 15%
danger for all units. but this can change latter.
> 
> Then right below you have
> 
> +  } else if (base_unsafe_terrain_loss_pct(unit_owner(punit), punit) > 0)
> +  {
> +    parameter->turn_mode = TM_WORST_TIME;
> +    parameter->is_pos_dangerous = is_pos_dangerous;
> +  } /* FIX ME triremes are safes in unsafe oceans where best naval
> +       unit are unsafe! */
>   }
> 
> I don't understand this comment.  Are you saying that if the ocean is 
> TER_UNSAFE then tririeme_is_pos_dangerous will not catch it because it 
> only checks for coasts?
yes(only in pf), but this is ok until we include new oceans terrains,
actualy ocean is not unsafe and triremes never move over ice!
when including new terrains type danerous code of pf will be thinked
fondemantaly.

> 
> I think the rest looks okay.
> 
> jason
-- 
 . /  .     '    ,    .      (*)   '        `     '      `    .    
  |    ,  |   `     ,     .      ,   '  Marcelo Julián Burda      .
 /  '     \     `     \@_     '      .        '      `        '    
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~




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