diff --git a/src/server/game/mod/order/order_func.go b/src/server/game/mod/order/order_func.go index 3e685608..c159f64c 100644 --- a/src/server/game/mod/order/order_func.go +++ b/src/server/game/mod/order/order_func.go @@ -90,10 +90,10 @@ type orderConfigInfo struct { } // 根据上一个订单难度和系数 生成订单难度 -func getOrderDiffRand(Lv, Diff int) map[int]int { +func getOrderDiffRand(lv, diff int) map[int]int { var d map[int]int - if Lv < 24 { - switch Diff { + if lv < 24 { + switch diff { case DIFF_MID: d = map[int]int{ DIFF_LOW: 50, @@ -107,7 +107,7 @@ func getOrderDiffRand(Lv, Diff int) map[int]int { } return d } - switch Diff { + switch diff { case DIFF_MID: d = map[int]int{ DIFF_LOW: 21, @@ -131,7 +131,7 @@ func getOrderDiffRand(Lv, Diff int) map[int]int { } func getChessByDiff(lv, diff, cType int) (int, int, int) { - if cType == Common_type { + if cType == Common_type || cType == Super_type { switch diff { case DIFF_MID: return 100, 600, GoUtil.RandMap(map[int]int{1: 50, 2: 50}) @@ -430,8 +430,9 @@ func randSuperOrderChess(o *OrderMod, lv int, emit []int, energyMul, orderDiff i return nil, DIFF_LOW, err } chessNum := GoUtil.RandMap(randChessNum) - chessDiff := getChessDiff(chessNum, orderDiff) - return buildMergeListFromDiff(o, chessDiff, emit, energyMul, orderDiff) + minEnergy, maxEnergy, _ := getChessByDiff(lv, orderDiff, Super_type) + mergeList := getChessFromPoolByEnergy(o, minEnergy, maxEnergy, chessNum, emit, energyMul, orderDiff, Super_type) + return mergeList, orderDiff, nil } // 随机生成订单棋子 @@ -446,8 +447,8 @@ func randOrderChess(o *OrderMod, lv int, emit []int, energyMul, orderType int) ( o.NextDiff = 0 } //获取订单体力范围和棋子数量 - MinEnergy, MaxEnergy, ChessNum := getChessByDiff(lv, orderDiff, orderType) - mergeList := getChessFromPoolByEnergy(o, MinEnergy, MaxEnergy, ChessNum, emit, energyMul, orderDiff, orderType) + minEnergy, maxEnergy, chessNum := getChessByDiff(lv, orderDiff, orderType) + mergeList := getChessFromPoolByEnergy(o, minEnergy, maxEnergy, chessNum, emit, energyMul, orderDiff, orderType) return mergeList, orderDiff, nil }