PluginBugs / Issues-ItemsAdder

Repository used to keep track of issues of my plugin ItemsAdder
https://itemsadder.devs.beer
53 stars 21 forks source link

Resourcepack protection sometimes throws java.lang.IndexOutOfBoundsException #3208

Closed Fergs32 closed 6 months ago

Fergs32 commented 10 months ago

Terms

Discord tag (optional)

No response

What happened?

Hi, I've recently came across this error, and it's unable to protect the texturepack. Sometimes it does do it, but then sometimes it doesn't do it and it outputs a error and some warnings when it does occur. I checked all my textures / models, and they're all configurated correctly.

Steps to reproduce the issue

I think this happens when you have 1MB+ of models / textures maybe, but I can't seem to figure out why it does it myself. I'll attach the error I get image

Server version

git-Paper-196 (MC: 1.20.1) (Implementing API version 1.20.1-R0.1-SNAPSHOT)

ItemsAdder Version

version 3.6.2c

ProtocolLib Version

ProtocolLib version 5.1.1-SNAPSHOT-669

LoneLibs Version

LoneLibs version 1.0.31

FULL server log

No response

Error (optional)

10.12 19:34:29 [Server] [INFO] outrated issued server command: /iazip

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Host] Stopped self-host webserver on port: 8072

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Host] Starting self-host webserver on port: 8072

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Pack] Extracting internal contents from .jar

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Pack] DONE extracting internal contents from .jar

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Loaded 59 items

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 0/188 REAL block IDs

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 0/750 REAL_NOTE block IDs

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 0/63 REAL_TRANSPARENT block IDs

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 0/127 REAL_WIRE block IDs

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 0/14 FIRE block IDs

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Used 45/6608 font_images

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Init] Loaded 3 categories

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Init] Loaded successfully in 73ms

10.12 19:34:29 [Server] [INFO] [ItemsAdder]

10.12 19:34:29 [Server] [INFO] [ItemsAdder]

10.12 19:34:29 [Server] [INFO] [ItemsAdder] [Pack] Started generation

10.12 19:34:29 [Server] [INFO] [PlaceholderAPI] Successfully registered internal expansion: img [1.0.1]

10.12 19:34:29 [Server] [INFO] [PlaceholderAPI] Successfully registered internal expansion: iaplayerstat [1.0.1]

10.12 19:34:29 [Server] [INFO] [ItemsAdder] Reloading ItemsAdder Custom Entities Citizens NPCs

10.12 19:34:30 [Server] [WARN] [EntityLookup] Entity uuid already exists: 1cf4b649-fc37-2c1e-8f87-57c7497669ee, mapped to EntityHumanNPC[''/3754, uuid='1cf4b649-fc37-2c1e-8f87-57c7497669ee', l='ServerLevel[Spawn]', x=490.70, y=30.00, z=124.55, cpos=[30, 7], tl=0, v=true]( at 490.7,30.0,124.5513), can't add EntityHumanNPC[''/3758, uuid='1cf4b649-fc37-2c1e-8f87-57c7497669ee', l='ServerLevel[Spawn]', x=480.50, y=30.00, z=128.50, cpos=[30, 8], tl=0, v=false]( at 480.5,30.0,128.5)

10.12 19:34:30 [Server] [WARN] [ItemsAdder] Duplicate char  (\\uF808) 'space:font/space_split.png'. File: contents/Example/assets/minecraft/font/default.json

10.12 19:34:30 [Server] [INFO] [ItemsAdder]

10.12 19:34:30 [Server] [INFO] [ItemsAdder] [Pack] Generated resourcepack

10.12 19:34:30 [Server] [INFO] [ItemsAdder] [OK] Your zip file will be protected from unzip (as set in config.yml)

10.12 19:34:30 [Server] [INFO] [ItemsAdder] [Pack] Compressing resource_pack ...

10.12 19:34:30 [Server] [ERROR] [ItemsAdder] Failed to protect zip file.

10.12 19:34:30 [Server] [WARN] java.lang.IndexOutOfBoundsException

10.12 19:34:30 [Server] [WARN] at java.base/java.io.RandomAccessFile.writeBytes(Native Method)

10.12 19:34:30 [Server] [WARN] at java.base/java.io.RandomAccessFile.write(RandomAccessFile.java:558)

10.12 19:34:30 [Server] [WARN] at ItemsAdder_3.6.2c.jar//ia.m.jq.e(SourceFile:116)

10.12 19:34:30 [Server] [WARN] at ItemsAdder_3.6.2c.jar//ia.m.jd.a(SourceFile:229)

10.12 19:34:30 [Server] [WARN] at ItemsAdder_3.6.2c.jar//ia.m.jh.a(SourceFile:436)

10.12 19:34:30 [Server] [WARN] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftTask.run(CraftTask.java:101)

10.12 19:34:30 [Server] [WARN] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:57)

10.12 19:34:30 [Server] [WARN] at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22)

10.12 19:34:30 [Server] [WARN] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)

10.12 19:34:30 [Server] [WARN] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)

10.12 19:34:30 [Server] [WARN] at java.base/java.lang.Thread.run(Thread.java:833)

Problematic items yml configuration file (optional)

No response

Other files, you can drag and drop them here to upload. (optional)

No response

Screenshots/Videos (you can drag and drop files or paste links)

No response

github-actions[bot] commented 10 months ago

Hello, your report will be looked into as soon as possible. Please do not bump this thread and don't post it on multiple platforms.

Thanks a lot for your patience.

LoneDev6 commented 10 months ago

Sometimes it does do it, but then sometimes it doesn't do

Is it totally random? I mean, would it fail sometimes if you call /iazip and sometimes not? With the SAME content? Or it happens when you add certain files?