diff options
Diffstat (limited to 'src/mame/drivers/alg.c')
-rw-r--r-- | src/mame/drivers/alg.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mame/drivers/alg.c b/src/mame/drivers/alg.c index caabd183ad5..d54133bf06a 100644 --- a/src/mame/drivers/alg.c +++ b/src/mame/drivers/alg.c @@ -64,8 +64,8 @@ static int get_lightgun_pos(screen_device &screen, int player, int *x, int *y) if (xpos == -1 || ypos == -1) return FALSE; - *x = visarea.min_x + xpos * (visarea.max_x - visarea.min_x + 1) / 255; - *y = visarea.min_y + ypos * (visarea.max_y - visarea.min_y + 1) / 255; + *x = visarea.min_x + xpos * visarea.width() / 255; + *y = visarea.min_y + ypos * visarea.height() / 255; return TRUE; } |