四象心法
parent
70b92f1b91
commit
9178024c9f
|
@ -343,8 +343,13 @@ public interface BIReason {
|
|||
|
||||
int QIMENDUNJIA_DRAW = 1103;//奇门遁甲
|
||||
int QIMENDUNJIA_DRAW_CONSUME = 1104;//奇门遁甲消耗
|
||||
int SIXIANG_UP_COST=1105;//四象心法强化消耗
|
||||
|
||||
int SIXIANG_UP_STAR_COST=1106;//四象心法进阶消耗
|
||||
|
||||
int FOUR_CHALLENGE_FIRST = 1201;//四灵试炼首通
|
||||
int FOUR_CHALLENGE_SWEEP = 1202;//四灵试炼扫荡
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -175,10 +175,14 @@ public class GetPlayerInfoHandler extends BaseHandler{
|
|||
user.getPlayerInfoManager().getMonthCard().put(Global.LMONTHCARDID, (int) (System.currentTimeMillis() / 1000));
|
||||
Poster.getPoster().dispatchEvent(new NewWelfareEvent(user, NewWelfareTypeEnum.RECHARGE_BUY.getType(),Global.LMONTHCARDID));
|
||||
}
|
||||
<<<<<<< Updated upstream
|
||||
|
||||
// 四灵试炼初始化
|
||||
FourChallengeLogic.getInstance().firstGetTimes(user);
|
||||
|
||||
=======
|
||||
List<CommonProto.SixiangxinfaInfo> sixiangxinfaInfos = getSixiangxinfaInfos(heroManager);
|
||||
>>>>>>> Stashed changes
|
||||
int randomCount =SLotterySpecialConfig.getLotteryListByDifferentType(7).iterator().next().getCount()- user.getHeroManager().getRandomPoolByType().getOrDefault(11,new HashMap<>()).getOrDefault(7,0);
|
||||
StoreLogic.reloadStoreInfo(user,7);//重载功能商店
|
||||
|
||||
|
@ -224,6 +228,7 @@ public class GetPlayerInfoHandler extends BaseHandler{
|
|||
.setDailyredpack(playerInfoManager.getDailyWelfareRedPacket())
|
||||
.setRandomCount(randomCount)
|
||||
.addAllDrawTimes(CBean2Proto.getRandomTypeNums(user))
|
||||
.addAllSixiangInfos(sixiangxinfaInfos)
|
||||
.addAllHelpFightList(CBean2Proto.getHelpFightList(user))
|
||||
.build();
|
||||
ReportUtil.onReportEvent(user, ReportEventEnum.APP_LOGIN.getType());
|
||||
|
@ -246,6 +251,31 @@ public class GetPlayerInfoHandler extends BaseHandler{
|
|||
}
|
||||
}
|
||||
|
||||
private List<CommonProto.SixiangxinfaInfo> getSixiangxinfaInfos(HeroManager heroManager) {
|
||||
Map<Integer,SixiangProfessionInfo> sixiangDataMap = heroManager.getSixiangDataMap();
|
||||
List<CommonProto.SixiangxinfaInfo> sixiangxinfaInfos = new ArrayList<>(sixiangDataMap.size());
|
||||
for (Map.Entry<Integer, SixiangProfessionInfo> integerMapEntry : sixiangDataMap.entrySet()) {
|
||||
Integer key = integerMapEntry.getKey();
|
||||
SixiangProfessionInfo value = integerMapEntry.getValue();
|
||||
List<CommonProto.SixiangxinfaPropertyInfo> sixiangxinfaPropertyInfos = new ArrayList<>(value.propertyMap.size());
|
||||
for (Map.Entry<Integer, Integer> integerIntegerEntry : value.propertyMap.entrySet()) {
|
||||
CommonProto.SixiangxinfaPropertyInfo sixiangxinfaPropertyInfo = CommonProto.SixiangxinfaPropertyInfo
|
||||
.newBuilder()
|
||||
.setPropertyId(integerIntegerEntry.getKey())
|
||||
.setPropertyNum(integerIntegerEntry.getValue())
|
||||
.build();
|
||||
sixiangxinfaPropertyInfos.add(sixiangxinfaPropertyInfo);
|
||||
}
|
||||
CommonProto.SixiangxinfaInfo sixiangxinfaInfo = CommonProto.SixiangxinfaInfo.newBuilder()
|
||||
.setProfessionId(key)
|
||||
.setLevel(value.level)
|
||||
.addAllPropertyInfoList(sixiangxinfaPropertyInfos)
|
||||
.build();
|
||||
sixiangxinfaInfos.add(sixiangxinfaInfo);
|
||||
}
|
||||
return sixiangxinfaInfos;
|
||||
}
|
||||
|
||||
/**
|
||||
* 初始化英雄星级map(针对老号)
|
||||
* @param user
|
||||
|
|
|
@ -0,0 +1,96 @@
|
|||
package com.ljsd.jieling.handler.hero;
|
||||
|
||||
import com.ljsd.jieling.exception.ErrorCode;
|
||||
import com.ljsd.jieling.exception.ErrorCodeException;
|
||||
import com.ljsd.jieling.globals.BIReason;
|
||||
import com.ljsd.jieling.handler.BaseHandler;
|
||||
import com.ljsd.jieling.logic.dao.SixiangProfessionInfo;
|
||||
import com.ljsd.jieling.logic.dao.UserManager;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import com.ljsd.jieling.logic.hero.HeroLogic;
|
||||
import com.ljsd.jieling.network.session.ISession;
|
||||
import com.ljsd.jieling.util.ItemUtil;
|
||||
import com.ljsd.jieling.util.MessageUtil;
|
||||
import config.SFourQuadrantConfig;
|
||||
import config.SXiuXian;
|
||||
import manager.STableManager;
|
||||
import org.springframework.stereotype.Component;
|
||||
import rpc.protocols.CommonProto;
|
||||
import rpc.protocols.HeroInfoProto;
|
||||
import rpc.protocols.MessageTypeProto;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@Component
|
||||
public class SixiangUpRequestHandler extends BaseHandler<HeroInfoProto.SixiangUpRequest> {
|
||||
@Override
|
||||
public MessageTypeProto.MessageType getMessageCode() {
|
||||
return MessageTypeProto.MessageType.SIXIANG_UP_REQUEST;
|
||||
}
|
||||
|
||||
//四象心法强化消息
|
||||
@Override
|
||||
public void processWithProto(ISession session, HeroInfoProto.SixiangUpRequest proto) throws Exception {
|
||||
int professionId=proto.getProfessionId();//职业id
|
||||
int uid = session.getUid();
|
||||
User user = UserManager.getUser(uid);
|
||||
SixiangProfessionInfo professionInfo = user.getHeroManager().getSixiangDataMap().get(professionId);
|
||||
int professionLv=professionInfo==null?0:professionInfo.level;
|
||||
SFourQuadrantConfig fourConfig=SFourQuadrantConfig.configByStrtMap.get(professionLv);
|
||||
|
||||
int[][]costArr=fourConfig.getLvupCost();
|
||||
boolean costResult = ItemUtil.itemCost(user,costArr, BIReason.SIXIANG_UP_COST,professionId);
|
||||
if (costResult) {
|
||||
if (professionInfo==null) {
|
||||
professionInfo=new SixiangProfessionInfo();
|
||||
professionInfo.level=0;
|
||||
professionInfo.propertyMap = new HashMap<>();
|
||||
for (int i=0;i<fourConfig.getPropLimit().length;i++){
|
||||
int[]limit=fourConfig.getPropLimit()[i];
|
||||
professionInfo.propertyMap.put(limit[0],0);
|
||||
}
|
||||
}
|
||||
ArrayList<Integer>_randomList=new ArrayList<>();
|
||||
for (int i=0;i<fourConfig.getPropLimit().length;i++){
|
||||
int[]limit=fourConfig.getPropLimit()[i];
|
||||
if (professionInfo.propertyMap.get(limit[0])<limit[1]){
|
||||
_randomList.add(limit[0]);
|
||||
}
|
||||
}
|
||||
int[][]propLvup=fourConfig.getPropLvup();
|
||||
Random random=new Random();
|
||||
for (int i=0;i<10;i++){
|
||||
int index=random.nextInt(_randomList.size());
|
||||
int propId=_randomList.get(index);
|
||||
int addPropNum=propLvup[propId-1][1];
|
||||
int curPropNum= professionInfo.propertyMap.get(propId)+addPropNum;
|
||||
professionInfo.propertyMap.put(propId,curPropNum);
|
||||
}
|
||||
|
||||
for (int i=0;i<fourConfig.getPropLimit().length;i++){
|
||||
int[]limit=fourConfig.getPropLimit()[i];//当前等级属性加成上限信息
|
||||
if (professionInfo.propertyMap.get(limit[0])>limit[1]){
|
||||
professionInfo.propertyMap.put(limit[0],limit[1]);
|
||||
}
|
||||
}
|
||||
user.getHeroManager().putSixiangDataMap(professionId,professionInfo);
|
||||
List<CommonProto.SixiangxinfaPropertyInfo> _list=new ArrayList<>();
|
||||
for (Map.Entry<Integer, Integer> dic : professionInfo.propertyMap.entrySet()) {
|
||||
CommonProto.SixiangxinfaPropertyInfo propertyInfo= CommonProto.SixiangxinfaPropertyInfo.newBuilder()
|
||||
.setPropertyId(dic.getKey())
|
||||
.setPropertyNum(dic.getValue())
|
||||
.build();
|
||||
_list.add(propertyInfo);
|
||||
}
|
||||
LOGGER.info("属性值:{}",professionInfo.propertyMap.get(1));
|
||||
HeroInfoProto.SixiangUpResponse response=HeroInfoProto.SixiangUpResponse.newBuilder()
|
||||
.addAllInfoList(_list)
|
||||
.build();
|
||||
MessageUtil.sendMessage(session,1, MessageTypeProto.MessageType.SIXIANG_UP_RESPONSE_VALUE,response,true);
|
||||
}else{
|
||||
LOGGER.error("四象心法强化材料不足");
|
||||
throw new ErrorCodeException(ErrorCode.SERVER_DEFINE_SELF);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,106 @@
|
|||
package com.ljsd.jieling.handler.hero;
|
||||
|
||||
import com.ljsd.jieling.exception.ErrorCode;
|
||||
import com.ljsd.jieling.exception.ErrorCodeException;
|
||||
import com.ljsd.jieling.globals.BIReason;
|
||||
import com.ljsd.jieling.handler.BaseHandler;
|
||||
import com.ljsd.jieling.logic.dao.SixiangProfessionInfo;
|
||||
import com.ljsd.jieling.logic.dao.UserManager;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import com.ljsd.jieling.logic.fight.eventhandler.IFightEventProcesor;
|
||||
import com.ljsd.jieling.network.session.ISession;
|
||||
import com.ljsd.jieling.util.ItemUtil;
|
||||
import com.ljsd.jieling.util.MessageUtil;
|
||||
import config.SFourQuadrantConfig;
|
||||
import config.SXiuXian;
|
||||
import manager.STableManager;
|
||||
import org.springframework.stereotype.Component;
|
||||
import rpc.protocols.CommonProto;
|
||||
import rpc.protocols.HeroInfoProto;
|
||||
import rpc.protocols.MessageTypeProto;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@Component
|
||||
public class SixiangUpStarRequestHandler extends BaseHandler<HeroInfoProto.SixiangUpRequest> {
|
||||
@Override
|
||||
public MessageTypeProto.MessageType getMessageCode() {
|
||||
return MessageTypeProto.MessageType.SIXIANG_UP_STAR_REQUEST;
|
||||
}
|
||||
|
||||
//四象心法进阶消息
|
||||
@Override
|
||||
public void processWithProto(ISession session, HeroInfoProto.SixiangUpRequest proto) throws Exception {
|
||||
int professionId=proto.getProfessionId();//职业id
|
||||
int uid = session.getUid();
|
||||
User user = UserManager.getUser(uid);
|
||||
SixiangProfessionInfo professionInfo = user.getHeroManager().getSixiangDataMap().get(professionId);
|
||||
SFourQuadrantConfig fourConfig=SFourQuadrantConfig.configByStrtMap.get(professionInfo.level);
|
||||
// if (CheckUpStar(user,professionInfo)) {
|
||||
//
|
||||
// }else{
|
||||
// LOGGER.error("四象心法进阶条件不满足");
|
||||
// throw new ErrorCodeException(ErrorCode.SERVER_DEFINE_SELF);
|
||||
// }
|
||||
int[][]costArr=fourConfig.getRankupCost();
|
||||
boolean costResult = ItemUtil.itemCost(user,costArr, BIReason.SIXIANG_UP_STAR_COST,professionId);
|
||||
if (costResult) {
|
||||
professionInfo.level++;
|
||||
user.getHeroManager().putSixiangDataMap(professionId,professionInfo);
|
||||
///进阶成功刷进阶额外加成属性
|
||||
user.getHeroManager().putSixiangPropUpMap(professionId,CalUpStarPropAdd( professionInfo.level));
|
||||
List<CommonProto.SixiangxinfaPropertyInfo> _list=new ArrayList<>();
|
||||
for (Map.Entry<Integer, Integer> dic : professionInfo.propertyMap.entrySet()) {
|
||||
CommonProto.SixiangxinfaPropertyInfo propertyInfo= CommonProto.SixiangxinfaPropertyInfo.newBuilder()
|
||||
.setPropertyId(dic.getKey())
|
||||
.setPropertyNum(dic.getValue())
|
||||
.build();
|
||||
_list.add(propertyInfo);
|
||||
}
|
||||
HeroInfoProto.SixiangUpStarResponse response=HeroInfoProto.SixiangUpStarResponse.newBuilder()
|
||||
.setStarLv(professionInfo.level)
|
||||
.addAllInfoList(_list)
|
||||
.build();
|
||||
MessageUtil.sendMessage(session,1, MessageTypeProto.MessageType.SIXIANG_UP_STAR_RESPONSE_VALUE,response,true);
|
||||
}else {
|
||||
LOGGER.error("四象心法进阶材料不足");
|
||||
throw new ErrorCodeException(ErrorCode.SERVER_DEFINE_SELF);
|
||||
}
|
||||
}
|
||||
|
||||
//检测当前职业是否可以进阶
|
||||
public boolean CheckUpStar(User user,SixiangProfessionInfo _professionInfo){
|
||||
if (_professionInfo==null)return false;
|
||||
SFourQuadrantConfig nextFourConfig=SFourQuadrantConfig.configByStrtMap.get(_professionInfo.level+1);
|
||||
if (nextFourConfig==null)return false;
|
||||
int xiuxianLv=user.getHeroManager().getPracticeLevel();//当前修仙等级
|
||||
SXiuXian xiuXian = STableManager.getConfig(SXiuXian.class).get(nextFourConfig.getXiuxianLimit());
|
||||
if (xiuxianLv<xiuXian.getRealmId())return false;
|
||||
SFourQuadrantConfig fourConfig=SFourQuadrantConfig.configByStrtMap.get(_professionInfo.level);
|
||||
for (int i=0;i<fourConfig.getPropLimit().length;i++){
|
||||
int[]limit=fourConfig.getPropLimit()[i];//当前等级属性加成上限信息
|
||||
if (_professionInfo.propertyMap.get(limit[0])<limit[1]){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
//计算当前星级的额外属性加成
|
||||
private Map<Integer,Integer> CalUpStarPropAdd(int _level){
|
||||
Map<Integer,Integer>propMap=new HashMap<>();
|
||||
for (int i=0;i<_level;i++){
|
||||
SFourQuadrantConfig fourConfig=SFourQuadrantConfig.configByStrtMap.get(i);
|
||||
int[][]propAddArr=fourConfig.getPropStar();
|
||||
for (int[] ints : propAddArr) {
|
||||
if (propMap.containsKey(ints[0])){
|
||||
int addPropVle=propMap.get(ints[0])+ints[1];
|
||||
propMap.put(ints[0],addPropVle);
|
||||
}else {
|
||||
propMap.put(ints[0],ints[1]);
|
||||
}
|
||||
}
|
||||
}
|
||||
return propMap;
|
||||
}
|
||||
}
|
|
@ -91,6 +91,26 @@ public class HeroManager extends MongoBase {
|
|||
*/
|
||||
private Map<Integer, Map<Integer,Integer>> wishCountByStar = new HashMap<>();
|
||||
|
||||
/**
|
||||
* 四象心法数据
|
||||
* key: 职业类型 value:职业相关数据
|
||||
*/
|
||||
private Map<Integer, SixiangProfessionInfo> sixiangDataMap = new HashMap<>();
|
||||
|
||||
public Map<Integer, SixiangProfessionInfo> getSixiangDataMap() {
|
||||
return sixiangDataMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* 四象心法进阶额外属性加成
|
||||
* key: 职业类型 value:< key: 属性类型 value: 属性加成值 >
|
||||
*/
|
||||
private Map<Integer, Map<Integer,Integer>> sixiangPropUpMap = new HashMap<>();
|
||||
|
||||
public Map<Integer, Map<Integer,Integer>> getSixiangPropUpMap() {
|
||||
return sixiangPropUpMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* 心愿可以选择的英雄列表
|
||||
*/
|
||||
|
@ -128,6 +148,17 @@ public class HeroManager extends MongoBase {
|
|||
updateString("wishCountByStar."+type, starMap);
|
||||
}
|
||||
|
||||
public void putSixiangDataMap(int type,SixiangProfessionInfo professionData) {
|
||||
sixiangDataMap.put(type,professionData);
|
||||
updateString("sixiangDataMap."+type, professionData);
|
||||
}
|
||||
|
||||
public void putSixiangPropUpMap(int professionId,Map<Integer,Integer> _propMap) {
|
||||
sixiangPropUpMap.put(professionId,_propMap);
|
||||
updateString("sixiangPropUpMap."+professionId, _propMap);
|
||||
}
|
||||
|
||||
|
||||
public void updateRandCount(int type, int count){
|
||||
updateString("totalCount." + type, count);
|
||||
totalCount.put(type,count);
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
package com.ljsd.jieling.logic.dao;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public class SixiangProfessionInfo {
|
||||
public int level;//四象心法职业进阶等级
|
||||
public Map<Integer,Integer>propertyMap;//四象心法属性数据
|
||||
|
||||
}
|
|
@ -32,6 +32,7 @@ import com.ljsd.jieling.logic.dao.gm.ArenaOfUser;
|
|||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import com.ljsd.jieling.logic.expedition.ExpeditionLogic;
|
||||
import com.ljsd.jieling.logic.fight.CombatLogic;
|
||||
import com.ljsd.jieling.logic.fight.eventhandler.IFightEventProcesor;
|
||||
import com.ljsd.jieling.logic.fight.passiveSkillCal.PassiveskillCalEnum;
|
||||
import com.ljsd.jieling.logic.help.HelpHero;
|
||||
import com.ljsd.jieling.logic.help.HelpHeroLogic;
|
||||
|
@ -57,6 +58,7 @@ import util.MathUtils;
|
|||
import util.StringUtil;
|
||||
import util.TimeUtils;
|
||||
|
||||
import java.lang.reflect.Array;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
@ -2294,6 +2296,21 @@ public class HeroLogic{
|
|||
}
|
||||
combinedAttribute(SPlayerHeadIcon.getHeadIconMap().get(entry.getKey()).getUnlockProperty(),heroAllAttribute);
|
||||
}
|
||||
//四象心法加成
|
||||
for(Map.Entry<Integer, SixiangProfessionInfo> entry : user.getHeroManager().getSixiangDataMap().entrySet()){
|
||||
if (scHero.getProfession()!=entry.getKey()) {
|
||||
continue;
|
||||
}
|
||||
Map<Integer,Integer>propertyMap=entry.getValue().propertyMap;
|
||||
int[][] propArr = ItemUtil.mapToArray(propertyMap);
|
||||
combinedAttribute(propArr,heroAllAttribute);
|
||||
if (user.getHeroManager().getSixiangPropUpMap().containsKey(entry.getKey())) {
|
||||
Map<Integer,Integer>upStarPropertyMap=user.getHeroManager().getSixiangPropUpMap().get(entry.getKey());
|
||||
int[][]upStarProp=ItemUtil.mapToArray(upStarPropertyMap);
|
||||
combinedAttribute(upStarProp,heroAllAttribute);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//装备总战力评分
|
||||
int equipForce=0;
|
||||
|
@ -2741,7 +2758,9 @@ public class HeroLogic{
|
|||
}
|
||||
force+=sEquipConfig.getScore();
|
||||
}
|
||||
return force + heroAllAttribute.get(HeroAttributeEnum.EquipForce.getPropertyId());
|
||||
long l = force + heroAllAttribute.get(HeroAttributeEnum.EquipForce.getPropertyId());
|
||||
LOGGER.info("战力::::::{}",l);
|
||||
return l;
|
||||
}
|
||||
|
||||
|
||||
|
@ -5160,4 +5179,5 @@ public class HeroLogic{
|
|||
MessageUtil.sendIndicationMessage(session,1, MessageTypeProto.MessageType.PurpleMansionSealIndication_VALUE,build2,true);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#server info
|
||||
server.id = 10161
|
||||
server.id = 10050
|
||||
server.openTime = 20190101000101
|
||||
server.num = 1
|
||||
server.debug = true
|
||||
|
@ -9,24 +9,24 @@ server.sendlog37 = true
|
|||
server.channel = test
|
||||
server.threads = 8
|
||||
# redis config
|
||||
# Redis数据库索引(默认为0)
|
||||
# Redis<EFBFBD><EFBFBD><EFBFBD>ݿ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĭ<EFBFBD><EFBFBD>Ϊ0<EFBFBD><EFBFBD>
|
||||
spring.redis.database=0
|
||||
#spring.redis.database=2
|
||||
# Redis服务器地址
|
||||
# Redis<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ַ
|
||||
spring.redis.host=60.1.1.21
|
||||
# Redis服务器连接端口
|
||||
# Redis<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ӷ˿<EFBFBD>
|
||||
spring.redis.port=6379
|
||||
# Redis服务器连接密码(默认为空)
|
||||
# Redis<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>루Ĭ<EFBFBD><EFBFBD>Ϊ<EFBFBD>գ<EFBFBD>
|
||||
spring.redis.password=
|
||||
# 连接池最大连接数(使用负值表示没有限制)
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD>ø<EFBFBD>ֵ<EFBFBD><EFBFBD>ʾû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƣ<EFBFBD>
|
||||
spring.redis.pool.max-active=8
|
||||
# 连接池最大阻塞等待时间(使用负值表示没有限制)
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȴ<EFBFBD>ʱ<EFBFBD>䣨ʹ<EFBFBD>ø<EFBFBD>ֵ<EFBFBD><EFBFBD>ʾû<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƣ<EFBFBD>
|
||||
spring.redis.pool.max-wait=-1
|
||||
# 连接池中的最大空闲连接
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD><EFBFBD>е<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
spring.redis.pool.max-idle=8
|
||||
# 连接池中的最小空闲连接
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD><EFBFBD>е<EFBFBD><EFBFBD><EFBFBD>С<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
spring.redis.pool.min-idle=0
|
||||
# 连接超时时间(毫秒)
|
||||
# <EFBFBD><EFBFBD><EFBFBD>ӳ<EFBFBD>ʱʱ<EFBFBD>䣨<EFBFBD><EFBFBD><EFBFBD>룩
|
||||
spring.redis.timeout=0
|
||||
|
||||
spring.redis.expireTime = -1
|
||||
|
@ -35,7 +35,7 @@ spring.redis.expireTime = -1
|
|||
#spring.data.mongodb.uri = mongodb://mongouser:ysj#2017#ljsd@111.231.54.96:27017/ysj_wx_1
|
||||
#spring.data.mongodb2.uri = mongodb://mongouser:ysj#2017#ljsd@111.231.54.96:27017/develop_ysj_wx_1
|
||||
#mongodb2 develop
|
||||
spring.data.mongodb.uri = mongodb://60.1.1.14:27017/jieling_10161
|
||||
spring.data.mongodb.uri = mongodb://60.1.1.14:27017/jieling_10050
|
||||
spring.data.mongodbcore.uri = mongodb://60.1.1.14:27017/jl_core
|
||||
#spring.data.mongodb.uri = mongodb://60.1.1.14:27017/jieling_10212
|
||||
mongodb.options.maxWaitTime = 120000
|
||||
|
@ -64,7 +64,7 @@ netty.allTimeout=35
|
|||
|
||||
|
||||
#core
|
||||
services.core.ip=60.1.1.163
|
||||
services.core.ip=60.1.1.50
|
||||
services.core.port=7900
|
||||
services.core.area=1000
|
||||
services.core.id=1
|
||||
|
|
|
@ -0,0 +1,100 @@
|
|||
package config;
|
||||
|
||||
import manager.STableManager;
|
||||
import manager.Table;
|
||||
import rpc.protocols.CommonProto;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Table(name ="FourQuadrantConfig")
|
||||
public class SFourQuadrantConfig implements BaseConfig {
|
||||
|
||||
private int id;
|
||||
|
||||
private int star;
|
||||
|
||||
private int[][] propLimit;
|
||||
private int[][] propLvup;
|
||||
|
||||
private int[][] lvupCost;
|
||||
|
||||
private int[][] rankupCost;
|
||||
|
||||
private int[][] propStar;
|
||||
|
||||
private int[][] propResonance;
|
||||
|
||||
private int[] skill;
|
||||
|
||||
private int randomTimes;
|
||||
|
||||
private int rankupPercent;
|
||||
|
||||
private int xiuxianLimit;
|
||||
|
||||
public static Map<Integer, SFourQuadrantConfig> sFourQuadrantConfigMap;
|
||||
|
||||
public static Map<Integer, SFourQuadrantConfig> configByStrtMap;
|
||||
|
||||
|
||||
@Override
|
||||
public void init() throws Exception {
|
||||
configByStrtMap=new HashMap<>();
|
||||
sFourQuadrantConfigMap = STableManager.getConfig(SFourQuadrantConfig.class);
|
||||
for (SFourQuadrantConfig value : sFourQuadrantConfigMap.values()) {
|
||||
configByStrtMap.put(value.star,value);
|
||||
}
|
||||
}
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public int getStar() {
|
||||
return star;
|
||||
}
|
||||
|
||||
public int[][] getPropLimit() {
|
||||
return propLimit;
|
||||
}
|
||||
|
||||
public int[][] getPropLvup() {
|
||||
return propLvup;
|
||||
}
|
||||
|
||||
public int[][] getLvupCost() {
|
||||
return lvupCost;
|
||||
}
|
||||
|
||||
public int[][] getRankupCost() {
|
||||
return rankupCost;
|
||||
}
|
||||
|
||||
public int[][] getPropStar() {
|
||||
return propStar;
|
||||
}
|
||||
|
||||
public int[][] getPropResonance() {
|
||||
return propResonance;
|
||||
}
|
||||
|
||||
public int[] getSkill() {
|
||||
return skill;
|
||||
}
|
||||
|
||||
public int getRandomTimes() {
|
||||
return randomTimes;
|
||||
}
|
||||
|
||||
public int getRankupPercent() {
|
||||
return rankupPercent;
|
||||
}
|
||||
|
||||
public int getXiuxianLimit() {
|
||||
return xiuxianLimit;
|
||||
}
|
||||
}
|
||||
|
|
@ -8,7 +8,7 @@ import java.util.*;
|
|||
|
||||
public class ExcelUtils {
|
||||
private static boolean isWrite = true;
|
||||
private static String excelPath ="E:\\work\\data_execl\\master_en\\base_data\\"; //excel 文件
|
||||
private static String excelPath ="D:\\jieling_data\\master_zh_c\\base_data\\"; //excel 文件
|
||||
// private static String excelPath ="D:/excel/0.94/data_execl/Map_data/"; //excel 文件
|
||||
private static String path = "conf/server/";
|
||||
private static Set<String> oldFileNames = new HashSet<>();
|
||||
|
|
Loading…
Reference in New Issue