I have the key to One Eyed Willy

Allegiance discussion not belonging in another forum.
KGJV
Posts: 1474
Joined: Tue Jul 01, 2003 7:00 am
Location: Transilvania

Post by KGJV »

Wasp wrote:QUOTE (Wasp @ Jul 30 2017, 06:05 PM) Anyhoo, I took this to Imago who revealed that immediate mode was not available in Dx9 and was likely the cause of this. I did a little research and boy did that make a lot of sense (even to me). That explained why, no matter how stripped down and filled with hard coded values, I could not get the Dx9's inputs to be correct.
I'm still trying to understand how this "make a lot of sense" in that context. Care to elaborate ?

how retained mode affect the inputs ?

In both cases (DX7 and DX9), Allegiance use a standard simple loop:

A- UpdateInput() - read input values (mouse, js, etc)
B- UpdateFrame() - update the scene (receive network code, update game logic (DoTrekUpdate) , no gfx stuff in here)
C- RenderFrame() - render the frame (immediate mode with DX7, retained mode with DX9, either way a full frame must be drawn before moving to D)
D- Sleep(30 ms) - (this prevents high cpu usage)

then loop to A. The position/orientation of the ship is calculated in B so it should be the same if the input values in A are the same.

The main difference between DX7 and DX9 code is in C (and a bit in A where DirectInput8 is used in place of DirecInput7).

I fail to see how the C step can affect the slew rate when using a js. It's either a timing issue (is C taking too long with DX9 and are some timing values/references absolute instead of relative?) or a code change not related to C was made (<- imho the most probable explanation).

To investigate further here is the whole game "main" loop:

Window::MessageLoop = infinite loop doing:
CallTimers() -> which will process expired/due timers (used for timeout stuff like server not responding for instance)
CallIdleFunctions() -> this calls EngineWindow::DoIdle which does A then B then C then D
ProcessMessage() -> read Win32 message events (handle key strokes)

Now this is complex stuff ,it's not easy to investigate without proper metrics.
Last edited by KGJV on Sun Jul 30, 2017 6:28 pm, edited 1 time in total.
Image
Wasp
Posts: 1084
Joined: Sun Aug 17, 2003 7:00 am

Post by Wasp »

Perhaps you could compare the two versions and find out where all the lag is coming from.

I forced an update at that point in wintrek.cpp where the slew code resides, even though I wasn't slewing(zooming)). It reduced input lag considerably which made me think that there was too much in the loop or a rendering lag issue.
Radulfr
Posts: 125
Joined: Sun Sep 20, 2009 9:10 am

Post by Radulfr »

Sounds to me like mouse acceleration is causing issues.

Try if this fixes it:
http://donewmouseaccel.blogspot.de/2010/03...ration-fix.html
Wasp
Posts: 1084
Joined: Sun Aug 17, 2003 7:00 am

Post by Wasp »

If you had read that thread, you'd see that I have already discussed this with MarkC back in 2011. :)

It IS a problem with an Allegiance" Dx9 project that replaced the Dx7 version of the game back in 2009. There is JUST NOW a R4 version (thanks to BT) that doesn't contain any of that Dx9 stuff and doesn't exhibit the problems R5 - R9 does. If you want to use R4, right click Allegiance in steam, select properties, then goto the beta tab.

Whether you notice it or not, whether you use a mouse or joystick or keyboard or if you have the highest kill/death ratio or most ferocious alligator mouth.., YOU ARE AFFECTED. Yeah, I know, we want the game to be "updated" and have a pretty UI...but at the sacrifice of performance?

And did I forget to mention.. THANKS TO BT who started down this journey more than 2 years ago and saw it to a finish. Countless hours of work went into this and I'm grateful to have been a part of it.
Radulfr
Posts: 125
Joined: Sun Sep 20, 2009 9:10 am

Post by Radulfr »

Wasp wrote:QUOTE (Wasp @ Mar 13 2016, 09:27 PM) The best way to see this difference is when using a joystick (of course) when you are moving swiftly from one point to another when you are closest to the deadzone.
This is from 2016. The thread isn't visible further back.
Moving swiftly would be when mouse acceleration does the most damage.

Please just do me the favor and test it. Compared to what you and whatever many devs have been through, this is nothing. And it's hardly done, if it really is an issue for everyone as you assume.
Wasp
Posts: 1084
Joined: Sun Aug 17, 2003 7:00 am

Post by Wasp »

I meant the thread that you posted a link to. As I have already said, I have discussed this with MarkC (the author of that thread you linked to), back in 2011. If you had scrolled down that page, you would have seen my posts :)

We (actually BT) has already found the issue. It's not a mouse acceleration issue. It's not a windows xp/vista vs win7+ pointer ballistic issue. No more testing is needed. It is already solved...

It was a project meant to port Dx7 to Dx9 (R5), that introduced this problem. Undoing that work, fixed the problem...Now available, R4, in the game properties/beta section of Steam.

You should see a noticeable difference in pointer (aim) behavior. If you can't see it, it's probably because you can't aim in the first place. ;)
Last edited by Wasp on Mon Dec 11, 2017 10:28 pm, edited 1 time in total.
Wasp
Posts: 1084
Joined: Sun Aug 17, 2003 7:00 am

Post by Wasp »

New development...

After mucho testing of BT's fixed client (R4 old school), it still didn't seem right. Don't get me wrong, it is 100 times better than that Dx9 thing you're playing however there is still a "wonky" behavior that I couldn't eliminate no matter what combination of tweaks I applied. The axis seem ever so slightly "off" and inconsistent. Angles are difficult to make while maintaining precision aim. Upper right to lower left slops feel different from upper left to lower right slopes (like inconsistent "stair climbing") and "rubber banding".

A little history:
Three things happened when this all began back in 2009; (1) The release of that Dx9 project (R5) that replaced R4. (2) I upgraded to Win7. (3) I upgraded my nvidia 8800 ultra for a GTX260.

I believe BT DID fix this game, so problem #1 is out of the picture (At Last)! The upgrade of my video adapter was not a major leap and both cards were Nvidia so I figured that could be rulled out (for now), so the only thing left to do was to install Vista.

Yesterday I tried BT's fixed version on Vista and to my utter amazement, the joystick and mouse were SMOOTH AS BUTTAH. I tried the current R9 on Vista...absolute $hit, loaded R4 again, like night and day.

My uber coding skill instinct says that either Win7 is introducing some driver level latency or maybe dorking with allegiance somehow with input or scaling? Whatever the case, there is no doubt that Win7+ is causing problems.
Imago
Posts: 1440
Joined: Tue Sep 23, 2003 7:00 am
Location: Minneapolis, MN
Contact:

Post by Imago »

Blame Gates!
Image

These bugs haven't been fixed yet because don't have any developers interested in fixing them up. --Tigereye
Imago's stupid-sensor is supersensitive. --RealPandemonium
The art is managing the flow of the drama to achieve the desired results. --Big_Beta_Tester
joeld wrote:But we’ve been amazed at the level to which some of the Allegiance fans have remained hard-core.
Wasp
Posts: 1084
Joined: Sun Aug 17, 2003 7:00 am

Post by Wasp »

I'm now suspecting there is a problem with the change to dinput8.

In R4, (dinput7) the mouse was controlled by windows... somehow. Switching to dinput8, windows no longer has control of mouse speed. :o

EDIT: Reverting dinput8 back to dinput7 returned mouse pointer control back over to windows. I'm hoping this will fix some of the pointer issues going around.
Last edited by Wasp on Tue Feb 27, 2018 5:40 pm, edited 1 time in total.
Post Reply