back_recharge
parent
ae9a7bc1ee
commit
b07a7f5673
|
|
@ -6,7 +6,7 @@ import com.ljsd.jieling.handler.map.MapManager;
|
|||
import com.ljsd.jieling.handler.map.TemporaryItems;
|
||||
import com.ljsd.jieling.logic.dao.*;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import com.ljsd.jieling.logic.item.ItemLogic;
|
||||
import com.ljsd.jieling.logic.fight.CombatLogic;
|
||||
import com.ljsd.jieling.protocols.CommonProto;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
|
@ -486,10 +486,11 @@ public class ItemUtil {
|
|||
}
|
||||
}
|
||||
|
||||
public static boolean checkCost(User user, Map<Integer, Integer> itemMap) {
|
||||
public static boolean checkCost(User user, Map<Integer, Integer> itemMap) throws Exception {
|
||||
if (itemMap == null) {
|
||||
return true;
|
||||
}
|
||||
CombatLogic.getInstance().calAdvenrureReward(user,true,0);
|
||||
TemporaryItems temporaryItems = user.getMapManager().getTemporaryItems();
|
||||
Map<Integer, Item> temporaryItemList = new HashMap<>();
|
||||
if (temporaryItems != null) {
|
||||
|
|
@ -611,7 +612,7 @@ public class ItemUtil {
|
|||
* @param costItems
|
||||
* @return
|
||||
*/
|
||||
public static boolean fightItemCost(User user,int[][] costItems) {
|
||||
public static boolean fightItemCost(User user,int[][] costItems) throws Exception {
|
||||
Map<Integer, Integer> itemMap = new HashMap<>();
|
||||
selectCost(costItems,itemMap);
|
||||
boolean result = checkCost(user, itemMap);
|
||||
|
|
|
|||
Loading…
Reference in New Issue