mirror of
https://github.com/holub/mame
synced 2025-10-07 17:27:06 +03:00
added tilemap_get_scrollx / tilemap_get_scrolly
This commit is contained in:
parent
be4bd611f0
commit
e5b2e1f8ee
@ -655,6 +655,34 @@ void tilemap_set_scrolly(tilemap *tmap, int which, int value)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*-------------------------------------------------
|
||||||
|
tilemap_get_scrollx - return the scroll value
|
||||||
|
for a row unit
|
||||||
|
-------------------------------------------------*/
|
||||||
|
|
||||||
|
int tilemap_get_scrollx(tilemap *tmap, int which)
|
||||||
|
{
|
||||||
|
if (which < tmap->scrollrows)
|
||||||
|
return tmap->rowscroll[which];
|
||||||
|
else
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*-------------------------------------------------
|
||||||
|
tilemap_get_scrolly - return the scroll value
|
||||||
|
for a column unit
|
||||||
|
-------------------------------------------------*/
|
||||||
|
|
||||||
|
int tilemap_get_scrolly(tilemap *tmap, int which)
|
||||||
|
{
|
||||||
|
if (which < tmap->scrollcols)
|
||||||
|
return tmap->colscroll[which];
|
||||||
|
else
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
INTERNAL MAP ACCESS
|
INTERNAL MAP ACCESS
|
||||||
|
@ -518,6 +518,10 @@ int tilemap_get_scrolldy(tilemap *tmap);
|
|||||||
void tilemap_set_scrollx(tilemap *tmap, int row, int value);
|
void tilemap_set_scrollx(tilemap *tmap, int row, int value);
|
||||||
void tilemap_set_scrolly(tilemap *tmap, int col, int value);
|
void tilemap_set_scrolly(tilemap *tmap, int col, int value);
|
||||||
|
|
||||||
|
/* return the scroll value for a row/column unit */
|
||||||
|
int tilemap_get_scrollx(tilemap *tmap, int row);
|
||||||
|
int tilemap_get_scrolly(tilemap *tmap, int col);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* ----- internal map access ----- */
|
/* ----- internal map access ----- */
|
||||||
|
Loading…
Reference in New Issue
Block a user