Merge branch 'master_online_hw' into master_test_hw

# Conflicts:
#	serverlogic/src/main/java/com/ljsd/jieling/logic/rank/rankImpl/ForceCurrRank.java
#	serverlogic/src/main/java/com/ljsd/jieling/logic/store/BuyGoodsLogic.java
back_recharge
lvxinran 2020-09-25 14:31:42 +08:00
commit 805ac98057
7 changed files with 51 additions and 30 deletions

View File

@ -2857,6 +2857,7 @@ public class MapLogic {
trialInfo.setKillCount(0);
trialInfo.setBombUseTimes(0);
trialInfo.setTowerReceivedReward(new HashSet<>());
trialInfo.setMonsterHp(new HashMap<>());
if(mapManager.getCurMapId()!=0){
if(MapLogic.getInstance().getMap(user) instanceof TowerMap){
resetMapInfo(user,false);

View File

@ -415,7 +415,7 @@ public class ExpeditionLogic {
if (typeArr.length != 2) {
continue;
}
Set<ExpeditionNodeInfo> tempnode = getNode(sExpeditionFloorConfig, typeArr[0], typeArr[1]);
Set<ExpeditionNodeInfo> tempnode = getNode(sExpeditionFloorConfig, typeArr[0], Math.min(typeArr[1],indexList.size()));
tempnode.forEach(nodeInfo -> {
if(indexList.size()==0){
@ -1022,7 +1022,7 @@ public class ExpeditionLogic {
WorldTreasureReward worldTreasureReward = user.getExpeditionManager().getWorldTreasureReward();
Expedition.ExpeditionTreasureInfoResponse.Builder response = Expedition.ExpeditionTreasureInfoResponse.newBuilder();
if(worldTreasureReward.getFirstStartTime()!=0&&worldTreasureReward.getFirstStartTime()<=TimeUtils.nowInt()){
if(worldTreasureReward.getFirstStartTime()!=0&&worldTreasureReward.getFirstStartTime()<=TimeUtils.nowInt()&&worldTreasureReward.getCreateTime()>TimeUtils.now()/1000){
Map<Integer, Integer> rewardStatusMap = worldTreasureReward.getRewardStatusMap();
WorldBossTreasureStaticConfig worldBossTreasureStaticConfig = STableManager.getFigureConfig(WorldBossTreasureStaticConfig.class);
Set<SWorldBossTreasureConfig> sWorldBossTreasureConfigs = worldBossTreasureStaticConfig.getIdsByPeriods().get(worldTreasureReward.getRound());

View File

@ -650,8 +650,9 @@ public class GuildLogic {
throw new ErrorCodeException(ErrorCode.FAMILY_NOT_KICK_IN_WAR);
}
User targetUser = UserManager.getUser(targetUid);
//TODO lock check
OnUserLeveFamily(user);
OnUserLeveFamily(targetUser);
Family.KickOutIndication kickIndication = Family.KickOutIndication.newBuilder().setUid(targetUid).build();
sendIndicationToMember(guildInfo,MessageTypeProto.MessageType.FAMILY_KICK_INDICATION,kickIndication);
@ -663,7 +664,6 @@ public class GuildLogic {
if(guildInfo.getDefendInfo().containsKey((targetUid))){
guildInfo.removeDefendInfo(targetUid);
}
User targetUser = UserManager.getUser(targetUid);
targetUser.getPlayerInfoManager().setGuildId(0);
targetUser.getGuildMyInfo().clearOfLevelGuild();
addGuildLog(guildInfo.getId(),GuildDef.Log.KICK,targetUser.getPlayerInfoManager().getNickName());

View File

@ -57,7 +57,6 @@ public class ForceCurrRank extends AbstractRank implements IEventHandler{
private void run(){
Queue<UserMainTeamForceEvent> infoQueue = ForceCurrRank.infoQueue;
// LOGGER.info("实时战力排行,队列长度{}",infoQueue.size());
if(infoQueue.isEmpty()){
return;
}

View File

@ -856,35 +856,48 @@ public class BuyGoodsLogic {
}
}
if(SGlobalActivity.sRechargeId2ActivityId.containsKey(goodsId)){
Integer integer = SGlobalActivity.sRechargeId2ActivityId.get(goodsId);
Set<Integer> ids =getOpenActivity(user,6);
if(!ids.contains(integer)){
if(sRechargeCommodityConfig.getType()==GiftGoodsType.SKY_TREASURE){
WorldTreasureReward worldTreasureReward = user.getExpeditionManager().getWorldTreasureReward();
if(worldTreasureReward==null||worldTreasureReward.getIsBuy()==1||worldTreasureReward.getFirstStartTime()>(int)(TimeUtils.now()/1000)){
continue;
}
}
//临时处理 商品控制需要重新处理
if(goodsId>=314&&goodsId<=355)
{
continue;
}
//临时处理 商品控制需要重新处理
if(goodsId>=300&&goodsId<=306)
{
Set<Integer> ids =getOpenActivity(user,20001);
if(ids.size()==0){
continue;
}
}
//临时处理 商品控制需要重新处理
if(goodsId>=300&&goodsId<=317)
{
Set<Integer> ids =getOpenActivity(user,20002);
if(ids.size()==0){
if(SGlobalActivity.sRechargeId2ActivityId.containsKey(goodsId)){
Integer integer = SGlobalActivity.sRechargeId2ActivityId.get(goodsId);
// Set<Integer> ids =getOpenActivity(user,6);
ActivityManager activityManager = user.getActivityManager();
Map<Integer, ActivityMission> activityMissionMap = activityManager.getActivityMissionMap();
if(!activityMissionMap.keySet().contains(integer)){
continue;
}
}
// //临时处理 商品控制需要重新处理
// if(goodsId>=314&&goodsId<=355)
// {
// continue;
// }
// //临时处理 商品控制需要重新处理
// if(goodsId>=300&&goodsId<=306)
// {
// Set<Integer> ids =getOpenActivity(user,20001);
// if(ids.size()==0){
// continue;
// }
// }
// //临时处理 商品控制需要重新处理
// if(goodsId>=300&&goodsId<=317)
// {
// Set<Integer> ids =getOpenActivity(user,20002);
// if(ids.size()==0){
// continue;
// }
// }
Integer buyTimes = buyGoodsTimes.get(goodsId);
if(buyTimes ==null){
@ -909,12 +922,16 @@ public class BuyGoodsLogic {
}
long startTime=0;
long endTime=0;
int dybuytime = 0;
RechargeResult rechargeResult = getStartTime( user ,rechargeInfo, sRechargeCommodityConfig);
if(!rechargeResult.isTag()){
if(sRechargeCommodityConfig.getType() == 4){
dybuytime = rechargeInfo.getDyGoodsCanBuyTimes().getOrDefault(goodsId,-1);
if(0==dybuytime||-1==dybuytime){
continue;
}
} else if(!rechargeResult.isTag()){
continue;
}
startTime = rechargeResult.getStartTime();

View File

@ -712,6 +712,9 @@ public class ItemUtil {
if (levelConfig != null) {
//需要先确定下每级真实需要的经验,与客户端实现方式同步,认为表里填的升到下一级所需经验是前边各级经验总和
int[][] integral = levelConfig.getIntegral();
if(integral==null||integral.length<=0||integral[0].length<=0){
return;
}
STreasureSunlongConfig lastLevelConfig = STreasureSunlongConfig.levelTreasureConfigMap.get(activity.getId()).get(levelConfig.getLevel() - 1);
int[][] costItems = integral;
if (lastLevelConfig != null) {

View File

@ -78,6 +78,7 @@ public class STableManager {
//TODO 应该说有数据都加载后统一替换 但是现在部分静态数据遗留在cfg类中 只能一个一个加载
if(!tableName.equals("Map"))
loadInCache(cls);
LOGGER.info("hotfix table"+tableName);
}
Object stable = cls.newInstance();