PluginBugs / Issues-ItemsAdder

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

Custom armor - mixed textures. #3647

Closed JrRequeim closed 4 months ago

JrRequeim commented 5 months ago

Terms

Discord tag (optional)

requeim

What happened?

Hello there! So, I've been thinking about it for a few days and can't find a solution. - I'm using ExecutableItems to create custom armor pieces (with custom abilities) based on IA resorucepack. The problem is, that everyone sees different textures, mixed up. For now, i have only 3 custom sets on my server, and some players see them well, but rest see them wrongly. player_two_pov player_one_pov

Steps to reproduce the issue

  1. Use /iaget .
  2. Dressup the armor piece.
  3. Check the other players can see the same/correct texture.

Server version

Current: git-Purpur-2144 (MC: 1.20.4)*

ItemsAdder Version

3.6.3-beta-14

ProtocolLib Version

5.2.0-SNAPSHOT-679

LoneLibs Version

1.0.45

Full server log

https://mclo.gs/AAfbrRU#L1372

Error (optional)

[13:29:22] [Server thread/INFO]: JrRequeim issued server command: /iazip
[13:29:22] [pool-73-thread-1/INFO]: [Host] Stopped self-host webserver on port: 8163
[13:29:22] [Server thread/INFO]: [Host] Starting self-host webserver on port: 8163
[13:29:22] [Server thread/WARN]: Warning: forcefully setting player resourcepack status to installed because the plugin was reloaded.
[13:29:22] [Server thread/WARN]: Warning: forcefully setting player resourcepack status to installed because the plugin was reloaded.
[13:29:22] [Server thread/WARN]: Warning: forcefully setting player resourcepack status to installed because the plugin was reloaded.
[13:29:22] [Server thread/WARN]: Warning: forcefully setting player resourcepack status to installed because the plugin was reloaded.
[13:29:22] [Server thread/INFO]: [Pack] Extracting internal contents from .jar
[13:29:22] [Server thread/ERROR]: [Pack] Failed to update old 'contents/_iainternal' files. Consider deleting the folder and regenerate your pack.
[13:29:22] [Server thread/WARN]: lonelibs.com.alibaba.fastjson2.JSONException: offset 0, character , line 1, column 1, fastjson-version 2.0.43 
[13:29:22] [Server thread/WARN]:    at LoneLibs.jar//lonelibs.com.alibaba.fastjson2.JSONReader.read(JSONReader.java:2066)
[13:29:22] [Server thread/WARN]:    at LoneLibs.jar//lonelibs.com.alibaba.fastjson2.JSONReader.readJSONObject(JSONReader.java:2564)
[13:29:22] [Server thread/WARN]:    at ItemsAdder_3.6.3-beta-14.jar//ia.m.sn.a(SourceFile:90)
[13:29:22] [Server thread/WARN]:    at ItemsAdder_3.6.3-beta-14.jar//ia.m.qe.cC(SourceFile:192)
[13:29:22] [Server thread/WARN]:    at ItemsAdder_3.6.3-beta-14.jar//ia.m.G.b(SourceFile:668)
[13:29:22] [Server thread/WARN]:    at ItemsAdder_3.6.3-beta-14.jar//ia.m.G.c(SourceFile:641)
[13:29:22] [Server thread/WARN]:    at org.bukkit.craftbukkit.v1_20_R3.scheduler.CraftTask.run(CraftTask.java:101)
[13:29:22] [Server thread/WARN]:    at org.bukkit.craftbukkit.v1_20_R3.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:482)
[13:29:22] [Server thread/WARN]:    at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:1669)
[13:29:22] [Server thread/WARN]:    at net.minecraft.server.dedicated.DedicatedServer.b(DedicatedServer.java:487)
[13:29:22] [Server thread/WARN]:    at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:1548)
[13:29:22] [Server thread/WARN]:    at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:1236)
[13:29:22] [Server thread/WARN]:    at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323)
[13:29:22] [Server thread/WARN]:    at java.base/java.lang.Thread.run(Thread.java:840)
[13:29:22] [Server thread/INFO]: [Pack] DONE extracting internal contents from .jar

Problematic items yml configuration file (optional)

info:
  namespace: my_items
armors_rendering:
  popielna_zbroja:
    color: '#ffffff'
    layer_1: armor/popielna_zbroja/popielna_layer_1
    layer_2: armor/popielna_zbroja/popielna_layer_2
    use_color: false
