[Freeciv-Dev] Re: directional system: more magic code cleanups
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Wed, Sep 26, 2001 at 12:36:19AM -0400, Ross W. Wetmore wrote:
> At 10:19 AM 01/09/25 +0200, Raimar Falke wrote:
> >On Tue, Sep 25, 2001 at 03:11:26AM -0400, Ross W. Wetmore wrote:
> >> At 09:12 AM 01/09/24 +0200, Raimar Falke wrote:
> >Ok. However every piece of code which will get into cvs will be
> >reformatted.
>
> You obfuscated by you, right?
Indent.
> >Ok. From a test game:
> >
> >2: src=(43,4) dest=50,7)
> >2: orig=SE, jason=SE, ross=E, raimar=SE, raimar2=SE
> >
> >So we see that diff_x=7 diff_y=3. So we have a gradient of
> >m=diff_y/diff_x=3/7.
> >
> >Now comes the tricky part where your error is: which gradient is the
> >border between the SE part and the E part? I think your answer would
> >be 0.5. Probably because m=1 divides the quadrant. And 1/2 would
> >quarter the quadrant. THIS IS WRONG. The correct gradient is
> >tan(pi/8)=0.4142... It is now no surprise that the gradient from above
> >m=3/7=0.42857... is between 0.4142 and 0.5.
>
> Raimar LOOK AT your numbers. You need to move 7 east and 3 south. It
> should be clear as mud that the straightest direction looks like this
> with the first move to the EAST.
>
> 0 1 . . . . . .
> . . 2 3 . . . .
> . . . . 4 5 . .
> . . . . . . 6 7
>
> Your trig functions are clearly a bit out of whack. Do you know why?
Doing the example with pencil and paper:
0 . . . . . . .
. 1 2 3 . . . .
. . . . 4 5 . .
. . . . . . 6 7
But why is your solution better? Because it is symmetrical?
> I hope you come up with a new version that agrees with mine, or stop
> this nonsense and just admit that you hasve a bit more to learn in
> some things, and pay attention when people tell you something.
Yes it may be difficult to work with me but I have to understand
it. But I feel I'm really close now. Have some patience.
Raimar
--
email: rf13@xxxxxxxxxxxxxxxxx
Make a software that is foolproof, and only fools will want to use it.
- [Freeciv-Dev] Re: directional system: more magic code cleanups, (continued)
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/21
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/23
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/24
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/24
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/25
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/25
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Gregory Berkolaiko, 2001/09/25
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/25
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/25
- [Freeciv-Dev] Re: directional system: more magic code cleanups,
Raimar Falke <=
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Greg Wooledge, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Tony Stuckey, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/26
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Raimar Falke, 2001/09/27
- [Freeciv-Dev] Trigonometry of Freeciv, Gregory Berkolaiko, 2001/09/27
- [Freeciv-Dev] Re: Trigonometry of Freeciv, Raimar Falke, 2001/09/27
- [Freeciv-Dev] Re: Trigonometry of Freeciv, Raahul Kumar, 2001/09/29
- [Freeciv-Dev] Re: directional system: more magic code cleanups, Ross W. Wetmore, 2001/09/27
|
|