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

« back to all changes in this revision

Viewing changes to src/mame/video/megazone.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:
38
38
 
39
39
PALETTE_INIT( megazone )
40
40
{
 
41
        const UINT8 *color_prom = machine.root_device().memregion("proms")->base();
41
42
        static const int resistances_rg[3] = { 1000, 470, 220 };
42
43
        static const int resistances_b [2] = { 470, 220 };
43
44
        double rweights[3], gweights[3], bweights[2];
96
97
        }
97
98
}
98
99
 
99
 
WRITE8_HANDLER( megazone_flipscreen_w )
 
100
WRITE8_MEMBER(megazone_state::megazone_flipscreen_w)
100
101
{
101
 
        megazone_state *state = space->machine().driver_data<megazone_state>();
102
 
        state->m_flipscreen = data & 1;
 
102
        m_flipscreen = data & 1;
103
103
}
104
104
 
105
105
VIDEO_START( megazone )
118
118
        int x, y;
119
119
 
120
120
        /* for every character in the Video RAM */
121
 
        for (offs = state->m_videoram_size - 1; offs >= 0; offs--)
 
121
        for (offs = state->m_videoram.bytes() - 1; offs >= 0; offs--)
122
122
        {
123
123
                int sx, sy, flipx, flipy;
124
124
 
166
166
        /* Draw the sprites. */
167
167
        {
168
168
                UINT8 *spriteram = state->m_spriteram;
169
 
                for (offs = state->m_spriteram_size - 4; offs >= 0; offs -= 4)
 
169
                for (offs = state->m_spriteram.bytes() - 4; offs >= 0; offs -= 4)
170
170
                {
171
171
                        int sx = spriteram[offs + 3];
172
172
                        int sy = 255 - ((spriteram[offs + 1] + 16) & 0xff);