~ubuntu-branches/debian/sid/mame/sid

« back to all changes in this revision

Viewing changes to src/mame/video/tecmo.c

  • Committer: Package Import Robot
  • Author(s): Jordi Mallach, Emmanuel Kasper, Jordi Mallach
  • Date: 2012-06-05 20:02:23 UTC
  • mfrom: (0.3.1) (0.1.4)
  • Revision ID: package-import@ubuntu.com-20120605200223-gnlpogjrg6oqe9md
Tags: 0.146-1
[ Emmanuel Kasper ]
* New upstream release
* Drop patch to fix man pages section and patches to link with flac 
  and jpeg system lib: all this has been pushed upstream by Cesare Falco
* Add DM-Upload-Allowed: yes field.

[ Jordi Mallach ]
* Create a "gnu" TARGETOS stanza that defines NO_AFFINITY_NP.
* Stop setting TARGETOS to "unix" in d/rules. It should be autodetected,
  and set to the appropriate value.
* mame_manpage_section.patch: Change mame's manpage section to 6 (games),
  in the TH declaration.

Show diffs side-by-side

added added

removed removed

Lines of Context:
115
115
 
116
116
***************************************************************************/
117
117
 
118
 
WRITE8_HANDLER( tecmo_txvideoram_w )
119
 
{
120
 
        tecmo_state *state = space->machine().driver_data<tecmo_state>();
121
 
        state->m_txvideoram[offset] = data;
122
 
        state->m_tx_tilemap->mark_tile_dirty(offset & 0x3ff);
123
 
}
124
 
 
125
 
WRITE8_HANDLER( tecmo_fgvideoram_w )
126
 
{
127
 
        tecmo_state *state = space->machine().driver_data<tecmo_state>();
128
 
        state->m_fgvideoram[offset] = data;
129
 
        state->m_fg_tilemap->mark_tile_dirty(offset & 0x1ff);
130
 
}
131
 
 
132
 
WRITE8_HANDLER( tecmo_bgvideoram_w )
133
 
{
134
 
        tecmo_state *state = space->machine().driver_data<tecmo_state>();
135
 
        state->m_bgvideoram[offset] = data;
136
 
        state->m_bg_tilemap->mark_tile_dirty(offset & 0x1ff);
137
 
}
138
 
 
139
 
WRITE8_HANDLER( tecmo_fgscroll_w )
140
 
{
141
 
        tecmo_state *state = space->machine().driver_data<tecmo_state>();
142
 
 
143
 
        state->m_fgscroll[offset] = data;
144
 
 
145
 
        state->m_fg_tilemap->set_scrollx(0, state->m_fgscroll[0] + 256 * state->m_fgscroll[1]);
146
 
        state->m_fg_tilemap->set_scrolly(0, state->m_fgscroll[2]);
147
 
}
148
 
 
149
 
WRITE8_HANDLER( tecmo_bgscroll_w )
150
 
{
151
 
        tecmo_state *state = space->machine().driver_data<tecmo_state>();
152
 
 
153
 
        state->m_bgscroll[offset] = data;
154
 
 
155
 
        state->m_bg_tilemap->set_scrollx(0, state->m_bgscroll[0] + 256 * state->m_bgscroll[1]);
156
 
        state->m_bg_tilemap->set_scrolly(0, state->m_bgscroll[2]);
157
 
}
158
 
 
159
 
WRITE8_HANDLER( tecmo_flipscreen_w )
160
 
{
161
 
        flip_screen_set(space->machine(), data & 1);
 
118
WRITE8_MEMBER(tecmo_state::tecmo_txvideoram_w)
 
119
{
 
120
        m_txvideoram[offset] = data;
 
121
        m_tx_tilemap->mark_tile_dirty(offset & 0x3ff);
 
122
}
 
123
 
 
124
WRITE8_MEMBER(tecmo_state::tecmo_fgvideoram_w)
 
125
{
 
126
        m_fgvideoram[offset] = data;
 
127
        m_fg_tilemap->mark_tile_dirty(offset & 0x1ff);
 
128
}
 
129
 
 
130
WRITE8_MEMBER(tecmo_state::tecmo_bgvideoram_w)
 
131
{
 
132
        m_bgvideoram[offset] = data;
 
133
        m_bg_tilemap->mark_tile_dirty(offset & 0x1ff);
 
134
}
 
135
 
 
136
WRITE8_MEMBER(tecmo_state::tecmo_fgscroll_w)
 
137
{
 
138
 
 
139
        m_fgscroll[offset] = data;
 
140
 
 
141
        m_fg_tilemap->set_scrollx(0, m_fgscroll[0] + 256 * m_fgscroll[1]);
 
142
        m_fg_tilemap->set_scrolly(0, m_fgscroll[2]);
 
143
}
 
144
 
 
145
WRITE8_MEMBER(tecmo_state::tecmo_bgscroll_w)
 
146
{
 
147
 
 
148
        m_bgscroll[offset] = data;
 
149
 
 
150
        m_bg_tilemap->set_scrollx(0, m_bgscroll[0] + 256 * m_bgscroll[1]);
 
151
        m_bg_tilemap->set_scrolly(0, m_bgscroll[2]);
 
152
}
 
153
 
 
154
WRITE8_MEMBER(tecmo_state::tecmo_flipscreen_w)
 
155
{
 
156
        flip_screen_set(data & 1);
162
157
}
163
158
 
164
159
 
186
181
                {42,43,46,47,58,59,62,63}
187
182
        };
188
183
 
189
 
        for (offs = state->m_spriteram_size-8;offs >= 0;offs -= 8)
 
184
        for (offs = state->m_spriteram.bytes()-8;offs >= 0;offs -= 8)
190
185
        {
191
186
                int flags = spriteram[offs+3];
192
187
                int priority = flags>>6;
210
205
                        flipx = bank & 1;
211
206
                        flipy = bank & 2;
212
207
 
213
 
                        if (flip_screen_get(machine))
 
208
                        if (state->flip_screen())
214
209
                        {
215
210
                                xpos = 256 - (8 * size) - xpos;
216
211
                                ypos = 256 - (8 * size) - ypos;