gen: fix some vram corruption issues
general: fix some build warnings
This commit is contained in:
parent
52df58c84d
commit
90d1d12086
|
@ -239,19 +239,19 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x026:
|
case 0x026:
|
||||||
case 0x027:
|
case 0x027:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
dest_value = Register[dest];
|
//dest_value = Register[dest];
|
||||||
ones = (dest_value ^ 0xFFFF);
|
//ones = (dest_value ^ 0xFFFF);
|
||||||
result = ones + 1;
|
//result = ones + 1;
|
||||||
Calc_FlagC(result);
|
//Calc_FlagC(result);
|
||||||
Calc_FlagO_Add(ones, 1, result);
|
//Calc_FlagO_Add(ones, 1, result);
|
||||||
result &= 0xFFFF;
|
//result &= 0xFFFF;
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 6;
|
//cycles = 6;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// ADCR
|
// ADCR
|
||||||
case 0x028:
|
case 0x028:
|
||||||
case 0x029:
|
case 0x029:
|
||||||
|
@ -262,19 +262,19 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x02E:
|
case 0x02E:
|
||||||
case 0x02F:
|
case 0x02F:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
dest_value = Register[dest];
|
//dest_value = Register[dest];
|
||||||
carry = FlagC ? 1 : 0;
|
//carry = FlagC ? 1 : 0;
|
||||||
result = dest_value + carry;
|
//result = dest_value + carry;
|
||||||
Calc_FlagC(result);
|
//Calc_FlagC(result);
|
||||||
Calc_FlagO_Add(dest_value, carry, result);
|
//Calc_FlagO_Add(dest_value, carry, result);
|
||||||
result &= 0xFFFF;
|
//result &= 0xFFFF;
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 6;
|
//cycles = 6;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// GSWD
|
// GSWD
|
||||||
case 0x030:
|
case 0x030:
|
||||||
case 0x031:
|
case 0x031:
|
||||||
|
@ -922,15 +922,15 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x1BE:
|
case 0x1BE:
|
||||||
case 0x1BF:
|
case 0x1BF:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
src = (byte)((opcode >> 3) & 0x7);
|
//src = (byte)((opcode >> 3) & 0x7);
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
result = Register[dest] & Register[src];
|
//result = Register[dest] & Register[src];
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 6;
|
//cycles = 6;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// XORR
|
// XORR
|
||||||
case 0x1C0:
|
case 0x1C0:
|
||||||
case 0x1C1:
|
case 0x1C1:
|
||||||
|
@ -1421,21 +1421,21 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x306:
|
case 0x306:
|
||||||
case 0x307:
|
case 0x307:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
addr = ReadMemory(RegisterPC++);
|
//addr = ReadMemory(RegisterPC++);
|
||||||
dest_value = Register[dest];
|
//dest_value = Register[dest];
|
||||||
addr_read = ReadMemory(addr);
|
//addr_read = ReadMemory(addr);
|
||||||
twos = (0xFFFF ^ addr_read) + 1;
|
//twos = (0xFFFF ^ addr_read) + 1;
|
||||||
result = dest_value + twos;
|
//result = dest_value + twos;
|
||||||
Calc_FlagC(result);
|
//Calc_FlagC(result);
|
||||||
Calc_FlagO_Add(dest_value, addr_read, result);
|
//Calc_FlagO_Add(dest_value, addr_read, result);
|
||||||
result &= 0xFFFF;
|
//result &= 0xFFFF;
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 10;
|
//cycles = 10;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// SUB@
|
// SUB@
|
||||||
case 0x308:
|
case 0x308:
|
||||||
case 0x309:
|
case 0x309:
|
||||||
|
@ -1612,17 +1612,17 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x386:
|
case 0x386:
|
||||||
case 0x387:
|
case 0x387:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
addr = ReadMemory(RegisterPC++);
|
//addr = ReadMemory(RegisterPC++);
|
||||||
dest_value = Register[dest];
|
//dest_value = Register[dest];
|
||||||
addr_read = ReadMemory(addr);
|
//addr_read = ReadMemory(addr);
|
||||||
result = dest_value & addr_read;
|
//result = dest_value & addr_read;
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 10;
|
//cycles = 10;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// AND@
|
// AND@
|
||||||
case 0x388:
|
case 0x388:
|
||||||
case 0x389:
|
case 0x389:
|
||||||
|
@ -1700,17 +1700,17 @@ namespace BizHawk.Emulation.CPUs.CP1610
|
||||||
case 0x3C6:
|
case 0x3C6:
|
||||||
case 0x3C7:
|
case 0x3C7:
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
dest = (byte)(opcode & 0x7);
|
//dest = (byte)(opcode & 0x7);
|
||||||
addr = ReadMemory(RegisterPC++);
|
//addr = ReadMemory(RegisterPC++);
|
||||||
dest_value = Register[dest];
|
//dest_value = Register[dest];
|
||||||
addr_read = ReadMemory(addr);
|
//addr_read = ReadMemory(addr);
|
||||||
result = dest_value ^ addr_read;
|
//result = dest_value ^ addr_read;
|
||||||
Calc_FlagS(result);
|
//Calc_FlagS(result);
|
||||||
Calc_FlagZ(result);
|
//Calc_FlagZ(result);
|
||||||
Register[dest] = (ushort)result;
|
//Register[dest] = (ushort)result;
|
||||||
cycles = 10;
|
//cycles = 10;
|
||||||
Interruptible = true;
|
//Interruptible = true;
|
||||||
break;
|
//break;
|
||||||
// XOR@
|
// XOR@
|
||||||
case 0x3C8:
|
case 0x3C8:
|
||||||
case 0x3C9:
|
case 0x3C9:
|
||||||
|
|
|
@ -16,8 +16,6 @@ namespace BizHawk
|
||||||
public byte[] ram = new byte[128];
|
public byte[] ram = new byte[128];
|
||||||
public MapperBase mapper;
|
public MapperBase mapper;
|
||||||
|
|
||||||
bool resetSignal;
|
|
||||||
|
|
||||||
// The Atari 2600 memory mapper looks something like this...usually
|
// The Atari 2600 memory mapper looks something like this...usually
|
||||||
|
|
||||||
// N/A Page #
|
// N/A Page #
|
||||||
|
|
|
@ -48,7 +48,7 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
||||||
int prg_reg_16k, chr_reg_8k;
|
int prg_reg_16k, chr_reg_8k;
|
||||||
int prg_bank_mask_16k;
|
int prg_bank_mask_16k;
|
||||||
int chr_bank_mask_8k;
|
int chr_bank_mask_8k;
|
||||||
bool low;
|
|
||||||
public override bool Configure(NES.EDetectionOrigin origin)
|
public override bool Configure(NES.EDetectionOrigin origin)
|
||||||
{
|
{
|
||||||
switch (Cart.board_type)
|
switch (Cart.board_type)
|
||||||
|
|
|
@ -24,29 +24,24 @@ Blood Shot - FPS game - some texture corruption
|
||||||
Bonkers - substantial gfx corruption
|
Bonkers - substantial gfx corruption
|
||||||
Buck Rogers crashes in a fun way
|
Buck Rogers crashes in a fun way
|
||||||
Burning Force - some gfx issues. works way better than it has in the past though!
|
Burning Force - some gfx issues. works way better than it has in the past though!
|
||||||
Castle of Illusion - doesn't boot
|
|
||||||
Cheese Cat-astrophe - crashes renderer!!
|
Cheese Cat-astrophe - crashes renderer!!
|
||||||
Chester Cheetah - freezes when starting new game
|
Chester Cheetah - freezes when starting new game
|
||||||
Chuck Rock - Music messed up
|
Chuck Rock - Music messed up
|
||||||
Contra Hard Corps: Scrolling is messed up in level 1... used to work.
|
Contra Hard Corps: Scrolling is messed up in level 1... used to work.
|
||||||
Crusader of Centy- Text boxes messed up
|
|
||||||
Dashin' Desperados .. bottom screen messed up
|
Dashin' Desperados .. bottom screen messed up
|
||||||
Death Duel crashes my renderer... (!)
|
Death Duel crashes my renderer... (!)
|
||||||
Decap Attack - Item select screen messed up
|
Decap Attack - Item select screen messed up
|
||||||
Double Dragon doesn't boot
|
Double Dragon doesn't boot
|
||||||
Devilish/Bad Omen - intro messed up.... interesting debug target
|
Devilish/Bad Omen - intro messed up.... interesting debug target
|
||||||
Dune... freezes in intro
|
Dune... freezes in intro
|
||||||
Eternal Champions... GFX issues, immediately
|
|
||||||
Exile - Immediate gfx issues... Debug target.
|
Exile - Immediate gfx issues... Debug target.
|
||||||
Exo Squad - Doesn't boot at all
|
|
||||||
F1 World Championship... Gfx issue at bottom of screen... quite cool working game though!
|
F1 World Championship... Gfx issue at bottom of screen... quite cool working game though!
|
||||||
Fatal Rewind - appears to do a read.w on FFFFFF... that would be an address error. read.l messes up too. Ergo: basically doesnt work.
|
Fatal Rewind - appears to do a read.w on FFFFFF... that would be an address error. read.l messes up too. Ergo: basically doesnt work.
|
||||||
Final Blow - Music messed up
|
Final Blow - Music messed up
|
||||||
Fire Shark - Messed up sound
|
Fire Shark - Messed up sound
|
||||||
Flavio's Raster FX Test.. doesnt work
|
Flavio's Raster FX Test.. doesnt work
|
||||||
Foreman for Real doent boot
|
Foreman for Real doent boot
|
||||||
Galaxy Force II - minor gfx corruption now...
|
Galaxy Force II - gfx issue in level select screen, and in level-end "shoot the core" part
|
||||||
Garfield... immediate gfx corruption. debug target.
|
|
||||||
Gargoyles... gameplay is nonfunctional
|
Gargoyles... gameplay is nonfunctional
|
||||||
Gauntlet 4 .. title screen messed. gfx corruption. immediately - debug target.
|
Gauntlet 4 .. title screen messed. gfx corruption. immediately - debug target.
|
||||||
Golden Axe - controls are jacked up
|
Golden Axe - controls are jacked up
|
||||||
|
@ -60,7 +55,6 @@ Jurassic Park 2 - crashes in intro
|
||||||
Landstalker - Sprite masking on bottom is too high on the screen...
|
Landstalker - Sprite masking on bottom is too high on the screen...
|
||||||
Lemmings: Sound is royally effed... gfx glitches.
|
Lemmings: Sound is royally effed... gfx glitches.
|
||||||
Marvel Land .. holy shit thats psychadelic
|
Marvel Land .. holy shit thats psychadelic
|
||||||
Mega Bomberman....gfx glitches title screen
|
|
||||||
Mega Turrican some gfx glitches
|
Mega Turrican some gfx glitches
|
||||||
Mortal Kombat...
|
Mortal Kombat...
|
||||||
MUSHA: Intro music starts too soon. Suffers from lack of 2-cell-vertical-scroll mode.
|
MUSHA: Intro music starts too soon. Suffers from lack of 2-cell-vertical-scroll mode.
|
||||||
|
@ -70,31 +64,24 @@ Outrun, minor gfx issue. maybe related to h-int timing?
|
||||||
Outrunners, some gfx issues... but not as bad as you might think!!! apparently doesnt use interlace mode?
|
Outrunners, some gfx issues... but not as bad as you might think!!! apparently doesnt use interlace mode?
|
||||||
Panorama Cotton still not working right
|
Panorama Cotton still not working right
|
||||||
Power Monger messed up
|
Power Monger messed up
|
||||||
Quackshot doesn't boot.
|
|
||||||
RamboIII - intro gfx corrupted - MAYBE GOOD DEBUGGING TARGET
|
RamboIII - intro gfx corrupted - MAYBE GOOD DEBUGGING TARGET
|
||||||
Road Blasters: was working, now has gfx glitches.
|
Shining in the Darkness: Check out sprites in the tavern... very odd
|
||||||
Shining in the Darkness: Gfx glitches, pretty severe
|
|
||||||
Skitchin doesnt boot
|
|
||||||
Sonic 2: Aside from lack of interlace mode, the shadows in the special stage are white....?
|
Sonic 2: Aside from lack of interlace mode, the shadows in the special stage are white....?
|
||||||
Sonic 3 serious gfx glitches
|
Sonic 3 serious gfx glitches
|
||||||
Star Control - Shit gets crazy
|
Star Control - Shit gets crazy
|
||||||
Steel Empire - controls messed up. probably gfx issues also.
|
Steel Empire - controls messed up. probably gfx issues also.
|
||||||
Sub-Terrania some gfx issues in intro
|
Sub-Terrania some gfx issues in intro
|
||||||
|
Super Hang-On - Sprite priority/masking isnt happening the way its supposed to on the tracks.
|
||||||
Super Fantasy Zone: Sound totally boned, missing graphics
|
Super Fantasy Zone: Sound totally boned, missing graphics
|
||||||
TaleSpin - gfx glitches
|
TaleSpin - gfx glitches
|
||||||
The Humans
|
The Humans
|
||||||
The Immortal
|
The Immortal
|
||||||
Truxton - Sound is jaaaacked.
|
Truxton - Sound is jaaaacked.
|
||||||
Verytex - gfx issues
|
Verytex - gfx issues
|
||||||
World of Illusion doesnt boot
|
|
||||||
Zero Tolerance - gfx bugs that didnt used to happen :(
|
Zero Tolerance - gfx bugs that didnt used to happen :(
|
||||||
Zombies At My Neighbors: doesnt boot really
|
Zombies At My Neighbors: doesnt boot really
|
||||||
Zoop doesnt boot
|
Zoop doesnt boot
|
||||||
|
|
||||||
Things that read from VRAM work like 50%-90%, but not 100%. It's frustrating. Kid Chameleon and Eternal Champions are examples.
|
|
||||||
|
|
||||||
Some games flicker in the rightmost columns. Is this caused by mid-frame mode shifting(32/40 col modes?) Alisia Dragoon is one example.
|
|
||||||
--- Havent seen an example of this in a long time. Maybe it's a non-issue.
|
|
||||||
|
|
||||||
======================================================
|
======================================================
|
||||||
Fixed Issues: (listed for regression testing purposes)
|
Fixed Issues: (listed for regression testing purposes)
|
||||||
|
@ -112,6 +99,21 @@ Fun-n-Games fails its fadeouts. -- Fixed CRAM reads. I failed math.
|
||||||
|
|
||||||
Sonic Spinball executes a VSRAM read -- Implemented VSRAM reads.
|
Sonic Spinball executes a VSRAM read -- Implemented VSRAM reads.
|
||||||
|
|
||||||
|
Bugs related to longword read/write VRAM. Multiple bugs were present including sign-extension and endians and crap.
|
||||||
|
- Crusader of Centy- Text boxes messed up
|
||||||
|
- Eternal Champions - immediate gfx corruption
|
||||||
|
- Garfield... immediate gfx corruption. debug target.
|
||||||
|
- Kid Chameleon - gfx corruption on bounce bricks and level-end effect
|
||||||
|
|
||||||
|
Games to test window calculation on:
|
||||||
|
- Road Blasters (doesnt use window, but Window & Nametable A are at same location)
|
||||||
|
- Out of this World - Same as Road Blasters
|
||||||
|
- Musha,Gaiares - Window at top
|
||||||
|
- Eliminate Down - Window at bottom
|
||||||
|
- Monster World 4, Wonder Boy in Monster World - Window at top - needs window scroll plane size adjustment
|
||||||
|
- D&D Warriors of the Eternal Sun - Window at bottom and at sides
|
||||||
|
- Truxton, Fire Shark - Window on Right
|
||||||
|
|
||||||
======================================================
|
======================================================
|
||||||
|
|
||||||
TODO: non-instant DMA emulation
|
TODO: non-instant DMA emulation
|
||||||
|
@ -119,10 +121,6 @@ TODO: Add 68000/VDP interrupt enable delay (one instruction, similar to After Bu
|
||||||
TODO: H-Ints timing possibly not correct... Some game raster effects work, others don't work as expected. (could be HVC tho)
|
TODO: H-Ints timing possibly not correct... Some game raster effects work, others don't work as expected. (could be HVC tho)
|
||||||
TODO: Test DMA/ VDP command words.... I'm not at all convinced that VRAM is always correct
|
TODO: Test DMA/ VDP command words.... I'm not at all convinced that VRAM is always correct
|
||||||
|
|
||||||
TODO: Seems like the Window should be high-priority... or Sprites aren't getting masked or something. Sprites routinely draw over window.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
==============
|
==============
|
||||||
Notable games:
|
Notable games:
|
||||||
|
@ -142,4 +140,10 @@ Games that use VRAM->VRAM Copy: D&D Warriors of the Eternal Sun, MUSHA, Devilish
|
||||||
Games that require accurate VRAM fill emulation include Thunder Force IV,
|
Games that require accurate VRAM fill emulation include Thunder Force IV,
|
||||||
Contra Hard Corps, Revenge of Shinobi, Taiga Drama, and Sword of Vermillion.
|
Contra Hard Corps, Revenge of Shinobi, Taiga Drama, and Sword of Vermillion.
|
||||||
|
|
||||||
Sonic Spinball reads from VSRAM
|
Sonic Spinball reads from VSRAM
|
||||||
|
|
||||||
|
Games known to use 2-cell vertical scroll mode:
|
||||||
|
- Air Diver
|
||||||
|
- Exo Squad
|
||||||
|
- Contra Hard Corps (giant robot boss on stage 1)
|
||||||
|
- MUSHA (stage 3)
|
||||||
|
|
|
@ -59,6 +59,8 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
|
|
||||||
public bool VdpDebug = false;
|
public bool VdpDebug = false;
|
||||||
|
|
||||||
|
public Func<int> GetPC;
|
||||||
|
|
||||||
public GenVDP()
|
public GenVDP()
|
||||||
{
|
{
|
||||||
WriteVdpRegister(00, 0x04);
|
WriteVdpRegister(00, 0x04);
|
||||||
|
@ -105,7 +107,7 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
|
|
||||||
public void WriteVdpControl(ushort data)
|
public void WriteVdpControl(ushort data)
|
||||||
{
|
{
|
||||||
Log.Note("VDP", "Control Write {0:X4}", data);
|
Log.Note("VDP", "Control Write {0:X4} (PC={1:X6})", data, GetPC());
|
||||||
|
|
||||||
if (ControlWordPending == false)
|
if (ControlWordPending == false)
|
||||||
{
|
{
|
||||||
|
@ -171,14 +173,14 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
|
|
||||||
public void WriteVdpData(ushort data)
|
public void WriteVdpData(ushort data)
|
||||||
{
|
{
|
||||||
Log.Note("VDP", "Data port write: {0:X4}", data);
|
Log.Note("VDP", "Data port write: {0:X4} (PC={1:X6})", data, GetPC());
|
||||||
ControlWordPending = false;
|
ControlWordPending = false;
|
||||||
|
|
||||||
// byte-swap incoming data when A0 is set
|
// byte-swap incoming data when A0 is set
|
||||||
if ((VdpDataAddr & 1) != 0)
|
if ((VdpDataAddr & 1) != 0)
|
||||||
{
|
{
|
||||||
data = (ushort)((data >> 8) | (data << 8));
|
data = (ushort)((data >> 8) | (data << 8));
|
||||||
Log.Error("VDP", "VRAM byte-swap is happening because A0 is not 0");
|
Log.Error("VDP", "VRAM byte-swap is happening because A0 is not 0. [{0:X4}] = {1:X4}", VdpDataAddr, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (VdpDataCode & 0xF)
|
switch (VdpDataCode & 0xF)
|
||||||
|
|
|
@ -125,8 +125,10 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
#if MUSASHI
|
#if MUSASHI
|
||||||
Musashi.Init();
|
Musashi.Init();
|
||||||
Musashi.Reset();
|
Musashi.Reset();
|
||||||
|
VDP.GetPC = () => Musashi.PC;
|
||||||
#else
|
#else
|
||||||
MainCPU.Reset();
|
MainCPU.Reset();
|
||||||
|
VDP.GetPC = () => MainCPU.PC;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,7 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
|
|
||||||
if (address >= 0xE00000) // Work RAM
|
if (address >= 0xE00000) // Work RAM
|
||||||
{
|
{
|
||||||
maskedAddr = address & 0xFFFF;
|
maskedAddr = address & 0xFFFE;
|
||||||
return (short)((Ram[maskedAddr] << 8) | Ram[maskedAddr + 1]);
|
return (short)((Ram[maskedAddr] << 8) | Ram[maskedAddr + 1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -80,6 +80,14 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
return (Ram[maskedAddr] << 24) | (Ram[maskedAddr + 1] << 16) | (Ram[maskedAddr + 2] << 8) | Ram[maskedAddr + 3];
|
return (Ram[maskedAddr] << 24) | (Ram[maskedAddr + 1] << 16) | (Ram[maskedAddr + 2] << 8) | Ram[maskedAddr + 3];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (address >= 0xC00000)
|
||||||
|
{
|
||||||
|
//Console.WriteLine("long-read from VDP");
|
||||||
|
short msw = ReadWord(address);
|
||||||
|
short msl = ReadWord(address + 2);
|
||||||
|
return (msw << 16) | (ushort) msl;
|
||||||
|
}
|
||||||
|
|
||||||
// try to handle certain things separate if they need to be separate? otherwise handle as 2x readwords?
|
// try to handle certain things separate if they need to be separate? otherwise handle as 2x readwords?
|
||||||
{
|
{
|
||||||
return ((ushort)ReadWord(address) | (ushort)(ReadWord(address + 2) << 16));
|
return ((ushort)ReadWord(address) | (ushort)(ReadWord(address + 2) << 16));
|
||||||
|
@ -197,7 +205,7 @@ namespace BizHawk.Emulation.Consoles.Sega
|
||||||
if (address >= 0xC00000)
|
if (address >= 0xC00000)
|
||||||
{
|
{
|
||||||
WriteWord(address, (short)(value >> 16));
|
WriteWord(address, (short)(value >> 16));
|
||||||
WriteWord(address, (short)value);
|
WriteWord(address+2, (short)value);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -530,7 +530,6 @@ namespace BizHawk.MultiClient
|
||||||
class UIDisplay
|
class UIDisplay
|
||||||
{
|
{
|
||||||
public string Message;
|
public string Message;
|
||||||
public DateTime ExpireAt;
|
|
||||||
public int X;
|
public int X;
|
||||||
public int Y;
|
public int Y;
|
||||||
public bool Alert;
|
public bool Alert;
|
||||||
|
|
|
@ -350,7 +350,6 @@ namespace BizHawk.MultiClient
|
||||||
|
|
||||||
private byte[] GetRomBytes()
|
private byte[] GetRomBytes()
|
||||||
{
|
{
|
||||||
byte[] bytes;
|
|
||||||
string path = Global.MainForm.CurrentlyOpenRom;
|
string path = Global.MainForm.CurrentlyOpenRom;
|
||||||
if (path == null)
|
if (path == null)
|
||||||
{
|
{
|
||||||
|
@ -376,8 +375,6 @@ namespace BizHawk.MultiClient
|
||||||
return File.ReadAllBytes(path);
|
return File.ReadAllBytes(path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return new byte[0];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void SetMemoryDomain(int pos)
|
private void SetMemoryDomain(int pos)
|
||||||
|
|
|
@ -26,12 +26,6 @@ namespace BizHawk
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
}
|
}
|
||||||
|
|
||||||
private class DiscRecord
|
|
||||||
{
|
|
||||||
public Disc Disc;
|
|
||||||
public string BaseName;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void MainDiscoForm_Load(object sender, EventArgs e)
|
private void MainDiscoForm_Load(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue