Add an audio confirmation when an ability fails to activate/doesn't fulfil its requirements to activate

This commit is contained in:
Sollace 2021-02-09 20:44:05 +02:00
parent d48dc92528
commit a566dd2075

View file

@ -18,6 +18,7 @@ import com.minelittlepony.unicopia.network.Channel;
import com.minelittlepony.unicopia.util.NbtSerialisable;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.sound.SoundEvents;
import net.minecraft.util.Identifier;
import net.minecraft.util.Tickable;
@ -195,6 +196,7 @@ public class AbilityDispatcher implements Tickable, NbtSerialisable {
if (data != null) {
Channel.CLIENT_PLAYER_ABILITY.send(new MsgPlayerAbility<>(ability, data));
} else {
player.getEntity().playSound(SoundEvents.BLOCK_NOTE_BLOCK_DIDGERIDOO, 1, 1);
setCooldown(0);
}
}