mirror of
https://github.com/KAMKEEL/CustomNPC-Gecko-Addon.git
synced 2026-11-28 02:05:41 +00:00
Disabled JavaModernSyntaxSupport
This commit is contained in:
1 parent
d9ee1bd10a
commit
574858716d
4 files changed
+16
-17
No files matched your search
@@ -3,6 +3,7 @@ package com.goodbird.npcgecko.mixin.impl;
|
||||
import com.goodbird.npcgecko.entity.EntityCustomModel;
|
||||
import com.goodbird.npcgecko.mixin.IDataDisplay;
|
||||
import com.goodbird.npcgecko.utils.NpcTextureUtils;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import kamkeel.addon.GeckoAddon;
|
||||
@@ -27,7 +28,9 @@ public class MixinGeckoAddon {
|
||||
if(!supportEnabled)
|
||||
return;
|
||||
|
||||
if (entity instanceof EntityCustomModel modelEntity && copied instanceof EntityNPCInterface npc) {
|
||||
if (entity instanceof EntityCustomModel && copied instanceof EntityNPCInterface) {
|
||||
EntityCustomModel modelEntity = (EntityCustomModel) entity;
|
||||
EntityNPCInterface npc = (EntityNPCInterface) copied;
|
||||
IDataDisplay display = (IDataDisplay) npc.display;
|
||||
modelEntity.textureResLoc = NpcTextureUtils.getNpcTexture((EntityNPCInterface) copied);
|
||||
modelEntity.modelResLoc = new ResourceLocation(display.getCustomModelData().getModel());
|
||||
|
||||
Reference in new issue
Block a user