mirror of
https://github.com/RetroDECK/Supermodel.git
synced 2024-11-22 13:55:38 +00:00
Stretch the time the ping_pong bit flips a bit to bump writes into correct frame. Otherwise they end up getting written at like 99.8% of the frame and overlapping with the next.
This commit is contained in:
parent
ed2816cea4
commit
e1827cfd13
|
@ -553,20 +553,18 @@ UINT8 CModel3::ReadInputs(unsigned reg)
|
||||||
adc[1] = (UINT8)Inputs->analogGunX[1]->value;
|
adc[1] = (UINT8)Inputs->analogGunX[1]->value;
|
||||||
adc[3] = (UINT8)Inputs->analogGunY[1]->value;
|
adc[3] = (UINT8)Inputs->analogGunY[1]->value;
|
||||||
|
|
||||||
/*
|
|
||||||
// Unclear why this is necessary or how to cleanly fix it, so I'm
|
// Unclear why this is necessary or how to cleanly fix it, so I'm
|
||||||
// disabling it but leaving it here for future reference. The proper fix is
|
// disabling it but leaving it here for future reference. The proper fix is
|
||||||
// probably to allow users to define inverted controls for this game only,
|
// probably to allow users to define inverted controls for this game only,
|
||||||
// which means the input system must support loading per-game config (not
|
// which means the input system must support loading per-game config (not
|
||||||
// all analog_gun games require axis inversion to be playable).
|
// all analog_gun games require axis inversion to be playable).
|
||||||
if (m_game.name == "lostwsga" || m_game.name == "lostwsgo")
|
if (m_game.name == "lostwsga" || m_game.name == "lostwsgo")
|
||||||
{ // to do, not a string compare
|
{ // to do, not a string compare
|
||||||
adc[0] = (UINT8)Inputs->analogGunX[0]->value; // order is different for some reason in lost world
|
adc[0] = (UINT8)Inputs->analogGunX[0]->value; // order is different for some reason in lost world
|
||||||
adc[1] = 255 - (UINT8)Inputs->analogGunY[0]->value; // why are values inverted? is this the wrong place to fix this
|
adc[1] = 255 - (UINT8)Inputs->analogGunY[0]->value; // why are values inverted? is this the wrong place to fix this
|
||||||
adc[2] = (UINT8)Inputs->analogGunX[1]->value;
|
adc[2] = (UINT8)Inputs->analogGunX[1]->value;
|
||||||
adc[3] = 255 - (UINT8)Inputs->analogGunY[1]->value;
|
adc[3] = 255 - (UINT8)Inputs->analogGunY[1]->value;
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((m_game.inputs & Game::INPUT_SKI))
|
if ((m_game.inputs & Game::INPUT_SKI))
|
||||||
|
@ -2083,7 +2081,7 @@ void CModel3::RunMainBoardFrame(void)
|
||||||
unsigned gapCycles = (unsigned)((float)frameCycles * 2.5f / 100.0f); // we need a gap between asserting irq2 & irq 0x40
|
unsigned gapCycles = (unsigned)((float)frameCycles * 2.5f / 100.0f); // we need a gap between asserting irq2 & irq 0x40
|
||||||
unsigned offsetCycles = (unsigned)((float)frameCycles * 33.f / 100.0f);
|
unsigned offsetCycles = (unsigned)((float)frameCycles * 33.f / 100.0f);
|
||||||
unsigned dispCycles = frameCycles - gapCycles - offsetCycles;
|
unsigned dispCycles = frameCycles - gapCycles - offsetCycles;
|
||||||
unsigned statusCycles = (unsigned)((float)frameCycles * (0.001f));
|
unsigned statusCycles = (unsigned)((float)frameCycles * (0.005f));
|
||||||
|
|
||||||
// we think a frame looks like this on the model 2
|
// we think a frame looks like this on the model 2
|
||||||
// 66% of frame
|
// 66% of frame
|
||||||
|
|
Loading…
Reference in a new issue