From f59e58a15a98103ac8db0e64a304e57a243e8001 Mon Sep 17 00:00:00 2001 From: Alexander Xia Date: Sat, 27 Feb 2016 16:37:05 +0800 Subject: [PATCH] Fix rename bug --- Common/customskinloader/loader/CustomSkinAPILoader.java | 4 ++-- Common/customskinloader/loader/LegacyLoader.java | 6 +++--- Common/customskinloader/loader/MojangAPILoader.java | 6 +++--- Common/customskinloader/loader/UniSkinAPILoader.java | 4 ++-- Common/customskinloader/tweaker/ClassTransformer.java | 2 +- Common/customskinloader/tweaker/ForgeTweaker.java | 2 +- Common/customskinloader/tweaker/Tweaker.java | 2 +- .../utils/{HttpUtil.java => HttpUtil0.java} | 2 +- 8 files changed, 14 insertions(+), 14 deletions(-) rename Common/customskinloader/utils/{HttpUtil.java => HttpUtil0.java} (99%) diff --git a/Common/customskinloader/loader/CustomSkinAPILoader.java b/Common/customskinloader/loader/CustomSkinAPILoader.java index cb68c6f..03d2eb9 100644 --- a/Common/customskinloader/loader/CustomSkinAPILoader.java +++ b/Common/customskinloader/loader/CustomSkinAPILoader.java @@ -9,7 +9,7 @@ import customskinloader.CustomSkinLoader; import customskinloader.ModelManager; import customskinloader.UserProfile; import customskinloader.config.SkinSiteProfile; -import customskinloader.utils.HttpUtil; +import customskinloader.utils.HttpUtil0; public class CustomSkinAPILoader implements IProfileLoader { public static final String TEXTURES="textures/"; @@ -19,7 +19,7 @@ public class CustomSkinAPILoader implements IProfileLoader { CustomSkinLoader.logger.info("Root not denined."); return null; } - String json=HttpUtil.readHttp(ssp.root+username+".json"); + String json=HttpUtil0.readHttp(ssp.root+username+".json"); if(json==null||json.equals("")){ CustomSkinLoader.logger.info("Profile not found."); return null; diff --git a/Common/customskinloader/loader/LegacyLoader.java b/Common/customskinloader/loader/LegacyLoader.java index 463f80a..e65549f 100644 --- a/Common/customskinloader/loader/LegacyLoader.java +++ b/Common/customskinloader/loader/LegacyLoader.java @@ -3,7 +3,7 @@ package customskinloader.loader; import customskinloader.CustomSkinLoader; import customskinloader.UserProfile; import customskinloader.config.SkinSiteProfile; -import customskinloader.utils.HttpUtil; +import customskinloader.utils.HttpUtil0; public class LegacyLoader implements IProfileLoader { public static final String USERNAME_REGEX="\\{USERNAME\\}"; @@ -11,14 +11,14 @@ public class LegacyLoader implements IProfileLoader { public UserProfile loadProfile(SkinSiteProfile ssp, String username) throws Exception { UserProfile profile=new UserProfile(); if(ssp.skin!=null && !ssp.skin.equals("")){ - String skin=HttpUtil.getRealUrl(ssp.skin.replaceAll(USERNAME_REGEX, username)); + String skin=HttpUtil0.getRealUrl(ssp.skin.replaceAll(USERNAME_REGEX, username)); if(skin!=null&&!skin.equals("")){ profile.skinUrl=skin; profile.model="default"; } } if(ssp.cape!=null && !ssp.cape.equals("")){ - String cape=HttpUtil.getRealUrl(ssp.cape.replaceAll(USERNAME_REGEX, username)); + String cape=HttpUtil0.getRealUrl(ssp.cape.replaceAll(USERNAME_REGEX, username)); if(cape!=null&&!cape.equals("")){ profile.capeUrl=cape; } diff --git a/Common/customskinloader/loader/MojangAPILoader.java b/Common/customskinloader/loader/MojangAPILoader.java index b8e8e09..9bf1bdd 100644 --- a/Common/customskinloader/loader/MojangAPILoader.java +++ b/Common/customskinloader/loader/MojangAPILoader.java @@ -14,14 +14,14 @@ import customskinloader.CustomSkinLoader; import customskinloader.ModelManager; import customskinloader.UserProfile; import customskinloader.config.SkinSiteProfile; -import customskinloader.utils.HttpUtil; +import customskinloader.utils.HttpUtil0; public class MojangAPILoader implements IProfileLoader { @Override public UserProfile loadProfile(SkinSiteProfile ssp, String username) throws Exception { //Get UUID Begin (http://wiki.vg/Mojang_API#Username_-.3E_UUID_at_time) - String json0=HttpUtil.readHttp("https://api.mojang.com/users/profiles/minecraft/"+username); + String json0=HttpUtil0.readHttp("https://api.mojang.com/users/profiles/minecraft/"+username); if(json0==null||json0.equals("")){ CustomSkinLoader.logger.info("Profile not found.("+username+"'s UUID not found.)"); return null; @@ -34,7 +34,7 @@ public class MojangAPILoader implements IProfileLoader { } //Get UUID End //Get Profile Begin (http://wiki.vg/Mojang_API#UUID_-.3E_Profile_.2B_Skin.2FCape) - String json1=HttpUtil.readHttp("https://sessionserver.mojang.com/session/minecraft/profile/"+uuidProfile.id); + String json1=HttpUtil0.readHttp("https://sessionserver.mojang.com/session/minecraft/profile/"+uuidProfile.id); if(json1==null||json1.equals("")){ CustomSkinLoader.logger.info("Profile not found.("+username+"'s Profile is empty.)"); return null; diff --git a/Common/customskinloader/loader/UniSkinAPILoader.java b/Common/customskinloader/loader/UniSkinAPILoader.java index 2877904..984d08f 100644 --- a/Common/customskinloader/loader/UniSkinAPILoader.java +++ b/Common/customskinloader/loader/UniSkinAPILoader.java @@ -9,7 +9,7 @@ import customskinloader.CustomSkinLoader; import customskinloader.ModelManager; import customskinloader.UserProfile; import customskinloader.config.SkinSiteProfile; -import customskinloader.utils.HttpUtil; +import customskinloader.utils.HttpUtil0; public class UniSkinAPILoader implements IProfileLoader { public static final String TEXTURES="textures/"; @@ -19,7 +19,7 @@ public class UniSkinAPILoader implements IProfileLoader { CustomSkinLoader.logger.info("Root not denined."); return null; } - String json=HttpUtil.readHttp(ssp.root+username+".json"); + String json=HttpUtil0.readHttp(ssp.root+username+".json"); if(json==null||json.equals("")){ CustomSkinLoader.logger.info("Profile not found."); return null; diff --git a/Common/customskinloader/tweaker/ClassTransformer.java b/Common/customskinloader/tweaker/ClassTransformer.java index b5fffa4..40e156c 100644 --- a/Common/customskinloader/tweaker/ClassTransformer.java +++ b/Common/customskinloader/tweaker/ClassTransformer.java @@ -14,7 +14,7 @@ public class ClassTransformer implements IClassTransformer { public ClassTransformer() { ForgeTweaker.logger.info("ClassTransformer Begin"); try { - URLClassLoader ucl = (URLClassLoader)idv.jlchntoz.tweaker.ClassTransformer.class.getClassLoader(); + URLClassLoader ucl = (URLClassLoader)this.getClass().getClassLoader(); URL urls[] = ucl.getURLs(); for (int i = 0; i < urls.length; i++) { URL url = urls[i]; diff --git a/Common/customskinloader/tweaker/ForgeTweaker.java b/Common/customskinloader/tweaker/ForgeTweaker.java index c40e905..8febf2a 100644 --- a/Common/customskinloader/tweaker/ForgeTweaker.java +++ b/Common/customskinloader/tweaker/ForgeTweaker.java @@ -11,7 +11,7 @@ import net.minecraft.launchwrapper.LaunchClassLoader; public class ForgeTweaker implements ITweaker { private static final File TWEAKER_LOG_FILE = new File("CustomSkinLoader/Tweaker.log"); - public static MainLogger logger = new MainLogger(TWEAKER_LOG_FILE); + public static Logger logger = new Logger(TWEAKER_LOG_FILE); public ForgeTweaker() { logger.info("Using ForgeTweaker"); diff --git a/Common/customskinloader/tweaker/Tweaker.java b/Common/customskinloader/tweaker/Tweaker.java index 38c54ad..59da246 100644 --- a/Common/customskinloader/tweaker/Tweaker.java +++ b/Common/customskinloader/tweaker/Tweaker.java @@ -17,7 +17,7 @@ public class Tweaker implements ITweaker { private String profile; private static final File TWEAKER_LOG_FILE = new File("CustomSkinLoader/Tweaker.log"); - public static MainLogger logger = new MainLogger(TWEAKER_LOG_FILE); + public static Logger logger = new Logger(TWEAKER_LOG_FILE); public Tweaker() { logger.info("Using Tweaker"); diff --git a/Common/customskinloader/utils/HttpUtil.java b/Common/customskinloader/utils/HttpUtil0.java similarity index 99% rename from Common/customskinloader/utils/HttpUtil.java rename to Common/customskinloader/utils/HttpUtil0.java index 8f80072..952ea49 100644 --- a/Common/customskinloader/utils/HttpUtil.java +++ b/Common/customskinloader/utils/HttpUtil0.java @@ -11,7 +11,7 @@ import org.apache.commons.io.IOUtils; import customskinloader.CustomSkinLoader; -public class HttpUtil { +public class HttpUtil0 { /** * Read all text from http. */