diff options
author | D G Turner | 2019-09-04 19:47:15 +0100 |
---|---|---|
committer | D G Turner | 2019-09-04 19:47:15 +0100 |
commit | cb88db65cdff4302dd5952a0ed2a048ba5ef489a (patch) | |
tree | 3d6f194176cdeac53cd5f49d9c8d523d42f39fa1 | |
parent | 9d709866a5578de2c9e5bf2eebf966f66a849650 (diff) | |
download | scummvm-rg350-cb88db65cdff4302dd5952a0ed2a048ba5ef489a.tar.gz scummvm-rg350-cb88db65cdff4302dd5952a0ed2a048ba5ef489a.tar.bz2 scummvm-rg350-cb88db65cdff4302dd5952a0ed2a048ba5ef489a.zip |
HDB: Fix Some GCC Compiler Warnings
-rw-r--r-- | engines/hdb/ai-funcs.cpp | 4 | ||||
-rw-r--r-- | engines/hdb/ai-init.cpp | 3 | ||||
-rw-r--r-- | engines/hdb/ai-lists.cpp | 3 |
3 files changed, 4 insertions, 6 deletions
diff --git a/engines/hdb/ai-funcs.cpp b/engines/hdb/ai-funcs.cpp index 255e0581c5..e13fcc6879 100644 --- a/engines/hdb/ai-funcs.cpp +++ b/engines/hdb/ai-funcs.cpp @@ -1100,7 +1100,7 @@ void AI::animateEntity(AIEntity *e) { if ((e->tileX + xOff == _waypoints[_numWaypoints - 1].x && e->tileY + yOff == _waypoints[_numWaypoints - 1].y) && e->level == _waypoints[_numWaypoints - 1].level) { - memset(&_waypoints[0], 0, sizeof(_waypoints)); + clearWaypoints(); _numWaypoints = 1; _waypoints[0].x = e->tileX + xOff; _waypoints[0].y = e->tileY + yOff; @@ -1795,7 +1795,7 @@ void AI::drawEnts(int x, int y, int w, int h) { e->onScreen = 0; debugN(5, "not on screen"); } - debug(5, ""); // newline + debug(5, "%s", ""); // newline } if (stunTimer < g_hdb->getTimeSlice()) { diff --git a/engines/hdb/ai-init.cpp b/engines/hdb/ai-init.cpp index 32229d9908..0a03d579c7 100644 --- a/engines/hdb/ai-init.cpp +++ b/engines/hdb/ai-init.cpp @@ -1190,8 +1190,7 @@ void AI::restartSystem() { _numBridges = 0; // Clear waypoints - memset(&_waypoints[0], 0, sizeof(_waypoints)); - _numWaypoints = 0; + clearWaypoints(); // Clean up Player Graphics Storage memset(_horrible1Gfx, 0, sizeof(_horrible1Gfx)); diff --git a/engines/hdb/ai-lists.cpp b/engines/hdb/ai-lists.cpp index fd6a0fd9c9..27dbc7aff7 100644 --- a/engines/hdb/ai-lists.cpp +++ b/engines/hdb/ai-lists.cpp @@ -730,8 +730,7 @@ bool AI::checkTeleportList(AIEntity *e, int x, int y) { e->draw = e->standdownGfx[0]; if (e == _player) { - memset(&_waypoints[0], 0, sizeof(_waypoints)); - _numWaypoints = 0; + clearWaypoints(); } switch (e->dir) { |