[Change] Pause engine sounds when pausing.
This commit is contained in:
parent
7cb8dfd1f8
commit
fbc2cddac5
@ -9,7 +9,7 @@
|
|||||||
* @todo Should probably be eliminated by making everything use the dt system.
|
* @todo Should probably be eliminated by making everything use the dt system.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "pilot.h"
|
#include "player.h"
|
||||||
#include "pause.h"
|
#include "pause.h"
|
||||||
|
|
||||||
int paused = 0; /**< Are we paused. */
|
int paused = 0; /**< Are we paused. */
|
||||||
@ -22,12 +22,16 @@ extern unsigned int time; /**< From lephisto.c. */
|
|||||||
void pause_game(void) {
|
void pause_game(void) {
|
||||||
if(paused) return; /* Well well.. We are paused already. */
|
if(paused) return; /* Well well.. We are paused already. */
|
||||||
|
|
||||||
|
player_soundPause();
|
||||||
|
|
||||||
paused = 1; /* We should unpause it. */
|
paused = 1; /* We should unpause it. */
|
||||||
}
|
}
|
||||||
|
|
||||||
void unpause_game(void) {
|
void unpause_game(void) {
|
||||||
if(!paused) return; /* We are unpaused already. */
|
if(!paused) return; /* We are unpaused already. */
|
||||||
|
|
||||||
|
player_soundResume();
|
||||||
|
|
||||||
paused = 0;
|
paused = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user