http://bugs.winehq.org/show_bug.cgi?id=15866
Summary: MechCommander 2: DSERR_CONTROLUNAVAIL errors Product: Wine Version: 1.0.1 Platform: PC URL: http://www.mechcommander.org OS/Version: Linux Status: UNCONFIRMED Severity: enhancement Priority: P2 Component: directx-dsound AssignedTo: wine-bugs@winehq.org ReportedBy: georg298@gmx.de
Starting the game with
WINEDLLOVERRIDES="dpnet=n" wine MC2Rel.exe -window /gosnoblade /gosusehw
it will display many
FAILED (0x8878001e - DSERR_CONTROLUNAVAIL) - SetPan(0x8fa89a0: 0)
errors. These errors occur each time a sound notification or similar (e.g. hovering the mouse over a button in the menu or firing a weapon inside the game) is played. The reason is the function IDirectSoundBufferImpl_SetPan inside buffer.c from dsound dll. The following code is the reason:
/* You cannot use both pan and 3D controls */ if (!(This->dsbd.dwFlags & DSBCAPS_CTRLPAN) || (This->dsbd.dwFlags & DSBCAPS_CTRL3D)) { WARN("control unavailable\n"); return DSERR_CONTROLUNAVAIL; }
Is the logic here correct? Shouldn't "if(!A || B)" really be if(!(A || B)) ? However the comment "You cannot use both pan and 3D controls" doesn't make any sense in both cases, I think. If I change it accordingly, it will work (not display these errors any more):
/* You cannot use both pan and 3D controls */ if (!((This->dsbd.dwFlags & DSBCAPS_CTRLPAN) || (This->dsbd.dwFlags & DSBCAPS_CTRL3D))) { WARN("control unavailable\n"); return DSERR_CONTROLUNAVAIL; }
Changing it according to the comment to if(A && B) doesn't work.
I hope I provided enough information. I don't really know what I did there.