加入公会任务
parent
af304a8d85
commit
e6e27f722c
|
@ -117,6 +117,8 @@ public class CumulationData {
|
|||
|
||||
public int takeFriendGifts;//领取好友赠礼次数
|
||||
|
||||
public int joinFamilyCount;//加入公会次数
|
||||
|
||||
public Map<Integer,Integer> especialEquipStar = new HashMap<>();//法宝升到%s星级的数量为
|
||||
|
||||
|
||||
|
|
|
@ -16,6 +16,7 @@ import com.ljsd.jieling.logic.OnlineUserManager;
|
|||
import com.ljsd.jieling.logic.dao.*;
|
||||
import com.ljsd.jieling.logic.dao.root.*;
|
||||
import com.ljsd.jieling.logic.mail.MailLogic;
|
||||
import com.ljsd.jieling.logic.mission.GameEvent;
|
||||
import com.ljsd.jieling.logic.player.PlayerLogic;
|
||||
import com.ljsd.jieling.network.session.ISession;
|
||||
import com.ljsd.jieling.protocols.CommonProto;
|
||||
|
@ -502,6 +503,7 @@ public class GuildLogic {
|
|||
PlayerInfoCache cache = RedisUtil.getInstence().getMapEntry(RedisKey.PLAYER_INFO_CACHE, "", String.valueOf(applyId), PlayerInfoCache.class);
|
||||
cache.setGuildPosition(GlobalsDef.MEMBER);
|
||||
RedisUtil.getInstence().putMapEntry(RedisKey.PLAYER_INFO_CACHE,"",String.valueOf(applyId),cache);
|
||||
targetUser.getUserMissionManager().onGameEvent(targetUser, GameEvent.JOIN_FAMILY);
|
||||
}catch (Exception e){
|
||||
LOGGER.error("the exception={}",e);
|
||||
}finally {
|
||||
|
|
|
@ -67,7 +67,7 @@ public enum GameEvent {
|
|||
FIND_STAR,//占星
|
||||
|
||||
TAKE_FRIEND_GIFT,//领取好友赠礼
|
||||
|
||||
JOIN_FAMILY,//加入公会次数
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -83,6 +83,7 @@ public enum MissionType {
|
|||
ESPECIAL_EQUIP(62),//拥有%s星级法宝的数量为:%s
|
||||
FIND_STAR(65),//占星
|
||||
TAKE_FRIEND_GIFT(66),//领取好友友情点
|
||||
JOIN_FAMILY(69),
|
||||
;
|
||||
|
||||
private int missionType;
|
||||
|
@ -225,6 +226,8 @@ public enum MissionType {
|
|||
return FIND_STAR;
|
||||
case 66:
|
||||
return TAKE_FRIEND_GIFT;
|
||||
case 69:
|
||||
return JOIN_FAMILY;
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -104,6 +104,7 @@ public class DataManagerDistributor {
|
|||
judges.put(MissionType.FIND_STAR,new FindStarManager());
|
||||
|
||||
judges.put(MissionType.TAKE_FRIEND_GIFT,new TakeFriendGiftTimesManager());
|
||||
judges.put(MissionType.JOIN_FAMILY,new JoinFamilyCountManager());
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
package com.ljsd.jieling.logic.mission.data;
|
||||
|
||||
import com.ljsd.jieling.logic.dao.CumulationData;
|
||||
import com.ljsd.jieling.logic.mission.MissionType;
|
||||
|
||||
/**
|
||||
* @author lvxinran
|
||||
* @date 2019/11/2
|
||||
* @discribe
|
||||
*/
|
||||
public class JoinFamilyCountManager implements BaseDataManager {
|
||||
@Override
|
||||
public CumulationData.Result updateData(CumulationData data, MissionType missionType, Object... parm) {
|
||||
data.joinFamilyCount++;
|
||||
return new CumulationData.Result(missionType);
|
||||
}
|
||||
}
|
|
@ -274,6 +274,11 @@ public class MissionEventDistributor {
|
|||
eventEnumListMap.put(GameEvent.TAKE_FRIEND_GIFT,typeList);
|
||||
eventProcessor.put(GameEvent.TAKE_FRIEND_GIFT,new CumulationDataEventProcessor());
|
||||
|
||||
typeList = new ArrayList<>();
|
||||
typeList.add(MissionType.JOIN_FAMILY);
|
||||
eventEnumListMap.put(GameEvent.JOIN_FAMILY,typeList);
|
||||
eventProcessor.put(GameEvent.JOIN_FAMILY,new CumulationDataEventProcessor());
|
||||
|
||||
}
|
||||
|
||||
private static final ThreadLocal<Map<GameMisionType, List<MissionStateChangeInfo>>> threadMissionChangeList =
|
||||
|
|
Loading…
Reference in New Issue