This commit introduces a comprehensive turn-based system that controls when players can interact with cards. The changes include: - Adding turnPhase state tracking with draw, player_play, and cpu_play phases - Setting initial turn phase to player_play for proper game flow - Implementing conditional logic in card interaction handlers (hover, click) - Restricting all interactive card behaviors to only occur during the player's turn phase - Updating documentation comments to reflect the new turn-based control system These changes establish the foundation for a structured gameplay sequence where players can only play cards during their designated turn phase, preventing actions outside of proper game flow. |
||
|---|---|---|
| .. | ||
| card-data.js | ||
| main.js | ||