五星英雄成长礼
parent
ba1cb23fb2
commit
3cdb228594
|
|
@ -37,9 +37,9 @@ public class HeroFiveStarGetEventHandler implements IEventHandler {
|
|||
rechargeInfo.addTypeBagMap(5,System.currentTimeMillis());
|
||||
|
||||
List<CommonProto.GiftGoodsInfo> goodsBagInfo = new ArrayList<>(SRechargeCommodityConfig.rechargeCommodityConfigMap.size());
|
||||
boolean change = BuyGoodsLogic.getGoodsBagInfo(user.getId(), goodsBagInfo,false);
|
||||
BuyGoodsLogic.getGoodsBagInfo(user.getId(), goodsBagInfo,false);
|
||||
ISession session = OnlineUserManager.getSessionByUid(user.getId());
|
||||
if(session!=null && change){
|
||||
if(session!=null){
|
||||
if(null!= HandlerLogicThread.current()){
|
||||
//获得多个英雄进行协议合并
|
||||
PlayerInfoProto.AllGiftGoodsIndication.Builder build = PlayerInfoProto.AllGiftGoodsIndication.newBuilder().addAllGiftGoodsInfo(goodsBagInfo);
|
||||
|
|
|
|||
|
|
@ -208,7 +208,7 @@ public class BuyGoodsLogic {
|
|||
rechargeInfo.removeTypeBagMap(tempvalue);
|
||||
}
|
||||
if (rechargeInfo.getCacheSendedTypes().containsKey(tempvalue)){
|
||||
rechargeInfo.getCacheSendedTypes().remove(temptype);
|
||||
rechargeInfo.getCacheSendedTypes().remove(tempvalue);
|
||||
}
|
||||
|
||||
List<CommonProto.GiftGoodsInfo> goodsBagInfo = new ArrayList<>(SRechargeCommodityConfig.rechargeCommodityConfigMap.size());
|
||||
|
|
@ -356,14 +356,14 @@ public class BuyGoodsLogic {
|
|||
long lasttime = rechargeInfo.getCacheSendedTypes().get(value);
|
||||
if(lasttime != startTime){
|
||||
needChange = true;
|
||||
rechargeInfo.getCacheSendedTypes().put(value, startTime);
|
||||
int diffHourTemp = (int) ((now - lasttime) / 3600 / 1000);
|
||||
if (diffHourTemp < addtime) {
|
||||
startTime =0;
|
||||
}
|
||||
rechargeInfo.getCacheSendedTypes().put(value, System.currentTimeMillis());
|
||||
}
|
||||
}else {
|
||||
rechargeInfo.getCacheSendedTypes().put(value, System.currentTimeMillis());
|
||||
rechargeInfo.getCacheSendedTypes().put(value, startTime);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue