关卡验证

back_recharge
duhui 2023-02-08 15:17:49 +08:00
parent 063674c2f2
commit 80b61b2fb1
1 changed files with 4 additions and 2 deletions

View File

@ -12,6 +12,7 @@ import com.ljsd.jieling.logic.store.newRechargeInfo.rechargeHandler.RechargeHand
import com.ljsd.jieling.network.session.ISession;
import com.ljsd.jieling.util.ItemUtil;
import config.SGMMaster;
import config.SMainLevelConfig;
import config.SRechargeCommodityNewConfig;
import org.springframework.stereotype.Component;
import rpc.protocols.MessageTypeProto;
@ -85,8 +86,9 @@ public class GmBuyGoodHandler extends BaseHandler<PlayerInfoProto.GmBuyGoodReque
}
break;
case 2://关卡id
int fightId = user.getMainLevelManager().getFightId();
if (fightId < value[1]){
SMainLevelConfig playerMain = SMainLevelConfig.fightPreMap.get(user.getMainLevelManager().getFightId());
SMainLevelConfig valueMain = SMainLevelConfig.fightPreMap.get(value[1]);
if (playerMain.getVirtureId() < valueMain.getVirtureId()){
throw new ErrorCodeException(ErrorCode.BEFORE_CONDITION_NOT);
}
break;