修改启服报错

back_recharge
lvxinran 2021-07-01 18:29:39 +08:00
parent 5515c1b9a1
commit d86d08821b
5 changed files with 65 additions and 31 deletions

View File

@ -21,37 +21,39 @@ public abstract class GlobalProtocolsManager {
public static final Logger LOGGER = LoggerFactory.getLogger(GlobalProtocolsManager.class); public static final Logger LOGGER = LoggerFactory.getLogger(GlobalProtocolsManager.class);
private static Map<Integer, gtGBaseHandler> handlers = new HashMap<>(); private static Map<Integer, gtGBaseHandler> handlers = new HashMap<>();
//暂时不用了
public static void initHandler(String pck,ClassLoader classLoader) { public static void initHandler(String pck,ClassLoader classLoader) {
List<Class<?>> handlers = new LinkedList<>(); return;
try { // List<Class<?>> handlers = new LinkedList<>();
try { // try {
ClassLoaderHelper.findLocalClass(pck, gtGBaseHandler.class, classLoader, handlers); // try {
} catch (RuntimeException e) { // ClassLoaderHelper.findLocalClass(pck, gtGBaseHandler.class, classLoader, handlers);
LOGGER.info("request unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e)); // } catch (RuntimeException e) {
} // LOGGER.info("request unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e));
try { // }
ClassLoaderHelper.findClassJar(pck, gtGBaseHandler.class,classLoader, handlers); // try {
} catch (RuntimeException e) { // ClassLoaderHelper.findClassJar(pck, gtGBaseHandler.class,classLoader, handlers);
LOGGER.info("request unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e)); // } catch (RuntimeException e) {
} // LOGGER.info("request unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e));
// }
handlers.forEach(hand -> //
{ // handlers.forEach(hand ->
gtGBaseHandler baseHandler = null; // {
// gtGBaseHandler baseHandler = null;
try { //
baseHandler = (gtGBaseHandler) hand.newInstance(); // try {
} catch (Exception ex) { // baseHandler = (gtGBaseHandler) hand.newInstance();
LOGGER.info("request unknow Exception {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(ex)); // } catch (Exception ex) {
} // LOGGER.info("request unknow Exception {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(ex));
// }
if (null != baseHandler) { //
addHandler(baseHandler); // if (null != baseHandler) {
} // addHandler(baseHandler);
}); // }
} catch (RuntimeException e2) { // });
LOGGER.info("initHandler unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e2)); // } catch (RuntimeException e2) {
} // LOGGER.info("initHandler unknow RuntimeException {} ", ErrorPrintUtil.getExceptionStackTraceFileLineAndMethod(e2));
// }
} }

View File

@ -26,6 +26,8 @@ public class SEndlessHeroProp implements BaseConfig {
private int[][] props; private int[][] props;
private int heroRankId;
private int heroStarId; private int heroStarId;
public static Map<Integer,Map<Integer,Long>> propsMap = new HashMap<>(); public static Map<Integer,Map<Integer,Long>> propsMap = new HashMap<>();
@ -83,4 +85,8 @@ public class SEndlessHeroProp implements BaseConfig {
public int getHeroStarId() { public int getHeroStarId() {
return heroStarId; return heroStarId;
} }
public int getHeroRankId() {
return heroRankId;
}
} }

View File

@ -31,6 +31,8 @@ public class SHeroSkin implements BaseConfig {
private int[] headIcon; private int[] headIcon;
private int show;
public static Map<Integer,SHeroSkin> skinMapByType; public static Map<Integer,SHeroSkin> skinMapByType;
@ -94,4 +96,8 @@ public class SHeroSkin implements BaseConfig {
public int[] getHeadIcon() { public int[] getHeadIcon() {
return headIcon; return headIcon;
} }
public int getShow() {
return show;
}
} }

View File

@ -54,6 +54,10 @@ public class SRechargeCommodityNewConfig implements BaseConfig {
private String rechargeId5; private String rechargeId5;
private String rechargeId6; private String rechargeId6;
private String rechargeId7;
private String rechargeId8;
private String rechargeId9;
private String rechargeId10;
private int[] forbid; private int[] forbid;
@ -174,6 +178,22 @@ public class SRechargeCommodityNewConfig implements BaseConfig {
return rechargeId6; return rechargeId6;
} }
public String getRechargeId7() {
return rechargeId7;
}
public String getRechargeId8() {
return rechargeId8;
}
public String getRechargeId9() {
return rechargeId9;
}
public String getRechargeId10() {
return rechargeId10;
}
public String[][] getCondition() { public String[][] getCondition() {
return condition; return condition;
} }

View File

@ -197,7 +197,7 @@ public class STableManager {
LOGGER.error("file not find {}, do not find sheet with {} you need rebuild all sheet by gen sheet tool!", path, tableName); LOGGER.error("file not find {}, do not find sheet with {} you need rebuild all sheet by gen sheet tool!", path, tableName);
throw new NullPointerException("clazz.null" + clazz.getName()); throw new NullPointerException("clazz.null" + clazz.getName());
} }
LOGGER.info("initMap:{}", clazz.getSimpleName()); LOGGER.info("initConfig:{}", clazz.getSimpleName());
readFileToCache(clazz, map, file); readFileToCache(clazz, map, file);
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();