Fixed #8967
This commit is contained in:
@@ -23,6 +23,10 @@ public class MinerAI extends AIController{
|
||||
unit.mineTile(null);
|
||||
}
|
||||
|
||||
if(ore != null && !unit.validMine(ore)){
|
||||
ore = null;
|
||||
}
|
||||
|
||||
if(mining){
|
||||
if(timer.get(timerTarget2, 60 * 4) || targetItem == null){
|
||||
targetItem = unit.type.mineItems.min(i -> indexer.hasOre(i) && unit.canMine(i), i -> core.items.get(i));
|
||||
|
||||
@@ -165,14 +165,14 @@ public class NetClient implements ApplicationListener{
|
||||
public static void sound(Sound sound, float volume, float pitch, float pan){
|
||||
if(sound == null || headless) return;
|
||||
|
||||
sound.play(Mathf.clamp(volume, 0, 8f) * Core.settings.getInt("sfxvol") / 100f, pitch, pan, false, false);
|
||||
sound.play(Mathf.clamp(volume, 0, 8f) * Core.settings.getInt("sfxvol") / 100f, Mathf.clamp(pitch, 0f, 20f), pan, false, false);
|
||||
}
|
||||
|
||||
@Remote(variants = Variant.both, unreliable = true, called = Loc.server)
|
||||
public static void soundAt(Sound sound, float x, float y, float volume, float pitch){
|
||||
if(sound == null || headless) return;
|
||||
|
||||
sound.at(x, y, pitch, Mathf.clamp(volume, 0, 4f));
|
||||
sound.at(x, y, Mathf.clamp(pitch, 0f, 20f), Mathf.clamp(volume, 0, 4f));
|
||||
}
|
||||
|
||||
@Remote(variants = Variant.both, unreliable = true)
|
||||
|
||||
Reference in New Issue
Block a user