mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-12-28 12:07:38 +01:00
Remove skeleton sounds with /npc skin
This commit is contained in:
parent
fc835aa9dc
commit
1093965f7a
@ -57,6 +57,10 @@ public class PlayerSkin extends Trait {
|
|||||||
|
|
||||||
private Entity prepareEntity(String name, EntityType type) {
|
private Entity prepareEntity(String name, EntityType type) {
|
||||||
NPC npcEntity = npc.getOwningRegistry().createNPC(type, name);
|
NPC npcEntity = npc.getOwningRegistry().createNPC(type, name);
|
||||||
|
npcEntity.data().set(NPC.AMBIENT_SOUND_METADATA, "");
|
||||||
|
npcEntity.data().set(NPC.DEFAULT_PROTECTED_METADATA, true);
|
||||||
|
npcEntity.data().set(NPC.DEATH_SOUND_METADATA, "");
|
||||||
|
npcEntity.data().set(NPC.HURT_SOUND_METADATA, "");
|
||||||
npcEntity.data().set(NPC.SHOULD_SAVE_METADATA, false);
|
npcEntity.data().set(NPC.SHOULD_SAVE_METADATA, false);
|
||||||
npcEntity.spawn(npc.getStoredLocation());
|
npcEntity.spawn(npc.getStoredLocation());
|
||||||
if (name.isEmpty() || !(npcEntity.getEntity() instanceof Slime)) {
|
if (name.isEmpty() || !(npcEntity.getEntity() instanceof Slime)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user