|
From: Bernhard K. <ber...@gm...> - 2003-02-22 21:51:27
|
Hi,
thanks for the help with getting current torcs running,
I'm driving the human with mouse and find it a bit very sensitive
to control for me of the car is running at high speed.
So my idea was to make the mouse sensivity a function of the speed
of the car and reduce sensivity when the speed is high to compensate
for the stronger effect of turning in the steer and thus make it
easy to control the car at high speeds with the mouse. Thus you
can use the resulution of the mouse move to to finer grained
steer control at high speed, which is good to avoid not intented
turns or so and made me able to reach a much better lap time
on the default track(which is great!) with mouse.
I'm using the trackpad from the notebook as mouse, but I think
what I found with the trackpad should apply to a normal mouse
and trackballs(all mouse pointer-based controlled steering) as well.
This is the patch I tried and helped me much to control the
steer fine enough at high speeds:
--- src/drivers/human/human.cpp 30 Dec 2002 11:30:20 -0000 1.15
+++ src/drivers/human/human.cpp 22 Feb 2003 21:24:15 -0000
@@ -393,9 +393,13 @@
if (mouseMove < 0) {
mouseAxis[1] = -mouseMove;
+ mouseAxis[1] -= car->_speed_x*2;
mouseAxis[0] = 0;
} else {
mouseAxis[0] = mouseMove;
+ mouseAxis[0] -= car->_speed_x*2;
mouseAxis[1] = 0;
}
mouseMove = (float)(refMouse.Y - mouse->Y);
Maybe the change should be applied to another place instead and
make it only one line, but I just want the people know of this
idea and give an example how it looks like that is could work
(or works by luck most of the time).
I think Eric should best if it is a useable generally, I was
not reading the driver howto in detail so far and did not much
with torcs, this is just my first patch which seemed to work
for me for the track and the car I've tested it with(the default
track and car)
Best regards and many thanks for torcs, it's great fun!
Bernd
On Sun, 9 Feb 2003, Eric Espie wrote:
> Hi,
>
> As CVS do not remember versions on directories, it is
> necessary to use the -P option with the cvs co or
> the cvs export functions to avoid getting old empty directories.
>
> So, you have to remove all the empty directories by yourself now,
> and run again make datainstall
>
> Without the data, the programs crashes badly as it is really not
> robust when the data files are not present.
>
> Eric.
|