[Freeciv-Dev] Re: Massive Patch!
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Fri, Dec 28, 2001 at 08:59:35PM +0000, Gregory Berkolaiko wrote:
> --- Chris Richards <chrisr@xxxxxxxxxxxxxxxx> wrote:
> > This is a massive patch which does some clean up in autoattack.c. It
> > removes a redundant variable and conditional. Beware, it isn't for
> > the weak of heart.
>
> My, it's huge. You shouldn't send big files to the general list, upload
> it instead. And it's not even gzipped!
>
> I looked quickly at it and I think it should go in.
Always these rash decisions with Freeciv! I thought style guide prescribed
if(!enemy) return;
On a more serious note, I don't know what the style guide says, and
I can't find it on the web site yet. I'll see if I can link it in.
> G.
>
> >
> > > Index: server/autoattack.c
> > ===================================================================
> > RCS file: /home/freeciv/CVS/freeciv/server/autoattack.c,v
> > retrieving revision 1.29
> > diff -u -w -b -r1.29 autoattack.c
> > --- server/autoattack.c 2001/10/30 10:34:23 1.29
> > +++ server/autoattack.c 2001/12/28 20:32:58
> > @@ -149,14 +149,13 @@
> > {
> > int id = punit->id;
> > struct unit *enemy;
> > - int debug = 0;
> >
> > enemy=search_best_target(pplayer,pcity,punit);
> >
> > /* nothing found */
> > if(enemy == NULL) return;
> >
> > - if (debug) freelog(LOG_DEBUG, "launching attack");
> > + freelog(LOG_DEBUG, "launching attack");
> >
> > notify_player_ex(pplayer, enemy->x, enemy->y, E_NOEVENT,
> > _("Game: Auto-Attack: %s's %s attacking %s's %s"),
--
Reinier
|
|