Closed aymericdelab closed 6 days ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
eternum | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Nov 19, 2024 4:36pm |
eternum-docs | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Nov 19, 2024 4:36pm |
The pull request introduces significant changes to several components related to battle events in the codebase. Key modifications include updates to the BattleClaimData
and BattlePillageData
structures, enhancing how battle-related data is captured, including new fields for troop losses and ownership details. Additionally, the user interface for displaying pillage history has been improved, and configuration files have been updated to reflect new contract entries and address changes. Overall, these alterations aim to provide more detailed tracking of battle events and enhance user experience.
File Path | Change Summary |
---|---|
client/src/dojo/contractComponents.ts | - Updated BattleClaimData : replaced previous_owner with claimee_address and claimee_name . - Expanded BattlePillageData : added attacker_lost_troops , structure_lost_troops , and pillaged_structure_owner_name . - Updated metadata types. |
client/src/ui/components/military/PillageHistory.tsx | - Enhanced PillageHistoryItem layout and structure. - Updated success/failure messages to "Successful Raid" or "Failed Raid". - Restructured resource display and added troop loss sections using TroopDisplay . |
client/src/ui/components/military/TroopChip.tsx | - Modified TroopMenuRow to TroopDisplay , adding optional props: direction , iconSize , and negative , enhancing layout flexibility and conditional styling for troop counts. |
contracts/dojo_dev.toml | - Added entries: "eternum-map_generation_systems" (duplicate) and "eternum-battle_utils_systems" in the writers section. |
contracts/manifest_dev.json | - Added new contract: battle_utils_systems with address and class hash. - Enhanced ABI structure with new interfaces and functions for troop management. - Expanded event definitions for battle utilities. |
contracts/src/models/event.cairo | - Updated BattleClaimData : replaced previous_owner with claimee_address and added claimee_name . - Expanded BattlePillageData with new fields for troop losses and ownership details. - Updated imports. |
contracts/src/systems/combat/contracts/battle_systems.cairo | - Enhanced battle initiation and claiming logic. - Updated battle_pillage function to calculate troop losses and improved event emissions. - Added error handling for battle state validations. |
client/src/ui/components/battles/BattleListItem.tsx | - Replaced TroopMenuRow with TroopDisplay for rendering troop information. |
client/src/ui/components/military/ArmyChip.tsx | - Replaced TroopMenuRow with TroopDisplay for displaying troop information. |
client/src/ui/components/trading/MarketModal.tsx | - Replaced TroopMenuRow with TroopDisplay for troop information display. |
client/src/ui/components/worldmap/structures/StructureListItem.tsx | - Replaced TroopMenuRow with TroopDisplay for troop information display. |
contractComponents.ts
file, which is directly related to the changes made in the main PR regarding the BattleClaimData
and BattlePillageData
structures, as both involve updates to the same components.BattleManager
class, which includes updates to the logic for claiming structures and managing battles, aligning with the modifications made in the main PR regarding battle-related data structures.ClientConfigManager
, which may indirectly relate to the main PR's changes in battle data structures by improving overall configuration management, impacting how battle data is handled.BattleManager
class, which is relevant to the main PR's focus on battle data structures, particularly in how battles and troop management are handled.SettlementConfig
structure, which may relate to the main PR's changes in battle data structures by impacting how settlements and battles interact within the game.🐇 In the land of battle, where heroes tread,
New tales of glory, where brave hearts led.
Troops lost and claimed, in the heat of the fight,
With clearer paths drawn, our future is bright!
So gather your courage, let victories ring,
For in this grand tale, together we sing! 🎶
[!WARNING]
Rate limit exceeded
@aymericdelab has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 7 minutes and 48 seconds before requesting another review.
⌛ How to resolve this issue?
After the wait time has elapsed, a review can be triggered using the `@coderabbitai review` command as a PR comment. Alternatively, push new commits to this PR. We recommend that you space out your commits to avoid hitting the rate limit.🚦 How do rate limits work?
CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our [FAQ](https://docs.coderabbit.ai/faq) for further information.📥 Commits
Reviewing files that changed from the base of the PR and between 97d4fc67d6a28c7001f41cafd45227c1c5061ee2 and 9c51dc63773cad190758b8d58d7d6877b918ee03.
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?
Failed to generate code suggestions for PR
Summary by CodeRabbit
Release Notes
New Features
TroopDisplay
component for improved troop information presentation across various UI components.Bug Fixes
Documentation
Chores