aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2004-02-10 04:15:36 +0000
committerEugene Sandulenko2004-02-10 04:15:36 +0000
commit98ffd24d6914f0fefa4f720453f540d356ec6647 (patch)
tree4e06c6a4fc34352c0ff01cc2fefc781b9610d4ec
parent260fd5a3964025752f565b539e9132f9d854d251 (diff)
downloadscummvm-rg350-98ffd24d6914f0fefa4f720453f540d356ec6647.tar.gz
scummvm-rg350-98ffd24d6914f0fefa4f720453f540d356ec6647.tar.bz2
scummvm-rg350-98ffd24d6914f0fefa4f720453f540d356ec6647.zip
Fix warnings which spotted bugs at the same time
svn-id: r12803
-rw-r--r--scumm/insane/insane_enemy.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/scumm/insane/insane_enemy.cpp b/scumm/insane/insane_enemy.cpp
index c29123caa0..7088f7a4ab 100644
--- a/scumm/insane/insane_enemy.cpp
+++ b/scumm/insane/insane_enemy.cpp
@@ -171,7 +171,7 @@ int32 Insane::enemy0handler(int32 actor1, int32 actor2, int32 probability) {
retval = 1;
}
_enHdlVar[EN_ROTT1][5] = 0;
- _enHdlVar[EN_ROTT1][6] = ABS(_vm->_rnd.getRandomNumber(probability - 1)) * 2;
+ _enHdlVar[EN_ROTT1][6] = _vm->_rnd.getRandomNumber(probability - 1) / 2;
}
if (_actor[actor1].weapon == -1)
@@ -335,7 +335,7 @@ int32 Insane::enemy1handler(int32 actor1, int32 actor2, int32 probability) {
retval = 1;
}
_enHdlVar[EN_ROTT1][5] = 0;
- _enHdlVar[EN_ROTT1][6] = ABS(_vm->_rnd.getRandomNumber(probability - 1)) * 2;
+ _enHdlVar[EN_ROTT1][6] = _vm->_rnd.getRandomNumber(probability - 1) / 2;
}
if (_actor[actor1].weapon == -1)
@@ -479,7 +479,7 @@ int32 Insane::enemy2handler(int32 actor1, int32 actor2, int32 probability) {
retval = 1;
}
_enHdlVar[EN_ROTT3][5] = 0;
- _enHdlVar[EN_ROTT3][6] = ABS(_vm->_rnd.getRandomNumber(probability - 1)) * 2;
+ _enHdlVar[EN_ROTT3][6] = _vm->_rnd.getRandomNumber(probability - 1) / 2;
}
if (_actor[actor1].weapon == -1)
@@ -629,7 +629,7 @@ int32 Insane::enemy3handler(int32 actor1, int32 actor2, int32 probability) {
retval = 1;
}
_enHdlVar[EN_VULTF1][5] = 0;
- _enHdlVar[EN_VULTF1][6] = ABS(_vm->_rnd.getRandomNumber(probability - 1)) / 2;
+ _enHdlVar[EN_VULTF1][6] = _vm->_rnd.getRandomNumber(probability - 1) / 2;
}
if (_actor[actor1].weapon == -1)
@@ -785,7 +785,7 @@ int32 Insane::enemy4handler(int32 actor1, int32 actor2, int32 probability) {
retval = 1;
}
_enHdlVar[EN_VULTM1][5] = 0;
- _enHdlVar[EN_VULTM1][6] = ABS(_vm->_rnd.getRandomNumber(probability - 1)) * 2;
+ _enHdlVar[EN_VULTM1][6] = _vm->_rnd.getRandomNumber(probability - 1) / 2;
}
if (_actor[actor1].weapon == -1)