Closed GabryOsas closed 1 year ago
If I understand correctly, you’re running a server with online-mode set to false?
I’m thinking it may be a version incompatibility bug (I didn’t test the new version compatibility with players), or it’s related to not having online mode on.
I’ll get back to you when I’ve managed to reproduce and identify the issue. Thanks for the bug report :)
Yes online-mode is set to false. 👋
Can confirm it's caused by the the version. 1.16.5 spigot doesn't include a way to fetch the player profile this easily. I'm working on my own implementation that fetches from Mojang directly. I'll update you once it's ready
Ok thanks!
Hi @GabryOsas, I have fixed this issue in the latest release, 1.1.3: https://github.com/jensjeflensje/minecraft_imagery/releases/tag/1.1.3.
I have made sure it works on both 1.16.5 and 1.19.4 (the base plugin version).
Make sure to update your plugin's dependency information with version 1.1.3.
Thanks for the report! Looking forward to your creations with the library 😄
Thanks!
I tried the new library but from a new error:
java.lang.RuntimeException: Mojang API request was not successful
at dev.jensderuiter.minecraft_imagery.Util.getPlayerProfile(Util.java:178) ~[?:?]
at dev.jensderuiter.minecraft_imagery.Util.getPlayerSkin(Util.java:149) ~[?:?]
at dev.jensderuiter.minecraft_imagery.Util.getPlayerSkinFront(Util.java:58) ~[?:?]
at dev.jensderuiter.minecraft_imagery.image.ImageCapture.render(ImageCapture.java:230) ~[?:?]
at me.gabryosas.commandi.CustomMapRender$1.run(CustomMapRender.java:60) ~[?:?]
at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftTask.run(CraftTask.java:101) ~[patched_1.16.5.jar:git-Paper-794]
at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:54) ~[patched_1.16.5.jar:git-Paper-794]
at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22) ~[patched_1.16.5.jar:git-Paper-794]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630) ~[?:?]
at java.lang.Thread.run(Thread.java:831) [?:?]
Maybe because if the server is also for people who haven't bought minecraft it's wrong?
Yeah that's caused by the players not having an actual skin, as they're not registered with Mojang. Isn't there a way you can assign a user to an actual Minecraft account (so that it has a UUID the library can use)?
What is your expected result? I mean, if they're not actual Minecraft accounts, how would they have a skin? Or are you expecting them to be a steve/alex?
I think servers without online-mode to true are very rare for this use case. I also don't want to support cracked servers explicitly.
Does the SkinRestorer library not allow this?
I don't know for sure. You can try it. That may fix your problem.
Rendering a steve/alex when a player's skin can't be fetched may be something to look into. It's always nice as a fallback.
👌
Bug
These days I'm trying this library (1.1.2). My server is 1.16.5 and uses java 16. Players who have not paid for minecraft can also enter it. When I take the photo from this error:
Is this a library bug or did I do something wrong? I literally copied and pasted the code offered as an example.