fix movement audio service when no audio engine
This commit is contained in:
parent
ef724d3832
commit
496172680f
@ -879,6 +879,8 @@ Fix inventory null pointer check on virtualaudiomanager
|
|||||||
|
|
||||||
(10/21/2024)
|
(10/21/2024)
|
||||||
Fix inventory message for undefined id on client
|
Fix inventory message for undefined id on client
|
||||||
|
Fix movement audio service when audio engine disabled
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# TODO
|
# TODO
|
||||||
|
|||||||
@ -153,9 +153,11 @@ public class MovementAudioService {
|
|||||||
* @param type The interaction type
|
* @param type The interaction type
|
||||||
*/
|
*/
|
||||||
public void playAudio(int voxelType, InteractionType type){
|
public void playAudio(int voxelType, InteractionType type){
|
||||||
String audioPath = this.getAudioPath(voxelType, type);
|
if(Globals.RUN_AUDIO){
|
||||||
if(audioPath != null){
|
String audioPath = this.getAudioPath(voxelType, type);
|
||||||
Globals.virtualAudioSourceManager.createVirtualAudioSource(audioPath, VirtualAudioSourceType.CREATURE, false);
|
if(audioPath != null){
|
||||||
|
Globals.virtualAudioSourceManager.createVirtualAudioSource(audioPath, VirtualAudioSourceType.CREATURE, false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -166,9 +168,11 @@ public class MovementAudioService {
|
|||||||
* @param position The position of the audio
|
* @param position The position of the audio
|
||||||
*/
|
*/
|
||||||
public void playAudioPositional(int voxelType, InteractionType type, Vector3d position){
|
public void playAudioPositional(int voxelType, InteractionType type, Vector3d position){
|
||||||
String audioPath = this.getAudioPath(voxelType, type);
|
if(Globals.RUN_AUDIO){
|
||||||
if(audioPath != null){
|
String audioPath = this.getAudioPath(voxelType, type);
|
||||||
Globals.virtualAudioSourceManager.createVirtualAudioSource(audioPath, VirtualAudioSourceType.CREATURE, false, position);
|
if(audioPath != null){
|
||||||
|
Globals.virtualAudioSourceManager.createVirtualAudioSource(audioPath, VirtualAudioSourceType.CREATURE, false, position);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user