From a9b2484b3e91dad5593779500c6deb97df5a1e6b Mon Sep 17 00:00:00 2001 From: cewno Date: Fri, 20 Dec 2024 12:13:03 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E4=B8=8E=20Mojang=20API=20Wi?= =?UTF-8?q?ki=20=E7=9B=B8=E5=85=B3=E7=9A=84=E5=9C=B0=E5=9D=80=20(#320)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/customskinloader/loader/MojangAPILoader.java | 4 ++-- README.md | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Common/src/main/java/customskinloader/loader/MojangAPILoader.java b/Common/src/main/java/customskinloader/loader/MojangAPILoader.java index 1a8d114..d56b822 100644 --- a/Common/src/main/java/customskinloader/loader/MojangAPILoader.java +++ b/Common/src/main/java/customskinloader/loader/MojangAPILoader.java @@ -118,7 +118,7 @@ public class MojangAPILoader implements ICustomSkinLoaderPlugin, ProfileLoader.I //Username -> UUID public static GameProfile loadGameProfile(String apiRoot, String username) { - //Doc (https://wiki.vg/Mojang_API#Playernames_-.3E_UUIDs) + //Doc (https://minecraft.wiki/w/Mojang_API#Query_player_UUIDs_in_batch) HttpRequestUtil.HttpResponce responce = HttpRequestUtil.makeHttpRequest(new HttpRequestUtil.HttpRequest(apiRoot + "profiles/minecraft").setCacheTime(600).setPayload(GSON.toJson(Collections.singletonList(username)))); if (StringUtils.isEmpty(responce.content)) { return null; @@ -154,7 +154,7 @@ public class MojangAPILoader implements ICustomSkinLoaderPlugin, ProfileLoader.I //UUID -> Profile public static GameProfile fillGameProfile(String sessionRoot, GameProfile profile) { - //Doc (http://wiki.vg/Mojang_API#UUID_-.3E_Profile_.2B_Skin.2FCape) + //Doc (https://minecraft.wiki/w/Mojang_API#Query_player's_skin_and_cape) HttpRequestUtil.HttpResponce responce = HttpRequestUtil.makeHttpRequest(new HttpRequestUtil.HttpRequest(sessionRoot + "session/minecraft/profile/" + TextureUtil.fromUUID(profile.getId())).setCacheTime(90)); if (StringUtils.isEmpty(responce.content)) { return profile; diff --git a/README.md b/README.md index ba6b422..012999b 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,7 @@ The problem of incorrectly rendering textures has been fixed. By using this mod, you can see correct avatar of players in Spectator Menu rather than steve and alex. ## Default Load List -- [Mojang](http://www.minecraft.net/) (MojangAPI) +- [Mojang](https://minecraft.wiki/w/Mojang_API) (MojangAPI) - [LittleSkin](https://littleskin.cn/) (CustomSkinAPI) - [BlessingSkin](http://skin.prinzeugen.net/) (CustomSkinAPI) - [ElyBy](http://docs.ely.by/) (ElyByAPI)