| | |
| | | { |
| | | if (null == battleField) |
| | | return; |
| | | if (!FuncOpen.Instance.IsFuncOpen(BattleManager.Instance.passFuncId, true)) |
| | | return; |
| | | int passRound = BattleManager.Instance.passRound; |
| | | int nowRound = battleField.round; |
| | | if (nowRound <= passRound) |
| | | { |
| | | SysNotifyMgr.Instance.ShowTip("BattlePass", passRound - nowRound); |
| | | return; |
| | | } |
| | | battleField.ForceFinish(); |
| | | } |
| | | |
| | |
| | | { |
| | | if (null == battleField) |
| | | return; |
| | | |
| | | // 计算下一个速度档位的索引 |
| | | int nextSpeedIndex = (BattleManager.Instance.speedIndex + 1) % BattleManager.Instance.speedGear.Length; |
| | | // 检查下一档倍速功能是否开启 |
| | | int nextSpeedFuncId = BattleManager.Instance.speedIndexfuncIdArr[nextSpeedIndex]; |
| | | if (!FuncOpen.Instance.IsFuncOpen(nextSpeedFuncId, true)) |
| | | return; |
| | | BattleManager.Instance.speedIndex = (BattleManager.Instance.speedIndex + 1) % BattleManager.Instance.speedGear.Length; |
| | | battleField.SetSpeedRatio(BattleManager.Instance.speedGear[BattleManager.Instance.speedIndex]); |
| | | |
| | | if (textSpeed != null) |
| | | textSpeed.text = (BattleManager.Instance.speedIndex + 1).ToString(); |
| | | } |