Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2000:
[Freeciv-Dev] Re: FoW remove player bug
Home

[Freeciv-Dev] Re: FoW remove player bug

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Thue Janus Kristensen <thue@xxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: FoW remove player bug
From: Daniel Burrows <Daniel_Burrows@xxxxxxxxx>
Date: Tue, 16 May 2000 16:36:02 -0400

On Tue, May 16, 2000 at 08:39:51PM +0200, Thue Janus Kristensen <thue@xxxxxxx> 
was heard to say:
> I kinda forgot taking server_remove_player(), and the player renumbering
> that takes place, into account when I ade the FoW patch. This should make
> it work again.
> (Actually I had no idea it existed...)

  I'm not familiar with the internals of the FoW code, so I don't know whether
this is important, but something in your patch caught my eye:

-       struct tile *ptile=map_get_tile(x, y);
-       if(ptile)
-         ptile->known=WIPEBIT(ptile->known, idx);
+       struct tile *ptile = map_get_tile(x, y);
+       ptile->known = WIPEBIT(ptile->known, idx);
+       ptile->sent = WIPEBIT(ptile->known, idx);
+       ptile->assigned = WIPEBIT(ptile->known, idx);

  This /looks/ like it's clearing the "idx"th bit of ptile's members.  But
it also looks like maybe the last two should be ptile->sent and ptile->assigned.
I could be wrong, but this looks like a classic case of "x0=x1;y0=x1;z0=x1;" :)
 (instead of "x0=x1;y0=y1;z0=z1;"..I do this all the time (with proper
  formatting of course))

  Daniel

-- 
C C.
C C C.
C, C, C.
C?



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