unmuted and muted events
parent
b5e55136b9
commit
fb4a86c016
File diff suppressed because one or more lines are too long
|
@ -1,5 +1,5 @@
|
||||||
// COMPILE TIME DEFINITIONS (Generated via gulp)
|
// COMPILE TIME DEFINITIONS (Generated via gulp)
|
||||||
var __DATE__ = "Sun Nov 26 2017 22:50:32 GMT+0100 (CET)";
|
var __DATE__ = "Tue Nov 28 2017 08:21:32 GMT+0100 (CET)";
|
||||||
// END COMPILE TIME DEFINITIONS
|
// END COMPILE TIME DEFINITIONS
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -184,6 +184,8 @@ GameLib.Event.GAME_STARTED = 0x66;
|
||||||
GameLib.Event.GAME_PAUSED = 0x67;
|
GameLib.Event.GAME_PAUSED = 0x67;
|
||||||
GameLib.Event.GAME_RESUMED = 0x68;
|
GameLib.Event.GAME_RESUMED = 0x68;
|
||||||
GameLib.Event.CUSTOM_GAME_START = 0x69;
|
GameLib.Event.CUSTOM_GAME_START = 0x69;
|
||||||
|
GameLib.Event.AUDIO_MUTED = 0x6a;
|
||||||
|
GameLib.Event.AUDIO_UNMUTED = 0x6b;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -302,6 +304,8 @@ GameLib.Event.GetEventName = function(number) {
|
||||||
case 0x67 : return 'game_paused';
|
case 0x67 : return 'game_paused';
|
||||||
case 0x68 : return 'game_resumed';
|
case 0x68 : return 'game_resumed';
|
||||||
case 0x69 : return 'custom_game_start';
|
case 0x69 : return 'custom_game_start';
|
||||||
|
case 0x6a : return 'audio_muted';
|
||||||
|
case 0x6b : return 'audio_unmuted';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25826,14 +25830,20 @@ GameLib.System.Audio.prototype.muteAudio = function() {
|
||||||
return result;
|
return result;
|
||||||
},
|
},
|
||||||
[]
|
[]
|
||||||
)
|
);
|
||||||
|
|
||||||
|
GameLib.Event.Emit(GameLib.Event.AUDIO_MUTED, {audioSystem:this});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
this.audioVolumes.map(
|
this.audioVolumes.map(
|
||||||
function(audioVolume) {
|
function(audioVolume) {
|
||||||
audioVolume.audio.volume = audioVolume.volume;
|
audioVolume.audio.volume = audioVolume.volume;
|
||||||
audioVolume.audio.updateInstance('volume');
|
audioVolume.audio.updateInstance('volume');
|
||||||
}
|
}
|
||||||
)
|
);
|
||||||
|
|
||||||
|
GameLib.Event.Emit(GameLib.Event.AUDIO_UNMUTED, {audioSystem:this});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -120,6 +120,8 @@ GameLib.Event.GAME_STARTED = 0x66;
|
||||||
GameLib.Event.GAME_PAUSED = 0x67;
|
GameLib.Event.GAME_PAUSED = 0x67;
|
||||||
GameLib.Event.GAME_RESUMED = 0x68;
|
GameLib.Event.GAME_RESUMED = 0x68;
|
||||||
GameLib.Event.CUSTOM_GAME_START = 0x69;
|
GameLib.Event.CUSTOM_GAME_START = 0x69;
|
||||||
|
GameLib.Event.AUDIO_MUTED = 0x6a;
|
||||||
|
GameLib.Event.AUDIO_UNMUTED = 0x6b;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -238,6 +240,8 @@ GameLib.Event.GetEventName = function(number) {
|
||||||
case 0x67 : return 'game_paused';
|
case 0x67 : return 'game_paused';
|
||||||
case 0x68 : return 'game_resumed';
|
case 0x68 : return 'game_resumed';
|
||||||
case 0x69 : return 'custom_game_start';
|
case 0x69 : return 'custom_game_start';
|
||||||
|
case 0x6a : return 'audio_muted';
|
||||||
|
case 0x6b : return 'audio_unmuted';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -243,14 +243,20 @@ GameLib.System.Audio.prototype.muteAudio = function() {
|
||||||
return result;
|
return result;
|
||||||
},
|
},
|
||||||
[]
|
[]
|
||||||
)
|
);
|
||||||
|
|
||||||
|
GameLib.Event.Emit(GameLib.Event.AUDIO_MUTED, {audioSystem:this});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
this.audioVolumes.map(
|
this.audioVolumes.map(
|
||||||
function(audioVolume) {
|
function(audioVolume) {
|
||||||
audioVolume.audio.volume = audioVolume.volume;
|
audioVolume.audio.volume = audioVolume.volume;
|
||||||
audioVolume.audio.updateInstance('volume');
|
audioVolume.audio.updateInstance('volume');
|
||||||
}
|
}
|
||||||
)
|
);
|
||||||
|
|
||||||
|
GameLib.Event.Emit(GameLib.Event.AUDIO_UNMUTED, {audioSystem:this});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue