trunk/src/mame/drivers/popobear.c
| r21842 | r21843 | |
| 173 | 173 | { |
| 174 | 174 | int base = tilemap_base[0]; |
| 175 | 175 | int tileno = m_vram[base/2 + tile_index]; |
| 176 | | SET_TILE_INFO_MEMBER(0, tileno, 0, 0); |
| 176 | int flipyx = (tileno>>14); |
| 177 | SET_TILE_INFO_MEMBER(0, tileno&0x3fff, 0, TILE_FLIPYX(flipyx)); |
| 177 | 178 | } |
| 178 | 179 | |
| 179 | 180 | TILE_GET_INFO_MEMBER(popobear_state::get_popobear_bg1_tile_info) |
| 180 | 181 | { |
| 181 | 182 | int base = tilemap_base[1]; |
| 182 | 183 | int tileno = m_vram[base/2 + tile_index]; |
| 183 | | SET_TILE_INFO_MEMBER(0, tileno, 0, 0); |
| 184 | int flipyx = (tileno>>14); |
| 185 | SET_TILE_INFO_MEMBER(0, tileno&0x3fff, 0, TILE_FLIPYX(flipyx)); |
| 184 | 186 | } |
| 185 | 187 | |
| 186 | 188 | TILE_GET_INFO_MEMBER(popobear_state::get_popobear_bg2_tile_info) |
| 187 | 189 | { |
| 188 | 190 | int base = tilemap_base[2]; |
| 189 | 191 | int tileno = m_vram[base/2 + tile_index]; |
| 190 | | SET_TILE_INFO_MEMBER(0, tileno, 0, 0); |
| 192 | int flipyx = (tileno>>14); |
| 193 | SET_TILE_INFO_MEMBER(0, tileno&0x3fff, 0, TILE_FLIPYX(flipyx)); |
| 191 | 194 | } |
| 192 | 195 | |
| 193 | 196 | TILE_GET_INFO_MEMBER(popobear_state::get_popobear_bg3_tile_info) |
| 194 | 197 | { |
| 195 | 198 | int base = tilemap_base[3]; |
| 196 | 199 | int tileno = m_vram[base/2 + tile_index]; |
| 197 | | SET_TILE_INFO_MEMBER(0, tileno, 0, 0); |
| 200 | int flipyx = (tileno>>14); |
| 201 | SET_TILE_INFO_MEMBER(0, tileno&0x3fff, 0, TILE_FLIPYX(flipyx)); |
| 198 | 202 | } |
| 199 | 203 | |
| 200 | 204 | |
| r21842 | r21843 | |
| 280 | 284 | if(param == 0) |
| 281 | 285 | continue; |
| 282 | 286 | |
| 287 | |
| 283 | 288 | spr_num <<= 3; |
| 284 | 289 | |
| 285 | 290 | for(int yi=0;yi<height;yi++) |
| r21842 | r21843 | |
| 294 | 299 | if(cliprect.contains(x_draw, y_draw)) |
| 295 | 300 | { |
| 296 | 301 | // this is a bit strange, pix data is basically 8-bit |
| 297 | | // but we have to treat 0x00, 0x20, 0x40, 0x60, 0x80, 0xa0, 0xc0 and 0xe0 as transpens? |
| 298 | | // see scores when you colect an item |
| 302 | // but we have to treat 0x00, 0x40, 0x80, 0xc0 */ |
| 303 | // see scores when you colect an item, must be at least steps of 0x40 or one of the female panda gfx between levels breaks.. might depend on lower bits? |
| 299 | 304 | // granularity also means colour bank is applied *0x40 |
| 300 | 305 | // and we have 2 more possible colour bank bits |
| 301 | | if (pix&0x1f) |
| 306 | // colours on game over screen are still wrong |
| 307 | if (pix&0x3f) |
| 302 | 308 | { |
| 303 | 309 | bitmap.pix16(y_draw, x_draw) = machine().pens[((pix+(color_bank*0x40))&0xff)+0x100]; |
| 304 | 310 | } |