Merged fixes from branch-0-5-0:

* Max's "adjustment" was incomplete, fixed.
* Initialize shake_pos to 0 (fixes Sky, which never sets the shake_pos).
* Changed sematics of X button to allow boxing in Indy (I hope...)

svn-id: r9307
This commit is contained in:
Marcus Comstedt 2003-07-30 21:44:43 +00:00
parent f64a8793f3
commit 12f9de02b4
2 changed files with 4 additions and 3 deletions

View File

@ -44,7 +44,7 @@ OSystem *OSystem_Dreamcast::create() {
OSystem_Dreamcast::OSystem_Dreamcast()
: screen(NULL), mouse(NULL), overlay(NULL), _ms_buf(NULL),
_sound_proc(NULL), _timer_active(false)
_sound_proc(NULL), _timer_active(false), _current_shake_pos(0)
{
memset(screen_tx, 0, sizeof(screen_tx));
memset(mouse_tx, 0, sizeof(screen_tx));
@ -85,7 +85,7 @@ void OSystem_Dreamcast::play_cdrom(int track, int num_loops, int start_frame, in
else if(num_loops<0) num_loops=15; // infinity
if(!find_track(track, first_sec, last_sec))
return;
if(end_frame)
if(duration)
last_sec = first_sec + start_frame + duration;
first_sec += start_frame;
play_cdda_sectors(first_sec, last_sec, num_loops);

View File

@ -29,6 +29,7 @@
int handleInput(struct mapledev *pad, int &mouse_x, int &mouse_y,
byte &shiftFlags)
{
static const char numpadmap[] = "0000039601740285";
int lmb=0, rmb=0, newkey=0;
static int lastkey = 0;
static byte lastlmb = 0, lastrmb = 0;
@ -44,7 +45,7 @@ int handleInput(struct mapledev *pad, int &mouse_x, int &mouse_y,
if(!(buttons & 8)) newkey = 319;
else if(!(buttons & 512)) newkey = ' ';
else if(!(buttons & 1024)) newkey = '0';
else if(!(buttons & 1024)) newkey = numpadmap[(buttons>>4)&15];
if(!(buttons & 128)) mouse_x++;
if(!(buttons & 64)) mouse_x--;