mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-11 00:24:47 -07:00
Cause:
- This issue happens due to logic of moving the card from the top of the
deck being reused when moving from the bottom of the deck, in a way
that makes it impossible to check if the card came from the bottom.
Resolution:
- Updated the logging logic in the client for card moves.
- Added a gRPC parameter ('is_from_bottom') for card moves.
- Updates the server logic to reverse the order of the card move if the
'is_from_bottom' parameter is true.
- Added a test to show the expected behaviour of the fix.
NOTE: While the changes in this patch seem big, this is due to changing
the loop in the moveCard function to a helper function, in order to make
the bug fix change. The only change to the loop was to pass a
variable attribution to the moveCard function because it was redundant
to be in the loop.
|
||
|---|---|---|
| .. | ||
| game | ||
| CMakeLists.txt | ||
| room_message_type.h | ||
| server.cpp | ||
| server.h | ||
| server_abstractuserinterface.cpp | ||
| server_abstractuserinterface.h | ||
| server_database_interface.cpp | ||
| server_database_interface.h | ||
| server_player_reference.h | ||
| server_protocolhandler.cpp | ||
| server_protocolhandler.h | ||
| server_remoteuserinterface.cpp | ||
| server_remoteuserinterface.h | ||
| server_response_containers.cpp | ||
| server_response_containers.h | ||
| server_room.cpp | ||
| server_room.h | ||
| serverinfo_user_container.cpp | ||
| serverinfo_user_container.h | ||
| user_level.h | ||