1 /* FCE Ultra - NES/Famicom Emulator
3 * Copyright notice for this file:
4 * Copyright (C) 2003 Xodnizel
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 static uint8 OKValR,LastWR;
26 static uint32 OKX,OKY,OKB;
28 static uint8 FP_FASTAPASS(2) OK_Read(int w, uint8 ret)
37 static void FP_FASTAPASS(1) OK_Write(uint8 V)
50 else if(OKB) OKData|=3;
58 OKData |= (vx<<10) | (vy<<2);
65 if(!(V&0x2)) OKValR=0x4;
68 if(OKData&0x40000) OKValR=0;
75 static void FP_FASTAPASS(2) OK_Update(void *data, int arg)
78 OKX=((uint32*)data)[0];
79 OKY=((uint32*)data)[1];
80 OKB=((uint32*)data)[2];
83 static void FP_FASTAPASS(2) DrawOeka(uint8 *buf, int arg)
86 FCEU_DrawCursor(buf, OKX, OKY);
89 static INPUTCFC OekaKids={OK_Read,OK_Write,0,OK_Update,0,DrawOeka};
91 INPUTCFC *FCEU_InitOekaKids(void)