BIReason修改,副本难度暂存修改
parent
1d17e074d1
commit
232159bf22
|
|
@ -55,6 +55,10 @@ public interface BIReason {
|
|||
|
||||
int TOWER_SWEEP_REWARD = 34;//爬塔扫荡奖励
|
||||
|
||||
int WORK_SHOP_TECHNOGY_RESET_DROP =35 ;
|
||||
|
||||
int TAKE_STAR_REWARD = 36;
|
||||
|
||||
//道具消耗原因 1000开头
|
||||
int ADVENTURE_UPLEVEL_CONSUME = 1000; //秘境升级
|
||||
int SECRETBOX_CONSUME = 1001; //秘盒抽卡
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
package com.ljsd.jieling.handler.map;
|
||||
|
||||
import ch.qos.logback.core.util.TimeUtil;
|
||||
import com.googlecode.protobuf.format.JsonFormat;
|
||||
import com.ljsd.jieling.config.*;
|
||||
import com.ljsd.jieling.core.VipPrivilegeType;
|
||||
|
|
@ -1588,6 +1587,13 @@ public class MapLogic {
|
|||
.build();
|
||||
builder.setTowerCopyInfo(towerCopyInfo);
|
||||
builder.addAllPlayedGenMapId(mapManager.getPlayGenMaps());
|
||||
|
||||
for(Map.Entry<Integer,Integer> entry:mapManager.getDifficultyOptions().entrySet()){
|
||||
MapInfoProto.DifficultMapOption.Builder difficultMapOption = MapInfoProto.DifficultMapOption.newBuilder();
|
||||
difficultMapOption.setId(entry.getKey());
|
||||
difficultMapOption.setMapdifficulty(entry.getValue());
|
||||
builder.addDifficultMapOptions(difficultMapOption);
|
||||
}
|
||||
// LOGGER.info("关卡信息{}",towerCopyInfo.toString());
|
||||
MessageUtil.sendMessage(iSession, 1, msgId, builder.build(), true);
|
||||
}
|
||||
|
|
@ -2422,7 +2428,7 @@ public class MapLogic {
|
|||
return;
|
||||
}
|
||||
|
||||
CommonProto.Drop.Builder drop = ItemUtil.drop(user, sChallengeStarBox.getReward(), 1);
|
||||
CommonProto.Drop.Builder drop = ItemUtil.drop(user, sChallengeStarBox.getReward(), BIReason.TAKE_STAR_REWARD);
|
||||
mapManager.setStarReward(id);
|
||||
MapInfoProto.FbStarRewardResponse.Builder FbStarRewardResponse = MapInfoProto.FbStarRewardResponse.newBuilder();
|
||||
FbStarRewardResponse.setFbStarReward(drop);
|
||||
|
|
@ -2432,6 +2438,7 @@ public class MapLogic {
|
|||
}
|
||||
public void recordDifficultMap(ISession session ,int fbId,int difficultyId,MessageTypeProto.MessageType messageType) throws Exception {
|
||||
MapManager mapManager = UserManager.getUser(session.getUid()).getMapManager();
|
||||
|
||||
if(mapManager.getDifficultyOptions()!=null){
|
||||
if(fbId!=0&&difficultyId!=0){
|
||||
mapManager.addDiffcultyOptions(fbId,difficultyId);
|
||||
|
|
|
|||
|
|
@ -18,9 +18,8 @@ public class DifficultRecordHandler extends BaseHandler {
|
|||
@Override
|
||||
public void process(ISession iSession, PacketNetData netData) throws Exception {
|
||||
byte[] message = netData.parseClientProtoNetData();
|
||||
MapInfoProto.DifficultMapOption difficultMapOption = MapInfoProto.DifficultMapOption.parseFrom(message);
|
||||
difficultMapOption.getId();
|
||||
difficultMapOption.getMapdifficulty();
|
||||
MapLogic.getInstance().recordDifficultMap(iSession,difficultMapOption.getId(),difficultMapOption.getMapdifficulty(),MessageTypeProto.MessageType.DIFFICULT_MAP_OPTION_RECORD_RESPONSE);
|
||||
MapInfoProto.DifficultMapRequest difficultMapRequest = MapInfoProto.DifficultMapRequest.parseFrom(message);
|
||||
MapInfoProto.DifficultMapOption mapInfo = difficultMapRequest.getMapInfo();
|
||||
MapLogic.getInstance().recordDifficultMap(iSession,mapInfo.getId(),mapInfo.getMapdifficulty(),MessageTypeProto.MessageType.DIFFICULT_MAP_OPTION_RECORD_RESPONSE);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ public class WorkShopLogic {
|
|||
HeroLogic.getInstance().combinedAttribute(willReturn,returnMap);
|
||||
}
|
||||
workShopController.resetTech(profession);
|
||||
CommonProto.Drop.Builder builder = ItemUtil.dropMap(user, returnMap, 1);
|
||||
CommonProto.Drop.Builder builder = ItemUtil.dropMap(user, returnMap, BIReason.WORK_SHOP_TECHNOGY_RESET_DROP);
|
||||
PlayerInfoProto.WorkTechnologyResetResponse build = PlayerInfoProto.WorkTechnologyResetResponse.newBuilder().setDrop(builder).build();
|
||||
MessageUtil.sendMessage(session,1,msgId,build,true);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue