Fixed script console not appearing with the new global script tab saving method.

This commit is contained in:
Luis C.M committed 2023-02-19 15:20:51 -06:00
1 parent 79e13dfade
commit de6375c4cb
10 files changed
+58 -47

No files matched your search

@@ -210,6 +210,7 @@ public class PacketHandlerServer{
compound.setBoolean("ScriptEnabled", data.getEnabled());
compound.setString("ScriptLanguage", data.getLanguage());
compound.setTag("Languages", ScriptController.Instance.nbtLanguages());
compound.setTag("ScriptConsole", NBTTags.NBTLongStringMap(data.getConsoleText()));
Server.sendData(player, EnumPacketClient.GUI_DATA, compound);
List<ScriptContainer> containers = data.getScripts();
for (int i = 0; i < containers.size(); i++) {
@@ -238,6 +239,7 @@ public class PacketHandlerServer{
}
}
data.setEnabled(compound.getBoolean("ScriptEnabled"));
data.setConsoleText(NBTTags.GetLongStringMap(compound.getTagList("ScriptConsole", 10)));
}
}