mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-20 08:49:41 +00:00
Added configurable limits to skin overlays and dialog images.
This commit is contained in:
1 parent
7cfc4ccca4
commit
40a210ce8f
5 files changed
+29
-1
No files matched your search
@@ -2,6 +2,7 @@ package noppes.npcs.entity.data;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import noppes.npcs.CustomNpcs;
|
||||
import noppes.npcs.Server;
|
||||
import noppes.npcs.constants.EnumPacketClient;
|
||||
import noppes.npcs.controllers.data.PlayerData;
|
||||
@@ -58,6 +59,10 @@ public class DataSkinOverlays implements IOverlayHandler {
|
||||
}
|
||||
|
||||
public void add(int id, ISkinOverlay data) {
|
||||
if (this.overlayList.size() >= CustomNpcs.SkinOverlayLimit) {
|
||||
return;
|
||||
}
|
||||
|
||||
((SkinOverlay) data).parent = this;
|
||||
this.overlayList.put(id, data);
|
||||
updateClient();
|
||||
|
||||
Reference in new issue
Block a user