原有罗浮货币登录时转化为逐胜徽章
parent
87f073bb89
commit
847efbe252
|
@ -21,6 +21,8 @@ public interface GlobalsDef {
|
|||
int addReason = 0;
|
||||
int subReason = 1;
|
||||
|
||||
int LUOFUZHENG_MONEY = 1207; // 罗浮争锋道具
|
||||
|
||||
int BATTLING = -1;
|
||||
|
||||
int BREAK_TYPE = 1; //1突破
|
||||
|
|
|
@ -177,6 +177,7 @@ public interface BIReason {
|
|||
int ENDLESS_TREASURE_REWARD = 100;//无尽秘宝获得
|
||||
int ENDLESS_RESET = 101;//无尽重置获得
|
||||
int HERO_RETURN = 102;// 神将回退
|
||||
int ITEM_RETURN = 103;// 罗浮晶石转化逐胜徽章
|
||||
|
||||
int ADVENTURE_UPLEVEL_CONSUME = 1000;//秘境升级
|
||||
int SECRETBOX_CONSUME = 1001;//秘盒抽卡
|
||||
|
|
|
@ -860,9 +860,14 @@ public class BuyGoodsNewLogic {
|
|||
|
||||
public static CommonProto.GiftGoodsInfo buildGoodsInfo(AbstractWelfareBag bag){
|
||||
SRechargeCommodityNewConfig configById = SRechargeCommodityNewConfig.getConfigById(bag.getModId());
|
||||
// 配置表里已删除的礼包 删除
|
||||
if (configById == null) {
|
||||
return null;
|
||||
}
|
||||
// 礼包类型已更改的删除
|
||||
if (bag.getType() != configById.getOtype()) {
|
||||
return null;
|
||||
}
|
||||
CommonProto.GiftGoodsInfo.Builder builder = CommonProto.GiftGoodsInfo.newBuilder();
|
||||
builder.setGoodsId(bag.getModId());
|
||||
builder.setBuyTimes(bag.getBuyTimes());
|
||||
|
|
|
@ -1162,6 +1162,19 @@ public class ItemUtil {
|
|||
ItemManager itemManager = user.getItemManager();
|
||||
Map<Integer, Item> itemMap = itemManager.getItemMap();
|
||||
boolean needUpdateHero = true;
|
||||
Item item1 = itemMap.get(GlobalsDef.LUOFUZHENG_MONEY);
|
||||
if (item1 != null && item1.getItemNum() > 0) {
|
||||
|
||||
String title = SErrorCodeEerverConfig.getI18NMessage("msarenashopchange_mile_title");
|
||||
String content = SErrorCodeEerverConfig.getI18NMessageNeedConvert("msarenashopchange_mile_txt", new Object[]{item1.getItemNum(), item1.getItemNum()}, new int[]{0,0}, "#");
|
||||
MailLogic.getInstance().sendMail(user.getId(), title, content, "24#" + item1.getItemNum(), TimeUtils.nowInt(), Global.MAIL_EFFECTIVE_TIME);
|
||||
|
||||
Map<Integer, Integer> map = new HashMap<>(1);
|
||||
map.put(item1.getItemId(), (int) item1.getItemNum());
|
||||
useItem(user, map, BIReason.ITEM_RETURN, 0);
|
||||
itemMap.remove(GlobalsDef.LUOFUZHENG_MONEY);
|
||||
|
||||
}
|
||||
if (itemMap.size() !=0 ){
|
||||
for (Map.Entry<Integer, Item> entry :itemMap.entrySet()){
|
||||
|
||||
|
|
Loading…
Reference in New Issue