Beispiel #1
0
static void UNIFGI(GI h) {
    switch (h) {
    case GI_RESETSAVE:
        FCEU_ClearGameSave(&UNIFCart);
        break;

    case GI_RESETM2:
        if (UNIFCart.Reset)
            UNIFCart.Reset();
        break;
    case GI_POWER:
        if (UNIFCart.Power)
            UNIFCart.Power();
        if (UNIFchrrama) memset(UNIFchrrama, 0, 8192);
        break;
    case GI_SAVE:
        FCEU_SaveGameSave(&UNIFCart);
        break;
    case GI_CLOSE:
        FCEU_SaveGameSave(&UNIFCart);
        if (UNIFCart.Close)
            UNIFCart.Close();
        FreeUNIF();
        break;
    }
}
Beispiel #2
0
static void UNIFGI(int h, void *param)
{
 switch(h)
 {
  case GI_RESETM2:
                if(UNIFCart.Reset)
                 UNIFCart.Reset();
		break;
  case GI_POWER:
                if(UNIFCart.Power)
                 UNIFCart.Power();
		if(UNIFchrrama) memset(UNIFchrrama,0,8192);
		break;
  case GI_CLOSE:
                FCEU_SaveGameSave(&UNIFCart);
		if(UNIFCart.Close)
		 UNIFCart.Close();
                FreeUNIF();
		ResetExState(0,0);
                break;
  case GI_INFOSTRING:
		{
		 char board[24];
		 strncpy(board, sboardname, 20);
		 board[20] = 0;
		 sprintf(param, "UNIF, %s, %s%s", board, PAL?"PAL":"NTSC", UNIFCart.battery?", BB":"");
		}
		break;
 }
}