Closed KevinMB0220 closed 1 week ago
The pull request introduces a new Battle
struct in the src/models/battle.cairo
file, which represents the state and progress of a battle between two players. This struct includes fields such as battle_id
, player_id
, opponent_id
, active_beast_player
, active_beast_opponent
, battle_active
, and turn
, all defined as u32
. Each field is documented for clarity. Additionally, a test module is added to validate the initialization of a Battle
instance, ensuring that the fields are set correctly.
In src/systems/battle.cairo
, extensive documentation enhancements are made, adding comments to clarify the functionality of methods and structures without altering their signatures. The IBattleActions
interface and related structs remain unchanged, but their documentation is improved.
The test suite in src/tests/test_battle.cairo
is also updated with clearer comments and descriptions of the testing process, including a new test for the flee scenario. Other files such as .github/workflows/test.yaml
, .vscode/settings.json
, and various JSON files related to contracts and models undergo formatting adjustments or complete replacements, primarily for consistency and clarity.
Battle
struct introduced in this PR.Battle
struct and related functionalities.documentation
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
You are missing the documentation for the system tests, these are inside tests directory
Why am I seeing a lot of files that are not required to receive any kind of update modified?
Pull Request Overview
📝 Summary
🔄 Changes Made
🔧 Tests Results
🔜 Next Steps
PoC inicial
Summary by CodeRabbit
New Features
Battle
struct to manage battle states between players.Bug Fixes
Documentation
Chores