Merge branch 'master_huanxiang' into master_ob2
commit
90c4c479f4
|
|
@ -75,17 +75,17 @@ public class GetEndlessHeroInfoListHandler extends BaseHandler<HeroInfoProto.Get
|
||||||
|
|
||||||
}
|
}
|
||||||
private void checkNewEndlessHero(User user){
|
private void checkNewEndlessHero(User user){
|
||||||
Set<Integer> hadEndlessHero = new HashSet<>();
|
// Set<Integer> hadEndlessHero = new HashSet<>();
|
||||||
HeroManager heroManager = user.getHeroManager();
|
// HeroManager heroManager = user.getHeroManager();
|
||||||
if(heroManager.getEndlessHeroInfo().size()==0||heroManager.getEndlessHeroInfo().size()< STableManager.getConfig(SEndlessHeroProp.class).size()){
|
// if(heroManager.getEndlessHeroInfo().size()==0||heroManager.getEndlessHeroInfo().size()< STableManager.getConfig(SEndlessHeroProp.class).size()){
|
||||||
heroManager.getEndlessHeroInfo().forEach((k,v)->hadEndlessHero.add(v.getTemplateId()));
|
// heroManager.getEndlessHeroInfo().forEach((k,v)->hadEndlessHero.add(v.getTemplateId()));
|
||||||
for(Map.Entry<Integer,SEndlessHeroProp> entry:STableManager.getConfig(SEndlessHeroProp.class).entrySet()){
|
// for(Map.Entry<Integer,SEndlessHeroProp> entry:STableManager.getConfig(SEndlessHeroProp.class).entrySet()){
|
||||||
if(hadEndlessHero.contains(entry.getKey())){
|
// if(hadEndlessHero.contains(entry.getKey())){
|
||||||
continue;
|
// continue;
|
||||||
}
|
// }
|
||||||
Hero hero = new Hero(entry.getKey(), user.getId());
|
// Hero hero = new Hero(entry.getKey(), user.getId());
|
||||||
heroManager.updateEndlessHeroInfo(hero.getId(),hero);
|
// heroManager.updateEndlessHeroInfo(hero.getId(),hero);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -108,7 +108,7 @@ public class BuyGoodsNewLogic {
|
||||||
if (sRechargeCommodityConfig == null){
|
if (sRechargeCommodityConfig == null){
|
||||||
throw new ErrorCodeException(ErrorCode.CFG_NULL);
|
throw new ErrorCodeException(ErrorCode.CFG_NULL);
|
||||||
}
|
}
|
||||||
int price = (int)sRechargeCommodityConfig.getPrice();
|
int price = (int)sRechargeCommodityConfig.getPrice()*100;
|
||||||
if (!GameApplication.serverProperties.isDebug() && price != 0){
|
if (!GameApplication.serverProperties.isDebug() && price != 0){
|
||||||
LOGGER.error("debug关闭状态,线上环境,不允许测试支付购买!");
|
LOGGER.error("debug关闭状态,线上环境,不允许测试支付购买!");
|
||||||
return;
|
return;
|
||||||
|
|
@ -128,7 +128,7 @@ public class BuyGoodsNewLogic {
|
||||||
if(sRechargeCommodityConfig == null){
|
if(sRechargeCommodityConfig == null){
|
||||||
throw new ErrorCodeException(ErrorCode.CFG_NULL);
|
throw new ErrorCodeException(ErrorCode.CFG_NULL);
|
||||||
}
|
}
|
||||||
int price = (int)sRechargeCommodityConfig.getPrice();
|
int price = (int)sRechargeCommodityConfig.getPrice()*100;
|
||||||
sendGoods(iSession.getUid(), String.valueOf(goodsId), "", vouchers_order, TimeUtils.now(), price);
|
sendGoods(iSession.getUid(), String.valueOf(goodsId), "", vouchers_order, TimeUtils.now(), price);
|
||||||
MessageUtil.sendMessage(iSession,1, MessageTypeProto.MessageType.TEST_BUY_GIGT_GOODS_RESPONSE_VALUE,null,true);
|
MessageUtil.sendMessage(iSession,1, MessageTypeProto.MessageType.TEST_BUY_GIGT_GOODS_RESPONSE_VALUE,null,true);
|
||||||
}
|
}
|
||||||
|
|
@ -209,7 +209,8 @@ public class BuyGoodsNewLogic {
|
||||||
}
|
}
|
||||||
|
|
||||||
int goodsId = config.getId();
|
int goodsId = config.getId();
|
||||||
double price = config.getPrice();
|
// 支付金额用分
|
||||||
|
double price = config.getPrice()*100;
|
||||||
// int cfgType = SSpecialConfig.getIntegerValue(SSpecialConfig.EXCHANGE_FORCE_TYPE);
|
// int cfgType = SSpecialConfig.getIntegerValue(SSpecialConfig.EXCHANGE_FORCE_TYPE);
|
||||||
// double price = priceTemp==0?0: SExchangeRate.doubleIntegerHashMap.get(cfgType).get((int)priceTemp);
|
// double price = priceTemp==0?0: SExchangeRate.doubleIntegerHashMap.get(cfgType).get((int)priceTemp);
|
||||||
if(amount != price){
|
if(amount != price){
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue