fix warnings when no soundlib is included in build
monmove.c: In function ‘postmov’:
monmove.c:1391:65: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
1391 | Soundeffect(se_door_unlock_and_open, 50);
| ^
monmove.c:1410:55: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
1410 | Soundeffect(se_door_open, 100);
| ^
monmove.c:1435:60: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
1435 | Soundeffect(se_door_crash_open, 50);
This commit is contained in:
+6
-3
@@ -1387,8 +1387,9 @@ postmov(
|
|||||||
if (mb_trapped(mtmp, canseeit))
|
if (mb_trapped(mtmp, canseeit))
|
||||||
return MMOVE_DIED;
|
return MMOVE_DIED;
|
||||||
} else {
|
} else {
|
||||||
if (!Deaf)
|
if (!Deaf) {
|
||||||
Soundeffect(se_door_unlock_and_open, 50);
|
Soundeffect(se_door_unlock_and_open, 50);
|
||||||
|
}
|
||||||
if (flags.verbose) {
|
if (flags.verbose) {
|
||||||
if (canseeit && canspotmon(mtmp)) {
|
if (canseeit && canspotmon(mtmp)) {
|
||||||
pline("%s unlocks and opens a door.",
|
pline("%s unlocks and opens a door.",
|
||||||
@@ -1406,8 +1407,9 @@ postmov(
|
|||||||
if (mb_trapped(mtmp, canseeit))
|
if (mb_trapped(mtmp, canseeit))
|
||||||
return MMOVE_DIED;
|
return MMOVE_DIED;
|
||||||
} else {
|
} else {
|
||||||
if (!Deaf)
|
if (!Deaf) {
|
||||||
Soundeffect(se_door_open, 100);
|
Soundeffect(se_door_open, 100);
|
||||||
|
}
|
||||||
if (flags.verbose) {
|
if (flags.verbose) {
|
||||||
if (canseeit && canspotmon(mtmp)) {
|
if (canseeit && canspotmon(mtmp)) {
|
||||||
pline("%s opens a door.", Monnam(mtmp));
|
pline("%s opens a door.", Monnam(mtmp));
|
||||||
@@ -1431,8 +1433,9 @@ postmov(
|
|||||||
if (mb_trapped(mtmp, canseeit))
|
if (mb_trapped(mtmp, canseeit))
|
||||||
return MMOVE_DIED;
|
return MMOVE_DIED;
|
||||||
} else {
|
} else {
|
||||||
if (!Deaf)
|
if (!Deaf) {
|
||||||
Soundeffect(se_door_crash_open, 50);
|
Soundeffect(se_door_crash_open, 50);
|
||||||
|
}
|
||||||
if (flags.verbose) {
|
if (flags.verbose) {
|
||||||
if (canseeit && canspotmon(mtmp)) {
|
if (canseeit && canspotmon(mtmp)) {
|
||||||
pline("%s smashes down a door.", Monnam(mtmp));
|
pline("%s smashes down a door.", Monnam(mtmp));
|
||||||
|
|||||||
Reference in New Issue
Block a user