set role on client side before opening role editors

This commit is contained in:
luisc committed 2025-06-02 14:08:59 -05:00
1 parent b86c1ceabb
commit e9f810dc21
1 file changed
+1
@@ -119,6 +119,7 @@ public class GuiNpcAdvanced extends GuiNPCInterface2 implements IGuiData {
@Override
public void setGuiData(NBTTagCompound compound) {
if (compound.hasKey("RoleData")) {
npc.advanced.setRole(compound.getByte("RoleData"));
if (npc.roleInterface != null)
npc.roleInterface.readFromNBT(compound);