Closed ALCC01 closed 8 years ago
Have you experienced any issues in this particular case? Actually, the plugin should already use a GameProfile cache to prevent any problems.
Yes, as I mentioned earlier (maybe the API is cut out of the caching system?) the plugin does not seem to be caching anything.
Maybe I'm doing it wrong, here's how the minigame interacts with the iDisguise API:
Bukkit.getServicesManager().getRegistration(DisguiseAPI.class).getProvider().disguise(player, new PlayerDisguise(nickname));
)Bukkit.getServicesManager().getRegistration(DisguiseAPI.class).getProvider().undisguise(player);
)The problem is, at the beginning of the next game no player gets disguised because the server is banned from the Mojang API. Here's the stacktrace, even if I doubt it will be useful.
The caching system works whether you use the API or not. I tried switching between 2 player disguises about 15 to 20 times on my local server, everything worked fine. So no problem here.
By the way, the stacktrace you linked has nothing to do with iDisguise. It shows an error caused by the Minecraft server itself which failed to load the skin for a player skull block. So, as I said before, the cache works and there is no problem.
With Mojang limiting the skin API at 1 request minute/UUID/ip, I think it would be pretty useful allowing the plugin to cache the skins it downloads.
One particular use case of this feature would be a minigame I'm developing that heavily relies on skins and disguising players as other players (about 20 requests per match), which means that after the first game the server is banned from requiring the same skins, virtually breaking the game.
I hope you'll consider addressing this issue.