MCPcopy Create free account
hub / github.com/TASEmulators/fceux / WriteFileData

Function WriteFileData

src/drivers/win/memview.cpp:348–354  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

346}
347
348static int WriteFileData(uint32 addr,int data){
349 if (addr < 16) MessageBox(hMemView, "You can't edit ROM header here, however you can use NES Header Editor to edit the header if it's an iNES format file.", "Sorry", MB_OK | MB_ICONERROR);
350 if((addr >= 16) && (addr < PRGsize[0]+16)) *(uint8 *)(GetNesPRGPointer(addr-16)) = data;
351 if((addr >= PRGsize[0]+16) && (addr < CHRsize[0]+PRGsize[0]+16)) *(uint8 *)(GetNesCHRPointer(addr-16-PRGsize[0])) = data;
352
353 return 0;
354}
355
356static int GetRomFileSize(){ //todo: fix or remove this?
357 return 0;

Callers 2

ApplyPatchFunction · 0.85
UndoLastPatchFunction · 0.85

Calls 2

GetNesPRGPointerFunction · 0.85
GetNesCHRPointerFunction · 0.85

Tested by

no test coverage detected