… | |
… | |
1609 | if (distance <= MAX_SOUND_DISTANCE) |
1609 | if (distance <= MAX_SOUND_DISTANCE) |
1610 | ns->send_msg (NDI_GREY | NDI_DEF, SAY_CHANNEL, msg); |
1610 | ns->send_msg (NDI_GREY | NDI_DEF, SAY_CHANNEL, msg); |
1611 | } |
1611 | } |
1612 | } |
1612 | } |
1613 | |
1613 | |
|
|
1614 | dynbuf mapwalk_buf (sizeof (maprect) * 25, sizeof (maprect) * 25); |
|
|
1615 | |
1614 | static void |
1616 | static void |
1615 | split_to_tiles (dynbuf &buf, maptile *m, int x0, int y0, int x1, int y1, int dx, int dy) |
1617 | split_to_tiles (dynbuf &buf, maptile *m, int x0, int y0, int x1, int y1, int dx, int dy) |
1616 | { |
1618 | { |
1617 | // clip to map to the left |
1619 | // clip to map to the left |
1618 | if (x0 < 0) |
1620 | if (x0 < 0) |
… | |
… | |
1673 | r->dx = dx; |
1675 | r->dx = dx; |
1674 | r->dy = dy; |
1676 | r->dy = dy; |
1675 | } |
1677 | } |
1676 | |
1678 | |
1677 | maprect * |
1679 | maprect * |
1678 | maptile::split_to_tiles (int x0, int y0, int x1, int y1) |
1680 | maptile::split_to_tiles (dynbuf &buf, int x0, int y0, int x1, int y1) |
1679 | { |
1681 | { |
1680 | static dynbuf buf (sizeof (maprect) * 8, sizeof (maprect) * 8); |
|
|
1681 | buf.clear (); |
1682 | buf.clear (); |
1682 | |
1683 | |
1683 | ::split_to_tiles (buf, this, x0, y0, x1, y1, 0, 0); |
1684 | ::split_to_tiles (buf, this, x0, y0, x1, y1, 0, 0); |
1684 | |
1685 | |
1685 | // add end marker |
1686 | // add end marker |