small fixes

This commit is contained in:
dborth 2009-07-17 18:01:31 +00:00
parent 6cd1e80ef1
commit a44b9cf52e
4 changed files with 33 additions and 111 deletions

View File

@ -1,90 +0,0 @@
my_list = Split("""
01-222.cpp
103.cpp
106.cpp
108.cpp
112.cpp
117.cpp
120.cpp
121.cpp
15.cpp
164.cpp
175.cpp
176.cpp
177.cpp
178.cpp
179.cpp
183.cpp
185.cpp
186.cpp
187.cpp
189.cpp
199.cpp
208.cpp
222.cpp
23.cpp
235.cpp
3d-block.cpp
411120-c.cpp
43.cpp
57.cpp
603-5052.cpp
68.cpp
8157.cpp
8237.cpp
830118C.cpp
88.cpp
90.cpp
95.cpp
a9711.cpp
a9746.cpp
addrlatch.cpp
ax5705.cpp
bandai.cpp
bmc13in1jy110.cpp
bmc42in1r.cpp
bmc64in1nr.cpp
bmc70in1.cpp
bonza.cpp
bs-5.cpp
copyfami_mmc3.cpp
dance.cpp
datalatch.cpp
deirom.cpp
dream.cpp
__dummy_mapper.cpp
edu2000.cpp
fk23c.cpp
ghostbusters63in1.cpp
gs-2004.cpp
gs-2013.cpp
h2288.cpp
karaoke.cpp
kof97.cpp
konami-qtai.cpp
ks7032.cpp
malee.cpp
mmc1.cpp
mmc3.cpp
mmc5.cpp
n-c22m.cpp
n106.cpp
n625092.cpp
novel.cpp
sachen.cpp
sc-127.cpp
sheroes.cpp
sl1632.cpp
smb2j.cpp
subor.cpp
super24.cpp
supervision.cpp
t-227-1.cpp
t-262.cpp
tengen.cpp
tf-1201.cpp
""")
for x in range(len(my_list)):
my_list[x] = 'boards/' + my_list[x]
Return('my_list')

View File

