礼物升星
parent
e607cb442d
commit
da13ea697f
|
@ -29,8 +29,8 @@ public class Item extends MongoBase {
|
|||
}
|
||||
|
||||
public void setItemId(int itemId){
|
||||
updateString("itemId", itemId);
|
||||
this.itemId = itemId;
|
||||
updateString("itemId", itemId);
|
||||
}
|
||||
|
||||
public long getItemNum() {
|
||||
|
@ -38,8 +38,8 @@ public class Item extends MongoBase {
|
|||
}
|
||||
|
||||
public void setItemNum(long itemNum){
|
||||
updateString("itemNum", itemNum);
|
||||
this.itemNum = itemNum;
|
||||
updateString("itemNum", itemNum);
|
||||
}
|
||||
|
||||
public int getEndingTime() {
|
||||
|
@ -47,7 +47,7 @@ public class Item extends MongoBase {
|
|||
}
|
||||
|
||||
public void setEndingTime(int endingTime){
|
||||
updateString("endingTime", endingTime);
|
||||
this.endingTime = endingTime;
|
||||
updateString("endingTime", endingTime);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,8 +48,6 @@ public class ItemManager extends MongoBase {
|
|||
updateString("equipBookEnabled", equipBookEnabled);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public ItemManager() {
|
||||
this.setRootCollection(User._COLLECTION_NAME);
|
||||
}
|
||||
|
|
|
@ -637,8 +637,9 @@ public class EquipLogic {
|
|||
if (!cost){
|
||||
throw new ErrorCodeException(ErrorCode.ITEM_NOT_ENOUGH);
|
||||
}
|
||||
|
||||
CommonProto.Drop.Builder drop = ItemUtil.drop(user, new int[][]{{giftId, 1}}, BIReason.GIFT_UP_STAR_GET);
|
||||
ItemUtil.itemCost(user, costList, BIReason.GIFT_EQUIP_UP_COST, 0);
|
||||
ItemUtil.itemCost(user, costList, BIReason.GIFT_UP_STAR_COST, 0);
|
||||
HeroInfoProto.GiftEquipUpStarResponse.Builder builder = HeroInfoProto.GiftEquipUpStarResponse.newBuilder().setDrop(drop);
|
||||
MessageUtil.sendMessage(iSession, 1, MessageTypeProto.MessageType.GiftEquipUpStarResponse_VALUE, builder.build(), true);
|
||||
}
|
||||
|
|
|
@ -1102,7 +1102,7 @@ public class ItemUtil {
|
|||
switch (itemId){
|
||||
case ReportUtil.COIN_ID:
|
||||
if(type==1){
|
||||
item =ReportEventEnum.GET_COINS;
|
||||
item = ReportEventEnum.GET_COINS;
|
||||
}else{
|
||||
item = ReportEventEnum.COST_COINS;
|
||||
}
|
||||
|
@ -1122,7 +1122,8 @@ public class ItemUtil {
|
|||
}
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
item = ReportEventEnum.GET_ITEM;
|
||||
break;
|
||||
}
|
||||
|
||||
ReportUtil.onReportEvent(user,item.getType(),itemNum,String.valueOf(reason));
|
||||
|
|
Loading…
Reference in New Issue