Final Burn Neo > FBN Development
Some PVC Bankswitch code
bms888:
--- Code: ---
/***************************** Neo PVC protection *********************/
static unsigned short CartRAM[0x1000];
// for save states
unsigned char *NeoCartRAM = (unsigned char *)CartRAM;
unsigned char pvc_r8(unsigned int sekAddress)
{
return *(((unsigned char *)CartRAM)+((sekAddress^1)-0x2fe000));
}
void pvc_w8(unsigned int sekAddress,unsigned char byteValue)
{
*(((unsigned char *)CartRAM)+((sekAddress^1)-0x2fe000))=byteValue;
}
unsigned char __fastcall pvcReadByteBankSwitch(unsigned int sekAddress)
{
return pvc_r8(sekAddress);
}
unsigned short __fastcall pvcReadWordBankSwitch(unsigned int sekAddress)
{
return CartRAM[(sekAddress-0x2fe000)/2];
}
--- End code ---
--- Code: ---
// Special Bankswitch
void pvc_CalcBank2() // on writes to f0-f3
{
unsigned int offset;
// Make this universal for kof2003b + kof2003p
if ((!strcmp(BurnDrvText(0), "kof2k4eh")) || (!strcmp(BurnDrvText(0), "kof2k4ex"))) {
offset=(pvc_r8(0x2ffff2)
bms888:
these code can working on mslug5,mslug5b,svcboot,svcsplus,kof2003b,kof2k3up,kof2k4ex....^_^
bms888:
maybe I will open the pvc_port code in someday,bye.
bms888:
oh,everyone! this code maybe help you:
--- Code: ---
// Code by iq_132 -- http://neosource.1emu.net/
static void interleave_pdata()
{
int i, j=0;
UINT8 *src = Neo68KROM01;
UINT8 *dst = (UINT8 *)malloc(0x800000);
for (i=0;i> 12), 4, 5, 6, 7, 1, 0, 3, 2 ) > 12), 5, 4, 7, 6, 1, 0, 3, 2 )
bms888:
kof2003b you can try this code:
--- Code: ---
static void kof2003bDecrypt()
{
int sec[]={ 0x07, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06 };
int i, rom_size = 0x800000;
UINT8 *src = Neo68KROM01;
UINT8 *dst = (UINT8 *)malloc( rom_size );
memcpy( dst, src, rom_size );
for( i=0; i
Navigation
[0] Message Index
[#] Next page
Go to full version