@ -65,8 +65,12 @@
#include "drivers/win/memwatch.h"
#include "drivers/win/tracer.h"
#else
#ifdef GEKKO
#include "driver.h"
#else
#include "drivers/sdl/sdl.h"
#endif
#endif
using namespace std;
@ -284,7 +288,7 @@ static void AllocBuffers()
void win_AllocBuffers(uint8 **GameMemBlock, uint8 **RAM);
win_AllocBuffers(&GameMemBlock, &RAM);
#else
#else
GameMemBlock = (uint8*)FCEU_gmalloc(131072);
RAM = (uint8*)FCEU_gmalloc(0x800);
@ -296,7 +300,7 @@ static void FreeBuffers() {
#ifdef _USE_SHARED_MEMORY_
void win_FreeBuffers(uint8 *GameMemBlock, uint8 *RAM);
win_FreeBuffers(GameMemBlock, RAM);
#else
#else
FCEU_free(GameMemBlock);
FCEU_free(RAM);
#endif
@ -306,7 +310,7 @@ static void FreeBuffers() {
uint8 PAL=0;
static DECLFW(BRAML)
{
{
RAM[A]=V;
#ifdef _S9XLUA_H
FCEU_LuaWriteInform();
@ -604,7 +608,7 @@ void FCEUI_Emulate(uint8 **pXBuf, int32 **SoundBuf, int32 *SoundBufSize, int ski
r = FCEUPPU_Loop(skip);
if (skip != 2) ssize=FlushEmulateSound(); //If skip = 2 we are skipping sound processing
#ifdef WIN32
//These Windows only dialogs need to be updated only once per frame so they are included here
UpdateCheatList();
@ -623,12 +627,12 @@ void FCEUI_Emulate(uint8 **pXBuf, int32 **SoundBuf, int32 *SoundBufSize, int ski
*SoundBuf=0;
*SoundBufSize=0;
}
else
else
{
*SoundBuf=WaveFinal;
*SoundBufSize=ssize;
}
if (EmulationPaused&2 && ( !frameAdvanceLagSkip || !lagFlag) )
//Lots of conditions here. EmulationPaused&2 must be true. In addition frameAdvanceLagSkip or lagFlag must be false
{
@ -638,12 +642,12 @@ void FCEUI_Emulate(uint8 **pXBuf, int32 **SoundBuf, int32 *SoundBufSize, int ski
if(soundoptions&SO_MUTEFA) //mute the frame advance if the user requested it
*SoundBufSize=0; //keep sound muted
#endif
}
currMovieData.TryDumpIncremental();
if (lagFlag)
if (lagFlag)
{
lagCounter++;
justLagged = true;
@ -655,8 +659,8 @@ void FCEUI_Emulate(uint8 **pXBuf, int32 **SoundBuf, int32 *SoundBufSize, int ski
}
void FCEUI_CloseGame(void)
{
if(!FCEU_IsValidUI(FCEUI_CLOSEGAME))
{
if(!FCEU_IsValidUI(FCEUI_CLOSEGAME))
return;
CloseGame();
}
@ -693,7 +697,7 @@ void hand(X6502 *X, int type, unsigned int A)
}
int suppressAddPowerCommand=0; // hack... yeah, I know...
void PowerNES(void)
void PowerNES(void)
{
//void MapperInit();
//MapperInit();
@ -732,7 +736,7 @@ void PowerNES(void)
extern int disableBatteryLoading;
if(disableBatteryLoading)
GameInterface(GI_RESETSAVE);
timestampbase=0;
LagCounterReset();
@ -749,9 +753,9 @@ void FCEU_ResetVidSys(void)
int w;
if(GameInfo->vidsys==GIV_NTSC)
w=0;
w=0;
else if(GameInfo->vidsys==GIV_PAL)
w=1;
w=1;
else
w=FSettings.PAL;
@ -891,7 +895,7 @@ void UpdateAutosave(void)
{
if(!EnableAutosave)
return;
char * f;
AutosaveCounter = (AutosaveCounter + 1) % 256;
if(AutosaveCounter == 0)
@ -1075,7 +1079,7 @@ bool FCEUXLoad(const char *name, FCEUFILE *fp)
cart->chrPages = head.VROM_size;
cart->mirroring = (head.ROM_type&1);
cart->mirroring = (head.ROM_type&1);
if(head.ROM_type&8) cart->mirroring=2;
//skip trainer
@ -1097,7 +1101,7 @@ bool FCEUXLoad(const char *name, FCEUFILE *fp)
ResetCartMapping();
SetupCartPRGMapping(0,(uint8*)cart->PRG,cart->prgSize,0);
SetupCartCHRMapping(0,(uint8*)cart->CHR,cart->chrSize,0);
return true;
}
@ -1108,4 +1112,4 @@ uint8 FCEU_ReadRomByte(uint32 i) {
if(i < 16+PRGsize[0])return PRGptr[0][i-16];
if(i < 16+PRGsize[0]+CHRsize[0])return CHRptr[0][i-16-PRGsize[0]];
return 0;
}
}

View File

@ -122,7 +122,9 @@ void iNESGI(GI h) //bbit edited: removed static keyword
break;
case GI_CLOSE:
{
#ifndef GEKKO
FCEU_SaveGameSave(&iNESCart);
#endif
if(iNESCart.Close) iNESCart.Close();
#ifdef _USE_SHARED_MEMORY_
@ -696,7 +698,9 @@ int iNESLoad(const char *name, FCEUFILE *fp, int OverwriteVidMode)
GameInfo->mappernum = MapperNo;
MapperInit();
#ifndef GEKKO
FCEU_LoadGameSave(&iNESCart);
#endif
strcpy(LoadedRomFName,name); //bbit edited: line added
GameInterface=iNESGI;

View File

@ -545,7 +545,9 @@ static void UNIFGI(GI h)
if(UNIFchrrama) memset(UNIFchrrama,0,8192);
break;
case GI_CLOSE:
#ifndef GEKKO
FCEU_SaveGameSave(&UNIFCart);
#endif
if(UNIFCart.Close)
UNIFCart.Close();
FreeUNIF();
@ -591,8 +593,10 @@ int UNIFLoad(const char *name, FCEUFILE *fp)
if(!InitializeBoard())
goto aborto;
#ifndef GEKKO
FCEU_LoadGameSave(&UNIFCart);
#endif
GameInterface=UNIFGI;
return 1;