From b49499614dea37e975dd757d2705b0b66d94d14c Mon Sep 17 00:00:00 2001 From: LidamaoHub Date: Thu, 19 Oct 2023 00:05:18 +0800 Subject: [PATCH] Update:add todo --- packages/contracts/src/systems/BattleSystem.sol | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/contracts/src/systems/BattleSystem.sol b/packages/contracts/src/systems/BattleSystem.sol index f77f68a1..66bf12f8 100644 --- a/packages/contracts/src/systems/BattleSystem.sol +++ b/packages/contracts/src/systems/BattleSystem.sol @@ -10,6 +10,7 @@ import { GAME_CONFIG_KEY, BATTLE_CONFIG_KEY } from "../Constants.sol"; contract BattleSystem is System { function revealBattle(uint256 _battleId, bytes32 _action, uint256 _arg, bytes32 _nonce) external { // check battle + // TODO 揭示后全局event提示已经揭示(battle_id,address) BattleListData memory battle = BattleList.get(_battleId); BattleUtils.checkBattlePlayer(battle, _msgSender(), BattleState.Confirmed); @@ -37,7 +38,9 @@ contract BattleSystem is System { } function revealWinner(uint256 _battleId) public { - // 结算战斗 + // 结算战斗TODO revealWinner之后event + // TODO 战斗全局结束后有event + // TODO 战斗结束后如果没有人战败,也发一个event,表示当前局战斗结束了,但是整场战斗没有结束 BattleListData memory battle = BattleList.get(_battleId); BattleUtils.checkBattlePlayer(battle, _msgSender(), BattleState.Revealed);