~ubuntu-branches/ubuntu/precise/mame/precise-proposed

« back to all changes in this revision

Viewing changes to src/mame/machine/steppers.c

  • Committer: Package Import Robot
  • Author(s): Cesare Falco
  • Date: 2011-11-30 18:50:10 UTC
  • mfrom: (1.1.4)
  • Revision ID: package-import@ubuntu.com-20111130185010-02hcxybht1mn082w
Tags: 0.144-0ubuntu1
* New upstream release (LP: #913550)
* mame.install:
  - Added artwork/ images to be used with -effect switch
  - Be more selective with hash/ contents
* contrib/mame.ini: added /usr/share/games/mame/artwork/ to artpath

Show diffs side-by-side

added added

removed removed

Lines of Context:
253
253
                if ( which ==1 )logerror("which %d Steps %d Phase %d Pattern Old %02X New %02X\n",which,steps,(step[which].phase),step[which].old_pattern,step[which].pattern);
254
254
                #endif
255
255
 
256
 
                if (step[which].reverse)
 
256
                int max = step[which].max_steps;
 
257
                pos = 0;
 
258
 
 
259
                if (max!=0)
257
260
                {
258
 
                        pos = (step[which].step_pos - steps + step[which].max_steps) % step[which].max_steps;
 
261
                        if (step[which].reverse)
 
262
                        {
 
263
                                pos = (step[which].step_pos - steps + max) % max;
 
264
                        }
 
265
                        else
 
266
                        {
 
267
                                pos = (step[which].step_pos + steps + max) % max;
 
268
                        }
259
269
                }
260
270
                else
261
271
                {
262
 
                        pos = (step[which].step_pos + steps + step[which].max_steps) % step[which].max_steps;
 
272
                        logerror("step[which].max_steps == 0\n");
263
273
                }
264
274
 
265
275
                if (pos != step[which].step_pos)