mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2025-01-14 12:11:30 +01:00
Fix skin loading
This commit is contained in:
parent
11a3608f5e
commit
3fb0176c5d
@ -123,8 +123,8 @@ public class HumanController extends AbstractEntityController {
|
||||
.append(UUIDTypeAdapter.fromUUID(profile.getId())).toString());
|
||||
url = HttpAuthenticationService.concatenateURL(url,
|
||||
new StringBuilder().append("unsigned=").append(!requireSecure).toString());
|
||||
MinecraftProfilePropertiesResponse response = (MinecraftProfilePropertiesResponse) MAKE_REQUEST.invoke(url,
|
||||
null, MinecraftProfilePropertiesResponse.class);
|
||||
MinecraftProfilePropertiesResponse response = (MinecraftProfilePropertiesResponse) MAKE_REQUEST.invoke(
|
||||
auth, url, null, MinecraftProfilePropertiesResponse.class);
|
||||
if (response == null) {
|
||||
return profile;
|
||||
}
|
||||
@ -140,6 +140,7 @@ public class HumanController extends AbstractEntityController {
|
||||
try {
|
||||
realUUID = uuid.call();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return;
|
||||
}
|
||||
GameProfile skinProfile = null;
|
||||
@ -150,6 +151,8 @@ public class HumanController extends AbstractEntityController {
|
||||
} catch (Exception e) {
|
||||
if (e.getMessage().contains("too many requests")) {
|
||||
Bukkit.getScheduler().runTaskLaterAsynchronously(CitizensAPI.getPlugin(), this, 200);
|
||||
} else {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user