items:
  popielny_helm:
    display_name: Popielny hełm
    permission: group.default
    executableitem:
      id: popielny_helm
    resource:
      generate: true
      textures:
      - item/popielny_helm
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: head
        custom_armor: popielna_zbroja
  popielny_napiersnik:
    display_name: Popielny napierśnik
    permission: group.default
    executableitem:
      id: popielny_napiersnik
    resource:
      generate: true
      textures:
      - item/popielny_napiersnik
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: chest
        custom_armor: popielna_zbroja
  popielne_nogawice:
    display_name: Popielne nogawice
    permission: group.default
    executableitem:
      id: popielne_nogawice
    resource:
      generate: true
      textures:
      - item/popielne_nogawice
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: legs
        custom_armor: popielna_zbroja
  popielne_buty:
    display_name: Popielne buty
    permission: group.default
    executableitem:
      id: popielne_buty
    resource:
      generate: true
      textures:
      - item/popielne_buty
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: FEET
        custom_armor: popielna_zbroja

.....................................................

info:
  namespace: my_items
armors_rendering:
  zbroja_eternal:
    color: '#fffffe'
    layer_1: armor/zbroja_eternal/eternal_layer_1
    layer_2: armor/zbroja_eternal/eternal_layer_2
items:
  helm_eternal:
    display_name: Hełm Eternal
    permission: group.default
    executableitem:
      id: helm
    resource:
      generate: true
      textures:
      - item/helm_eternal
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: head
        custom_armor: zbroja_eternal
    attribute_modifiers:
      head:
        armor: 9
        armorToughness: 1
  napiersnik_eternal:
    display_name: Napierśnik Eternal
    permission: group.default
    executableitem:
      id: napiersnik
    resource:
      generate: true
      textures:
      - item/napiersnik_eternal
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: chest
        custom_armor: zbroja_eternal
    attribute_modifiers:
      chest:
        armor: 7
        armorToughness: 1
  nogawice_eternal:
    display_name: Nogawice Eternal
    permission: group.default
    executableitem:
      id: nogawice
    resource:
      generate: true
      textures:
      - item/nogawice_eternal
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: legs
        custom_armor: zbroja_eternal
    attribute_modifiers:
      legs:
        armor: 5
        armorToughness: 1
  buty_eternal:
    display_name: Buty Eternal
    permission: group.default
    executableitem:
      id: wyskok
    resource:
      generate: true
      textures:
      - item/buty_eternal
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: FEET
        custom_armor: zbroja_eternal
    attribute_modifiers:
      feet:
        armor: 3
        armorToughness: 1

..............................................

info:
  namespace: my_items
armors_rendering:
  zbroja_syrena:
    color: '#fffffd'
    layer_1: armor/zbroja_syrena/syrena_layer_1
    layer_2: armor/zbroja_syrena/syrena_layer_2
    use_color: false
items:
  helm_syrena:
    display_name: Syreni Hełm
    permission: group.default
    executableitem:
      id: syreni_helm
    resource:
      generate: true
      textures:
      - item/helm_syrena
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: head
        custom_armor: zbroja_syrena
  napiersnik_syrena:
    display_name: Syreni Napierśnik
    permission: group.default
    executableitem:
      id: syreni_napiersnik
    resource:
      generate: true
      textures:
      - item/napiersnik_syrena
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: chest
        custom_armor: zbroja_syrena
  nogawice_syrena:
    display_name: Syrenie Nogawice
    permission: group.default
    executableitem:
      id: syrenie_nogawice
    resource:
      generate: true
      textures:
      - item/nogawice_syrena
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: legs
        custom_armor: zbroja_syrena
  buty_syrena:
    display_name: Syrenie buty
    permission: group.default
    executableitem:
      id: syrenie_buty
    resource:
      generate: true
      textures:
      - item/buty_syrena
    durability:
      max_custom_durability: 1000
    specific_properties:
      armor:
        slot: FEET
        custom_armor: zbroja_syrena

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)

https://imgur.com/a/1T9ptiO

Andre601 commented 5 months ago

Different textures for different players usually is an indicator for them not loading the resource pack properly. Double check that they actually did properly download the resource pack from the server.

Also, the error you've shown reports an issue with the _iainternal folder (Some malformed JSON it seems like). You should delete the folder and let ItemsAdder recreate it to try and fix this issue. Perhaps this also fixes the issue you're having.

JrRequeim commented 5 months ago

Helloo. I fixed the error with iainternal like u said. I sent my IA pack from (appdata/.minecraft/downloads) to another player, he still sees those armors wrongly. But i found something, if i take glitched armor and write /iacolor #ffffff (armor colour id) it fixes itself immediately... Any ideas how to figure it out? The thing seems trivial ;-;