Chess board arrangement methods, related devices, equipment and storage media

CN117085331BActive Publication Date: 2026-08-14IFLYTEK (SUZHOU) TECH CO LTD +1
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-07
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

由此可见,现有方式一方面效率较为低下,另一方面还需配备专人记谱,故成本也较高

Benefits of technology

[0010]上述方案,响应于悔棋指令,基于弈棋序列确定悔棋指令期望返回的目标棋面,且弈棋序列所含的每个节点均表征执行一次弈棋操作后的棋面,在此基础上,控制弈棋装置整理现实棋盘上的现实棋面,且若检测到用户在现实棋面上新执行的弈棋操作,则控制弈棋装置在棋面整理过程中跳过新执行的弈棋操作的关联棋子,直至显示棋盘上关联棋子以外的局部棋面与目标棋面一致为止,故一方面通过弈棋序列实现自动记谱而无需人工记谱,有助于降低人力成本,另一方面响应于悔棋指令,根据弈棋序列直接确定目标棋面,并控制弈棋装置整理现实棋面,而无需手动重新布子,有助于提升效率,又一方面若检测到用户新执行的弈棋操作,则控制弈棋装置在棋面整理过程中跳过新执行的弈棋操作的关联棋子,从而尽可能地避免对用户下一手落子的非必要整理,有助于提升效率。故此,能够降低执行悔棋操作的成本,并提升执行悔棋操作的效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117085331B_ABST
    Figure CN117085331B_ABST
Patent Text Reader

Abstract

This application discloses a chessboard arrangement method, related apparatus, device, and storage medium. The chessboard arrangement method includes: responding to a re-move command, determining the target chessboard to be returned by the re-move command based on the game sequence; wherein each node in the game sequence represents the chessboard after performing a game operation; controlling a game device to arrange the real chessboard on the actual chessboard, and if a new game operation performed by the user on the actual chessboard is detected, controlling the game device to skip the associated pieces of the newly performed game operation during the chessboard arrangement process until the local chessboard other than the associated pieces matches the target chessboard. This solution reduces the cost of performing a re-move operation and improves the efficiency of performing a re-move operation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of human-computer interaction technology, and in particular to a method for arranging chess pieces and related devices, equipment and storage media. Background Technology

[0002] With the rapid development of electronic technology and artificial intelligence, the development of machines that can play against humans in real-world games to help train human chess skills has gradually attracted attention.

[0003] In the real world, during player-versus-player games, there are situations where taking back a move is allowed (e.g., in non-professional tournaments, or when playing with a practice partner). When one player takes back a move, both players need to rearrange the pieces on the actual board. Especially when there are many moves involved in taking back a move, it often requires manual notation to return the move to any position. Therefore, the current method is inefficient and requires dedicated personnel for notation, resulting in high costs. In light of this, reducing the cost of taking back moves and improving their efficiency has become an urgent problem to be solved. Summary of the Invention

[0004] The main technical problem addressed by this application is to provide a method for organizing chess pieces, as well as related devices, equipment, and storage media, which can reduce the cost of performing undo moves and improve the efficiency of performing undo moves.

[0005] To address the aforementioned technical problems, the first aspect of this application provides a chessboard arrangement method, comprising: responding to a retake instruction, determining the target chessboard to be returned by the retake instruction based on the game sequence; wherein each node in the game sequence represents the chessboard after performing a game operation; controlling a game device to arrange the real chessboard on the real chessboard, and if a new game operation performed by the user on the real chessboard is detected, controlling the game device to skip the associated pieces of the newly performed game operation during the chessboard arrangement process, until the local chessboard other than the associated pieces on the real chessboard matches the target chessboard.

[0006] To address the aforementioned technical problems, a second aspect of this application provides a chessboard arrangement device, comprising: a determining module and an arrangement module. The determining module is configured to, in response to a reversal instruction, determine the target chessboard to be returned by the reversal instruction based on the game sequence; wherein each node in the game sequence represents the chessboard after performing a game operation. The arrangement module is configured to control the chessboard device to arrange the real chessboard on the real chessboard, and if a new game operation performed by the user on the real chessboard is detected, control the chessboard device to skip the associated pieces of the newly performed game operation during the chessboard arrangement process until the local chessboard other than the associated pieces on the real chessboard matches the target chessboard.

[0007] To address the aforementioned technical problems, a third aspect of this application provides a master control device, comprising a memory and a processor coupled to each other, wherein the memory stores program instructions and the processor executes the program instructions to implement the chessboard arrangement method of the first aspect.

[0008] To solve the above-mentioned technical problems, the fourth aspect of this application provides a game device, including a display device, a game device, and a main control device as described in the third aspect above, wherein the display device and the game device are respectively coupled to the main control device, the display device is used to display a game interface under the control of the main control device, and the game device is used to perform game operations under the control of the main control device.

[0009] To address the aforementioned technical problems, the fifth aspect of this application provides a computer-readable storage medium storing program instructions executable by a processor, the program instructions being used to implement the chessboard arrangement method of the first aspect described above.

[0010] The above scheme, in response to a reversal command, determines the target board to be returned based on the game sequence. Each node in the game sequence represents the board after a single game action. Based on this, the game device is controlled to organize the actual board. If a new game action is detected on the actual board, the device skips the associated pieces during the organization process until the local board (excluding the associated pieces) matches the target board. Therefore, on the one hand, automatic notation is achieved through the game sequence, eliminating the need for manual notation and reducing labor costs. On the other hand, responding to a reversal command by directly determining the target board based on the game sequence and organizing the actual board without manual repositioning improves efficiency. Furthermore, if a new game action is detected, the device skips the associated pieces during the organization process, minimizing unnecessary organization for the user's next move and further improving efficiency. Thus, the cost of reversing a move is reduced, and the efficiency of reversing a move is improved. Attached Figure Description

[0011] Figure 1 This is a schematic diagram of the framework of an embodiment of the chessboard arrangement method of this application;

[0012] Figure 2a This is a schematic diagram of an embodiment of a chess game interface;

[0013] Figure 2b yes Figure 2a A schematic diagram of an embodiment of a virtual chessboard;

[0014] Figure 2c yes Figure 2a A schematic diagram of an embodiment of the Chinese chess sequence;

[0015] Figure 3 This is a schematic diagram of an embodiment of the chessboard arrangement method of this application;

[0016] Figure 4 This is a schematic diagram of an embodiment of the arrangement of markings;

[0017] Figure 5 This is a schematic diagram of the framework of an embodiment of the chessboard arrangement device of this application;

[0018] Figure 6 This is a schematic diagram of the framework of an embodiment of the main control device of this application;

[0019] Figure 7 This is a schematic diagram of the framework of an embodiment of the chess-playing device of this application;

[0020] Figure 8 This is a schematic diagram of a framework of an embodiment of the computer-readable storage medium of this application. Detailed Implementation

[0021] The embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0022] In the following description, specific details such as particular system architectures, interfaces, and technologies are presented for illustrative purposes rather than for limiting purposes, in order to provide a thorough understanding of this application.

[0023] In this paper, the terms "system" and "network" are often used interchangeably. The term "and / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. Additionally, the slash " / " generally indicates that the preceding and following related objects have an "or" relationship. Furthermore, "many" in this paper indicates two or more objects.

[0024] Please see Figure 1 , Figure 1 This is a schematic diagram of the framework of an embodiment of the chessboard arrangement method of this application. Specifically, the method steps in this embodiment can be implemented by the main control device in the chess-playing device, which may also include a display device and a chess-playing device. The display device is used to display the chess-playing interface, and the chess-playing device is used for actual operations such as taking and placing pieces. For details, please refer to the embodiments of the chess-playing device, which will not be elaborated here. This embodiment may include the following steps:

[0025] Step S11: In response to the undo command, determine the target board that the undo command expects to return based on the game sequence.

[0026] In this embodiment, each node in the game sequence represents the board state after one game operation. Specifically, the game sequence may contain several sequentially connected nodes, and each node represents the board state after one game operation. Of course, this embodiment is not limited to whether the game operation is performed on a virtual board or a real board. To distinguish between game operations performed on a virtual board and those performed on a real board, this application refers to game operations performed on a real board as real game operations and those performed on a virtual board as virtual game operations. Furthermore, to further improve the real-time performance of the game sequence, the game sequence is updated immediately after each game operation is completed. The process of updating the game sequence in real time is described in detail in the following description of this application, and will not be repeated here.

[0027] In one implementation scenario, please refer to the following: Figure 2a , Figure 2b and Figure 2c , Figure 2a This is a schematic diagram of one embodiment of a chess game interface. Figure 2b for Figure 2a A schematic diagram of an embodiment of a virtual chessboard. Figure 2c for Figure 2a A schematic diagram of an embodiment of a Chinese chess sequence. Taking Go as an example, as follows... Figure 2a and Figure 2c As shown, the chess interface displays the chess sequence (such as...). Figure 2a (As shown in the white dashed box on the right), as Figure 2a and Figure 2b As shown, the chess interface also displays a virtual chessboard (such as...). Figure 2a (As shown in the white dashed box on the left). The currently selected node is node number 16, and the board corresponding to node number 16 in the game sequence is the [board number missing]. Figure 2a and Figure 2b The virtual chessboard shown can be selected as the target board. The white pieces marked with solid black circles represent the move corresponding to node number 16 (where the white player moves). The pieces marked with dashed black circles represent the move corresponding to node number 17, which is the move for the next player (the black player). Understandably, when the selected node is node number 17... Figure 2a and Figure 2b In the diagram, the squares marked by the dotted black circles will be replaced by black stones, corresponding to the square with node number 17. Other cases can be deduced similarly, and will not be listed here. It should be noted that... Figure 2a , Figure 2b and Figure 2cThe illustrations shown represent only one possible implementation of the chess interface, virtual chessboard, and game sequence in practical applications, and do not limit other possible methods. For example, Figure 2a The leftmost column menu in the chess interface shown can also be omitted; or, Figure 2b The virtual chessboard shown can also be presented in different styles (such as color schemes); or, Figure 2c The game sequence shown can also be displayed vertically.

[0028] It should be noted that, Figure 2a , Figure 2b and Figure 2c The image shown is merely one possible position in an actual game and is not intended to limit the possibilities. Furthermore, in situations different from... Figure 2a , Figure 2b and Figure 2c In the situation shown, the process of determining the target board can be deduced by analogy, and will not be listed in detail here.

[0029] In this embodiment, the generation method of the undo command and the number of undo steps are not limited. However, the maximum number of undo steps is limited to the board corresponding to the root node of the move sequence, and the minimum number of undo steps should be greater than 0. The following examples illustrate the generation method of the undo command and the number of undo steps using several possible implementations. It should be understood that the following are merely possible implementations in this field and do not limit other possible methods.

[0030] In one implementation scenario, before responding to the undo command, the undo command can be generated by responding to the confirmation command following the selection command of the target node in the game sequence. It should be noted that the target node is any node other than the current node in the game sequence, and the confirmation command signifies the start of the game on the actual chessboard. In this case, the selected node in the game sequence can be designated as the new current node, and the board corresponding to the new current node can be selected as the target board to be returned by the undo command. It should be noted that when the undo command is triggered, the board corresponding to the current node is consistent with the actual board. This method, by selecting a node in the game sequence and reconfirming the start of the game on the actual chessboard, completes the undo operation, increasing the freedom of the undo operation while reducing the difficulty of triggering it.

[0031] In a specific implementation scenario, to facilitate node selection, the display device can be set to a touch display, thereby responding to the user's touch command on the physical device, obtaining the touch point coordinates, and generating the corresponding node selection command based on the node where the touch point coordinates are located.

[0032] In another specific implementation scenario, the display device can also be configured as a non-touch display. To facilitate human-computer interaction, the game device can further include an input device, coupled to the main control device. The input device can include, for example, a mouse, keyboard, microphone, etc., without limitation, and can receive the selected node determined by the input device. For example, when the input device is a mouse, the user can manipulate the mouse to select any node in the game sequence by clicking; or, when the input device is a keyboard, the user can manipulate the keyboard to select any node in the game sequence by inputting the node number; or, when the input device is a microphone, the user can input the node number into the microphone to select any node in the game sequence. The same logic applies to other input device configurations, which will not be listed here.

[0033] In another specific implementation scenario, to facilitate the distinction between real-world chessboard operations and virtual chessboard operations within the chessboard interface, at least an analysis mode and a playing mode can be provided. In analysis mode, the target thread linking with the chess-playing device can be severed, and the chess-playing device performs real-world operations such as piece capture and placement without being controlled by the main control device. Conversely, in playing mode, the target thread linking with the chess-playing device can be restored, and the chess-playing device performs real-world operations such as piece capture and placement under the control of the main control device. As one possible implementation, the chess sequence can be displayed on the chessboard interface only in analysis mode. In this mode, a selection command for any node in the chess sequence can be accepted, and upon receiving a switch command from analysis mode to playing mode, a confirmation command indicating the start of the game on the real chessboard is generated. For example, as shown... Figure 2a As shown, the chess interface can have at least two mode options representing analysis mode and chess playing mode, and the current mode is determined as analysis mode or chess playing mode based on the currently selected mode option. Of course, the above example is not limited to other implementations. For example, the chess sequence is not limited to being displayed on the chess interface in analysis mode; it can also be displayed on the chess interface in chess playing mode, without further limitation.

[0034] In a specific implementation scenario, please refer to the relevant documents. Figure 2a , Figure 2b and Figure 2c It should be noted that the actual chessboard layout refers to the layout corresponding to node number "22" in the game sequence. That is, when the undo command is triggered, the current node is node number "22". In this case, any node between node numbers "1" and "21" can be selected. For example... Figure 2cAs shown, the selected node is node number "16" (which is now the new current node), and triggers a confirmation command representing the start of the game on the real chessboard. It generates a command representing the expectation to return from the chessboard corresponding to node number "21" to the chessboard corresponding to node number "16" (i.e., the target chessboard). Figure 2a or Figure 2b The example above shows the undo move command for the chessboard (as shown in the image). Of course, the above example is merely one possible implementation in practical applications and does not limit other possible scenarios.

[0035] In another implementation scenario, unlike the aforementioned implementation method and the reversal to the board corresponding to any node in the game sequence, real-time undoing is also possible during the game. Specifically, an undo command triggered during the game can be received. Based on this, the number of steps to undo can be determined for both players, and the new current node is determined by moving the corresponding node of the actual board in the game sequence towards the root node. The board corresponding to the new current node is then selected as the target board to which the undo command expects to return. This method, by triggering the undo command at any time during the game, helps to improve the immediacy of the undo operation.

[0036] In a specific implementation scenario, to facilitate triggering an undo move, an undo option can be set in the game interface. When a selection command for the undo option is detected, an undo command can be generated. For an example, please refer to [reference needed]. Figure 2a ,like Figure 2a As shown in the left-hand menu, an undo option can be set, allowing users to select it at any time on the game interface to trigger the undo command. However, in practical applications, this is not the only possibility, and the above example does not limit the implementation method for triggering undo. For instance, a physical button for triggering undo can be provided on the main control device; once the physical button is triggered, an undo command can be generated.

[0037] In a specific implementation scenario, in practical applications, the two sides playing chess can include, but are not limited to: human-computer interaction, user-to-user interaction, and local self-play. For ease of understanding, the above three situations are described below: (1) Human-computer interaction: The two sides playing chess are a user and the local machine, (2) User-to-user interaction: Both sides playing chess are users (taking Go as an example, such as a single user playing both black and white, or two users, one playing black and the other playing white), (3) Local self-play: Both sides playing chess are the local machine (taking Go as an example, the local machine playing both black and white). After determining the two sides playing chess, the number of moves to undo can be determined based on the two sides playing chess. Specifically, in response to the two sides playing chess representing human-computer interaction, the number of moves to undo can be determined based on the player executing the chess operation corresponding to the current node. Specifically, in response to the player executing the chess operation corresponding to the current node being a user, the number of moves to undo can be determined to be 1, or in response to the player executing the chess operation corresponding to the current node being the local machine, the number of moves to undo can be determined to be 2. Conversely, in response to the self-play between the two players, the number of moves to undo a move can be determined to be 1. The above method, responding to the human-computer interaction between the two players, determines the number of moves to undo a move based on the player executing the move corresponding to the current node. However, in response to the self-play between the two players, the number of moves to undo a move is determined to be 1. Therefore, it can distinguish between different situations to determine the number of moves to undo a move, which helps improve the accuracy of determining the number of moves to undo a move.

[0038] In a specific implementation scenario, please refer to the following: Figure 2a , Figure 2b and Figure 2c Taking Go as an example, Black represents the user and White represents the computer. If the current move reaches node number "16", meaning White (the computer) has made a move while Black (the user) has not, and an undo command is detected, since the player executing the move corresponding to the current node is the computer, the undo move count is 2, i.e., moving 2 steps towards the root node to node number "14", which becomes the new current node. Alternatively, if the current move reaches node number "17", meaning Black (the user) has made a move while White (the computer) has not, and an undo command is detected, since the player executing the move corresponding to the current node is the user, the undo move count is 1, i.e., moving 1 step towards the root node to node number "16", which becomes the new current node.

[0039] Step S12: Control the chess-playing device to organize the real chess pieces on the real chessboard. If a new chess-playing operation performed by the user on the real chessboard is detected, control the chess-playing device to skip the associated pieces of the newly performed chess-playing operation during the chess piece organization process until the local chess pieces other than the associated pieces on the real chessboard are consistent with the target chess piece.

[0040] In this embodiment of the disclosure, the associated pieces of a newly executed chess operation may include, but are not limited to, newly added pieces, newly moved pieces, and newly removed pieces resulting from the newly executed chess operation, and are not limited here. Taking Go as an example, a newly executed chess operation may result in the addition of new pieces (e.g., if the target player is Black, a new black piece will be added due to Black's newly executed chess operation), and may also result in the removal of new pieces (e.g., if the target player is Black, a new white piece will be removed due to Black's newly executed chess operation); or, taking chess as an example, a newly executed chess operation may result in the moving of new pieces (e.g., if the target player is Black, a new black rook will be moved due to Black's newly executed chess operation), and may also result in the removal of new pieces (e.g., if the target player is Black, a new red pawn will be removed due to Black's newly executed chess operation). Other cases can be deduced by analogy, and will not be listed one by one here.

[0041] In one implementation scenario, the chess-playing device may include, but is not limited to, a robotic arm. The main control device can control the chess-playing device to organize the actual chessboard on the real chessboard. Specifically, it can compare the actual chessboard with the target chessboard to identify pieces that are different, and these differing pieces include at least one of the pieces to be added or removed. Based on this, the device can be controlled to process the pieces to be removed and the pieces to be added in sequence. This method, by identifying the differing pieces through comparison (including at least one of the pieces to be added or removed), and then controlling the device to process the pieces to be removed and the pieces to be added in sequence, can minimize the path overhead of the device traveling between the actual chessboard and the chess box, thus improving the efficiency of chessboard organization.

[0042] In a specific implementation scenario, each time the control device performs a processing operation on the different pieces, the differences on the board can be re-compared until the board matches.

[0043] In a specific implementation scenario, during the process of controlling the chess-playing device to sequentially process pieces to be removed and pieces to be added, the device can first detect whether the difference pieces include the piece to be removed. If the difference pieces include the piece to be removed, the device can first remove the piece to be removed from the real chessboard. If the difference pieces include a piece to be added that matches the removed piece, the device can then add the removed piece to the position of the piece to be added. Alternatively, if the difference pieces do not include a piece to be added that matches the removed piece, the device can return the removed piece to its original chess box and re-execute the step of comparing the difference pieces between the real chessboard and the latest virtual chessboard. Conversely, if the difference pieces do not include the piece to be removed but include the piece to be added, the device can extract a piece to be added that matches the piece to be added from its original chess box and add the extracted piece to the position of the piece to be added. The device can then re-execute the step of comparing the difference pieces between the real chessboard and the latest virtual chessboard. The above method processes the pieces to be removed before processing the pieces to be added during the chessboard arrangement process. Furthermore, if there is a piece to be added that matches the piece to be removed during the process of processing the piece to be removed, the piece to be removed is directly added to the position of the piece to be added. This can minimize the path overhead of the chess-playing device traveling back and forth between the physical chessboard and the chess box, and help improve the efficiency of chessboard arrangement.

[0044] In one implementation scenario, to facilitate the detection of chess-playing operations on a real chessboard, the chess-playing device can further include a camera mounted on top of the real chessboard to capture images of the board. Based on this, the actual chessboard layout can be obtained by detecting the images captured by the camera. Alternatively, different chess pieces can have electronic tags embedded within them, and the real chessboard can have sensors to detect the positions of each piece. Based on this, the actual chessboard layout can be obtained by analyzing the data from the sensors. The above examples are merely a few possible methods for obtaining the actual chessboard layout and do not limit other implementation methods.

[0045] In one implementation scenario, after a newly executed chess-playing operation is detected, the subsequent steps of controlling the chess-playing device to skip the associated pieces of the newly executed chess-playing operation during the chess-playing process can be directly executed until the chess-playing process is completed.

[0046] In another implementation scenario, unlike directly skipping associated pieces during board clearing after detecting a new move, the system can first check if the new move conforms to the move rules. If it does, the system skips associated pieces during board clearing and continues adding new nodes under the latest current node in the move sequence. This adds nodes to the board after the target board is cleared, allowing users to execute the next move while the move sequence is updated instantly, further improving efficiency.

[0047] In a specific implementation scenario, detecting whether a newly executed chess move conforms to the rules of the game can include, but is not limited to, conformity in form and conformity in movement, etc. For conformity in form, taking Go as an example, if the color of the piece corresponding to the newly executed move is different from the color of the piece held by the user, it can be considered a conformity in form. Or, taking Chinese chess as an example, if the piece corresponding to the newly executed move is a piece that has already been captured, it can be considered a conformity in form. For conformity in movement, taking Go as an example, if the newly executed move is a "suicidal move," it can be considered a conformity in movement. Or, taking Chinese chess as an example, if the knight corresponding to the newly executed move does not move in an "L" shape, it can be considered a conformity in movement. Other cases can be deduced similarly, and will not be listed here.

[0048] It should be noted that in practical applications, this function can not only check newly executed moves, but also, before the board is fully cleared, check whether all moves following the undo command comply with the rules of the game. Taking chess as an example, if a piece from the other side moves, it can also be considered a move that violates the rules of the game.

[0049] In a specific implementation scenario, the associated pieces of a newly executed chess operation may include, but are not limited to, newly added, newly moved, or newly removed pieces resulting from the operation. For details, please refer to the aforementioned descriptions, which will not be repeated here. In other words, during the board arrangement process, the chess-playing device will be controlled to skip these associated pieces to retain as many associated pieces as possible resulting from the newly executed operation, thereby improving efficiency. Please refer to [the relevant documentation / reference]. Figure 3 , Figure 3This is a schematic diagram of an embodiment of the chessboard arrangement method of this application. For example... Figure 3 As shown, the black piece in the lower right corner of the real chessboard is the associated piece (i.e., the newly added piece) of the new chess operation performed on the real chessboard after the user issues the undo command. During the process of the chess-playing device organizing the real chessboard, the associated piece will be skipped until the local chessboard other than the associated piece in the real chessboard is consistent with the target chessboard.

[0050] In one implementation scenario, if no new game operation by the user is detected during the game board arrangement process, the game board device can be directly controlled to arrange the real game board to match the target game board.

[0051] In one implementation scenario, as mentioned earlier, undoing a move can be performed by selecting a node in the game sequence. In this case, to further improve the reliability of subsequent board clearing, the target player for the next move on the target board can be determined based on the new current node. After detecting a new move by the user on the actual board, and before the device skips the associated pieces of the newly executed move during board clearing, it can be determined whether the target player is the user. If the target player is indeed the user, then the step of controlling the device to skip the associated pieces of the newly executed move during board clearing can be executed. This method, by determining the target player for the next move on the target board before detecting a new move and before controlling the device to clear the board, and only after confirming that the target player is indeed the user, further improves the reliability of board clearing.

[0052] In a specific implementation scenario, after determining the new current node, the target player to perform the next move on the target board can be determined based on the rules of play and the player who performed the move corresponding to the new current node. For example, taking Go as an example, the rules of play typically involve both black and white players submitting their moves. Therefore, if the player performing the move corresponding to the new current node is white, the target player is black; conversely, if the player performing the move corresponding to the new current node is black, the target player is white. Other cases can be deduced similarly, and will not be listed here.

[0053] In a specific implementation scenario, unlike when the target player is a user, when the target player is the local machine, regardless of whether a new move by the user is detected on the actual board, the game-playing device is controlled to rearrange the actual board until it matches the target board. It should be noted that when the target player is the local machine, if a new move by the user is detected on the actual board, this new move violates the rules of play, so the game-playing device can be controlled to rearrange the actual board until it matches the target board. Taking Go as an example, if the target player is White (the local machine), and a new move by Black (the user) is detected during the board rearrangement process, this new move itself violates the rules of play, so the game-playing device is controlled to rearrange the actual board until it matches the target board. In the above method, when the target player is the local machine, the control device arranges the actual chess board to match the target chess board. This ignores any new chess operations that the user may perform during the chess board arrangement process, and directly controls the chess board to arrange the actual chess board to match the target chess board, thereby improving the efficiency of chess board arrangement.

[0054] In one implementation scenario, to further improve the efficiency of board clearing, the virtual board on the game interface can be synchronized with the real board in real time, and the differences between the real board and the target board can be identified in real time. Based on this, the differences can be highlighted, which helps with human-computer collaborative board clearing and thus maximizes the efficiency of board clearing.

[0055] In a specific implementation scenario, before synchronizing the virtual chessboard with the real chessboard, compliance checks can be performed on the real chessboard and the chess-playing operations. Once the checks are compliant, the virtual chessboard can be synchronized with the real chessboard, and new nodes can be added under the current node in the chess-playing sequence. The new nodes correspond to the corresponding chess-playing operations. For details, please refer to the aforementioned descriptions, which will not be repeated here.

[0056] In a specific implementation scenario, it's possible to control the display of sorting markers on differing pieces in a virtual chessboard. Specifically, sorting markers can include, but are not limited to, checkmarks, crosses, etc. The specific form of the sorting markers is not limited here. Please refer to section 4. Figure 4 This is a schematic diagram illustrating an embodiment of the arrangement of markings. For example... Figure 4As shown, the sorting markers can be represented by flags. To distinguish between pieces to be added and pieces to be removed, different colored flags can be used to mark them respectively. For example, a red flag can be used to represent a piece to be removed, while a blue flag can be used to represent a piece to be added. Of course, the above example is only one possible implementation in practical applications and does not limit the specific form of the sorting markers. This method, which controls the display of sorting markers on the squares where different pieces are located on the virtual chessboard, can more clearly and conspicuously indicate pieces to be removed and pieces to be added, thus helping to improve the efficiency of human-computer collaborative chessboard sorting.

[0057] In a specific implementation scenario, unlike the aforementioned prompting methods, a primary prompt message for organizing differing pieces can also be displayed on the game interface. Specifically, this primary prompt message can be displayed in text form on the game interface. For example, it can directly output the primary prompt message containing the coordinates of the square where the differing piece is located. Of course, to distinguish between pieces to be added and pieces to be removed, the primary prompt messages for added and removed pieces can be displayed separately; this is not a limitation here. The above method, controlling the display of the primary prompt message on the game interface, can clearly and prominently indicate pieces to be removed and added, helping to improve the efficiency of human-computer collaborative game organization.

[0058] In a specific implementation scenario, in addition to the aforementioned prompting methods, a second prompt can be played to indicate the location of the differing piece. Specifically, the coordinates of the square containing the differing piece can be announced verbally as the second prompt. Of course, to distinguish between pieces to be added and pieces to be removed, the second prompts for added and removed pieces can be announced separately; this is not a limitation here. This method, controlling the playback of the second prompt, can clearly and prominently indicate the pieces to be removed and added, thus improving the efficiency of human-computer collaborative piece arrangement.

[0059] In a specific implementation scenario, unlike the aforementioned prompting methods, each square on the real chessboard is equipped with a light-emitting element, and the pieces can be set to have a certain degree of transparency, ideally allowing the light emitted from the light-emitting elements to pass through them. In this case, the light-emitting elements on the squares containing the different pieces can be controlled to illuminate, thus indicating the difference. Of course, different illumination methods can be used to distinguish between pieces to be added and pieces to be removed. For example, for a piece to be added, the light-emitting element on its corresponding square can remain constantly lit until the piece is added to that square, while for a piece to be removed, the light-emitting element on its corresponding square can flash until the piece is removed from that square. Furthermore, to distinguish different pieces, the light-emitting elements can also emit different colors. Taking Go as an example, white pieces can emit blue light, while black pieces can emit red light. In this scenario, if the piece to be added is black, the light-emitting element on its corresponding grid point can be kept constantly lit in red until the piece is added to that grid point. If the piece to be added is white, the light-emitting element on its corresponding grid point can be kept constantly lit in blue until the piece is added to that grid point. Conversely, for the piece to be removed, whether it is black or white, the light-emitting element on its corresponding grid point can be controlled to flash until the piece is removed from that grid point.

[0060] It should be noted that once the board is rearranged, the undo move is considered complete, and the game mode resumes for both players. During this process, the move sequence and virtual board can be synchronized with the moves made by both players on the real board. To further reduce the possibility of errors during the game, board rearrangement can be performed again at the initial stage of the game mode to ensure consistency between the real and virtual boards. The specific process of board rearrangement can be found in the aforementioned descriptions and will not be repeated here. After this, the game cycle can begin. Taking a human-computer game as an example, the game cycle can include human rounds and local rounds, as described below. Of course, the game is not limited to human-computer games; it can also be user-to-user games (i.e., both players are users) or local-to-local games (i.e., both players are local machines). This is not a limitation here. The main difference is that, in user-controlled self-play, regardless of which side is currently playing (e.g., black and white in Go, or black and red in chess), it is usually not necessary to control the playing device to perform real-world playing operations on the actual chessboard. For details, please refer to the description below regarding the current player being the user; it will not be repeated here. Conversely, in local self-play, regardless of which side is currently playing (e.g., black and white in Go, or black and red in chess), it is always necessary to control the playing device to perform real-world playing operations on the actual chessboard. For details, please refer to the description below regarding the current player being the local machine; it will not be repeated here.

[0061] Specifically, the current player's move can be determined first. Based on this, if the current player is a user and a real-world game action on the chessboard is detected, a new node is added to the game sequence. The new node continues the current node's sequence, and the process of determining the current player's move is repeated. Conversely, if the current player is the machine itself, the game device can be controlled to perform a real-world game action on the chessboard, adding a new node to the game sequence. The new node continues the current node's sequence, and the process of determining the current player's move is repeated. It should be noted that the chessboard corresponding to the current node is consistent with the latest chessboard before the real-world game action, and the chessboard corresponding to the new node is consistent with the updated chessboard after the real-world game action. This method updates the game sequence in real-time based on real-world game actions during the game on the real chessboard, enabling automatic notation and improving the efficiency of human-computer interaction.

[0062] In one implementation scenario, the current mover can be determined by combining the game sequence. Specifically, if the board corresponding to a node in the game sequence matches the latest board, that node can be taken as the current node. Based on this, the mover corresponding to the current node's move can be determined first, and then the current mover can be determined based on the mover corresponding to the current node's move. Taking Go as an example, in a normal game, black and white usually take turns moving the stones. If the mover corresponding to the current node's move is black, then the current mover can be determined as white; conversely, if the mover corresponding to the current node's move is white, then the current mover can be determined as black. Other cases can be deduced similarly, and will not be listed here.

[0063] In one implementation scenario, the actual chess game operation can be detected based on the image captured by the camera device mounted above the actual chessboard, or the actual chess game operation can be detected based on the data sensed by the sensor device placed on the actual chessboard. For details, please refer to the aforementioned descriptions of the camera device and the sensor device, which will not be repeated here.

[0064] In one implementation scenario, to further improve the performance of the chess-playing device, after detecting the user's actual chess-playing actions on the real chessboard, a human operation legality check can be performed on these actions. Specifically, it can be determined whether the chessboard change is legal. If it is legal, the next step is taken; otherwise, the chess-playing interface can display a message indicating that the actual chess-playing action is illegal, allowing the user to re-execute the action. Taking Go as an example, if the action results in an extra piece not belonging to the current player, or the current player losing pieces, it can be directly determined to be illegal. Similarly, in chess, if the action results in an extra piece that has already been captured, or the current player losing pieces, or other players' pieces being moved, it can be directly determined to be illegal. Furthermore, if the action is deemed legal, the legality of the placement or movement of a piece can also be checked. If legal, the next step is taken; otherwise, it is deemed illegal, and a corresponding message is displayed (as described above). Taking Go as an example, we can determine whether the extra pieces added due to actual game operations are legal. If this move is a move like "suicide," it can be directly determined to be illegal. Or, taking chess as an example, we can determine whether the movement of pieces due to actual game operations is legal. If the "horse" does not move in an "L" shape, it can be directly determined to be illegal.

[0065] In one implementation scenario, to improve chess playing efficiency, before re-executing the step of determining the current player's move, the virtual chessboard can be synchronized with the chessboard corresponding to the newly added node, thereby ensuring that the real chessboard and the virtual chessboard remain synchronized and consistent.

[0066] In one implementation scenario, before re-executing the step to determine the current move, it's possible to further check if the current state meets the actual game conditions. If it does, the step to determine the current move can be re-executed; otherwise, the loop can be exited. It should be noted that the actual game conditions may include still being in game mode and the game not having ended.

[0067] In one implementation scenario, when the current player is the local machine, the game-playing device can be controlled to retrieve the target piece from the current player's game box and place it on the target square on the actual game board. Furthermore, taking Go as an example, if there is a capture opportunity, the game-playing device must also retrieve the piece to be captured from the actual game board and place it in the corresponding game box; or, taking Chinese chess as an example, if there is a capture opportunity, the game-playing device must retrieve the piece to be captured from the actual game board and place it in a designated area outside the actual game board, and then place the target piece on the target square on the actual game board.

[0068] In one implementation scenario, when the current player is the user, the following loop can be executed, and the execution conditions of the loop include still being in chess mode, the game not ending, and no special operation detected. It should be noted that normal chess operations are not considered special operations, such as giving a handicap, taking back a move, and resigning. In the loop, the real chess board and the virtual chess board can be compared first, and there are three situations: (1) If the real chess board and the virtual chess board are the same, it can be determined that the user has not yet performed a real chess operation, and the comparison between the real chess board and the virtual chess board can be repeated; (2) If the real chess board and the virtual chess board are different, it can be determined that the user has performed a real chess operation, and the human operation legality check is entered (see the above relevant description for details). If the check is legal, the chess sequence can be updated and the loop can be ended, that is, the new current player is switched to the local machine. In addition, if a special operation is detected in this process, the loop can also be ended and a special operation can be performed; (3) If neither of the above two situations applies, the next step is taken. Secondly, the difference between the real and virtual chessboard can be displayed as an error notification on the game interface. For example, the difference between the real and virtual chessboard pieces can be displayed on the virtual chessboard. Furthermore, a real-world chessboard correction process can be initiated. It should be noted that the real-world chessboard correction process is largely the same as the aforementioned chessboard organization process, the main difference being that in the real-world chessboard correction process, after identifying the differing piece, it is necessary to check whether the differing piece is allowed. If allowed, the real-world chessboard correction process can end; otherwise, the game device can be controlled to correct the real-world chessboard. For details, please refer to the aforementioned description of "controlling the game device to sequentially process pieces to be removed and pieces to be added," which will not be repeated here. After the real-world chessboard correction process ends, it can return to re-compare the real and virtual chessboards to determine whether the user has performed a real-world game operation. Of course, if a special operation is detected in the real-world chessboard correction process, the loop can be terminated, and the special operation can be performed.

[0069] In one implementation scenario, to further improve chess-playing efficiency, a board validity check can be performed during each loop of the chess-playing mode. Specifically, the board validity check can also be a loop, and the loop conditions can include still being in chess-playing mode, no special operation detected, and the game not yet ended. During the loop, the differences between the real and virtual chess pieces can be compared first. The following situations exist: (1) There are no differences, the chess piece is normal, and the loop ends; (2) There are differences, and the differences are different from the historical differences. Then, different checking methods are used for the specific manifestations of the differences. Taking Go as an example, if the user has one more piece and the machine has one less piece, it can be checked whether the machine controls the playing device to place the wrong color piece on the real chessboard during the machine's playing phase. If so, the user can be prompted. If the user has one more piece and it may be that the user has made the next move and it is not that the machine placed the wrong color piece, the human operation legality check process can be executed (see the above description for details). If the check is legal, the loop can be ended directly. Of course, if a special operation is detected during this process, the loop can also be ended; (3) There are differences, and the differences are the same as the historical differences. Then, wait a while and execute the above "comparing the differences between the real and virtual chess pieces" step again. Secondly, it can display the areas on the board that need adjustment and proceed to the actual board correction process (see the aforementioned description for details).

[0070] In one implementation scenario, after adding a new node to the control sequence and before re-determining the current move, the current game file can be temporarily stored. It should be noted that the game file can at least contain the current game sequence. Based on this, in response to a selection command for a game file after the current game is interrupted, the selected game file is loaded as the target game file, and the virtual chessboard is synchronized with the chessboard corresponding to the current node in the game sequence contained in the target game file. It should be noted that the current game can be interrupted unexpectedly due to a power outage of the playing device, or manually due to the user's inability to continue playing; this is not limited here. Furthermore, the user's selection command among several game files can be obtained, allowing the selected game file to be used as the target game file; alternatively, in response to the user's selection to continue the previous game at the start after the current game is interrupted, a selection command for the previous game's game file can be automatically generated, and the previous game's game file can be used as the target game file; this is also not limited here. It should be noted that the current node in the game sequence contained in the target game file can be determined based on the board state at the end of the game to which the target game file belongs. Specifically, the board state corresponding to the current node can be exactly the board state at the end of the game to which the target game file belongs. Alternatively, the current node in the game sequence contained in the target game file can also be determined based on the main board of the game sequence contained in the target game file. Specifically, the current node can be determined as the last node of the main board in the game sequence. Alternatively, the current node in the game sequence contained in the target game file can also be determined based on the anchor point markers in the game sequence contained in the target game file. Specifically, the board state corresponding to the node marked with the anchor point marker is consistent with the latest actual board state during the game, so the current node can be determined as the node marked with the anchor point marker in the game sequence. The above examples are only a few possible implementation methods for determining the current node in practical applications, and do not limit the specific way of determining the current node. The above method, after adding a second new node to the control game sequence and before re-execution, temporarily stores the game file of the current game and responds to the selection instruction of the game file after the current game is interrupted, loads the selected game file as the target game file, and controls the virtual chess surface on the virtual chessboard to be synchronized with the chess surface corresponding to the current node in the game sequence contained in the target game file, which can improve the convenience of the opening of the game in the human-computer game process.

[0071] The above scheme, in response to a reversal command, determines the target board to be returned based on the game sequence. Each node in the game sequence represents the board after a single game action. Based on this, the game device is controlled to organize the actual board. If a new game action is detected on the actual board, the device skips this action during the board organization process until the displayed board area (excluding the newly executed action) matches the target board. Therefore, on the one hand, automatic notation is achieved through the game sequence, eliminating the need for manual notation and reducing labor costs. On the other hand, responding to a reversal command by directly determining the target board based on the game sequence and organizing the actual board without manual repositioning improves efficiency. Furthermore, if a new game action is detected, the device skips it during the board organization process, minimizing unnecessary adjustments for the user's next move and further improving efficiency. Thus, the cost of reversing a move is reduced, and the efficiency of reversing a move is improved.

[0072] Please see Figure 5 , Figure 5 This is a schematic diagram of a framework of an embodiment of the chessboard arrangement device 50 of this application. The chessboard arrangement device 50 includes: a determining module 51 and an arrangement module 52. The determining module 51 is used to determine the target chessboard to be returned by the undo command based on the game sequence in response to the undo command; wherein each node in the game sequence represents the chessboard after performing a game operation. The arrangement module 52 is used to control the chessboard device to arrange the real chessboard on the real chessboard, and if a new game operation performed by the user on the real chessboard is detected, the chessboard device is controlled to skip the associated pieces of the newly performed game operation during the chessboard arrangement process until the local chessboard other than the associated pieces on the real chessboard is consistent with the target chessboard.

[0073] In the above scheme, the chessboard arrangement device 50 responds to the undo command by determining the target chessboard to be returned by the undo command based on the game sequence. Each node in the game sequence represents the chessboard after a game operation. Based on this, the device arranges the actual chessboard on the real chessboard. If a new game operation performed by the user on the real chessboard is detected, the device skips the associated pieces of the newly performed game operation during the chessboard arrangement process until the local chessboard other than the associated pieces matches the target chessboard. Therefore, on the one hand, automatic notation is achieved through the game sequence without manual notation, which helps reduce labor costs. On the other hand, responding to the undo command by directly determining the target chessboard based on the game sequence and arranging the actual chessboard without manual re-placing of pieces helps improve efficiency. Furthermore, when the target player is the user, if a new game operation performed by the user is detected, the device skips the associated pieces of the newly performed game operation during the chessboard arrangement process, thereby avoiding unnecessary arrangement of the user's next move as much as possible, which helps improve efficiency. Therefore, it can reduce the cost of performing the undo operation and improve the efficiency of performing the undo operation.

[0074] In some disclosed embodiments, the chessboard arrangement device 50 further includes an instruction generation module, which generates a retake instruction in response to a confirmation instruction following a selection instruction for a target node in the game sequence; wherein, the target node is any node other than the current node in the game sequence, and the confirmation instruction indicates the start of the game on the actual chessboard; the determination module 51 is specifically used to determine the selected node in the game sequence as the new current node, and select the chessboard corresponding to the new current node as the target chessboard.

[0075] In some disclosed embodiments, the chessboard arrangement device 50 further includes a move determination module, which is used to determine the target player to perform the next move operation on the target chessboard based on the new current node; the arrangement module 52 is specifically used to respond to the target player being a user, and to perform the step of controlling the chessboard device to skip the associated pieces of the newly executed chessboard operation during the chessboard arrangement process.

[0076] In some disclosed embodiments, the organizing module 52 is also specifically used to control the chess-playing device to organize the real chess board to match the target chess board in response to the target chess player being the local machine.

[0077] In some disclosed embodiments, the chessboard arrangement device 50 further includes an instruction receiving module for receiving a reversal instruction triggered during the game; the determining module 51 is specifically used to determine the number of reversal steps based on the two players, and move the number of reversal steps towards the root node based on the corresponding node of the actual chessboard in the game sequence as the new current node, and select the chessboard corresponding to the new current node as the target chessboard.

[0078] In some disclosed embodiments, the determining module 51 includes a first response submodule, which is used to determine the number of undo moves based on the mover performing the move corresponding to the current node in response to the human-computer interaction between the two players; the determining module 51 also includes a second response submodule, which is used to determine the number of undo moves as 1 in response to the self-play between the two players.

[0079] In some disclosed embodiments, the first response submodule includes a first determining unit, configured to determine the number of undo moves as 1 in response to the fact that the player performing the chess operation corresponding to the current node is a user; the first response submodule includes a second determining unit, configured to determine the number of undo moves as 2 in response to the fact that the player performing the chess operation corresponding to the current node is the local machine.

[0080] In some disclosed embodiments, the chessboard arrangement device 50 further includes an operation detection module for detecting whether the newly executed chess operation conforms to the move rules; the arrangement module 52 is specifically used to respond to the fact that the newly executed chess operation conforms to the move rules, control the chess device to skip the associated chess pieces during the chessboard arrangement process, and control the addition of new nodes under the latest current node in the chess sequence; wherein, the chessboard corresponding to the new node is the chessboard after the newly executed chess operation is superimposed on the target chessboard.

[0081] In some disclosed embodiments, the chessboard arrangement device 50 further includes a chessboard synchronization module, which controls the virtual chessboard on the chessboard interface to synchronize with the real chessboard in real time, and determines the differences between the real chessboard and the target chessboard in real time; the chessboard arrangement device 50 also includes a difference prompting module, which controls the prompting of the differences.

[0082] In some disclosed embodiments, the difference prompting module includes a first prompting submodule for controlling the display of a sorting mark on the grid where the difference piece is located in the virtual chessboard; the difference prompting module includes a second prompting submodule for controlling the display of a first prompting message on the chess interface; and the difference prompting module includes a third prompting submodule for controlling the playback of a second prompting message; wherein the sorting mark, the first prompting message, and the second prompting message are all used to prompt the sorting of the difference piece.

[0083] In some disclosed embodiments, the sorting module 52 includes a chessboard comparison submodule for comparing the difference pieces between the actual chessboard and the target chessboard; wherein the difference pieces include at least one of pieces to be added and pieces to be removed; the sorting module 52 includes a difference processing submodule for controlling the chess-playing device to process the pieces to be removed and the pieces to be added in sequence.

[0084] Please see Figure 6 , Figure 6This is a schematic diagram of a framework of an embodiment of the main control device 60 of this application. The main control device 60 includes a memory 61 and a processor 62 coupled to each other. The memory 61 stores program instructions, and the processor 62 is used to execute the program instructions to implement the steps in any of the above-described chess board arrangement method embodiments. Furthermore, the main control device 60 may specifically include, but is not limited to, desktop computers, laptops, industrial control computers, etc., and is not limited here. It should be noted that the main control device 60 can decide the game strategy locally, or it can communicate with a server to obtain the game strategy issued by the server. In this case, the main control device 60 may also include a communication circuit (not shown), and the communication circuit is also coupled to the processor 62. The communication circuit communicates with the server to obtain the game strategy from the server.

[0085] Specifically, processor 62 controls itself and memory 61 to implement the steps in any of the above-described chessboard arrangement method embodiments. Processor 62 can also be referred to as a CPU (Central Processing Unit). Processor 62 may be an integrated circuit chip with signal processing capabilities. Processor 62 can also be a general-purpose processor, digital signal processor (DSP), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. A general-purpose processor can be a microprocessor or any conventional processor. Furthermore, processor 62 can be implemented using integrated circuit chips.

[0086] In the above scheme, the main control device 60 executes the chessboard arrangement method in any of the aforementioned embodiments. On the one hand, it achieves automatic notation of the game sequence without manual notation, which helps reduce labor costs. On the other hand, in response to the undo command, it directly determines the target chessboard based on the game sequence and controls the chessboard device to arrange the actual chessboard without manually re-placing the pieces, which helps improve efficiency. Furthermore, if a new game operation is detected by the user, the chessboard device is controlled to skip the pieces associated with the newly executed game operation during the chessboard arrangement process, thereby avoiding unnecessary arrangement of the user's next move as much as possible, which helps improve efficiency. Therefore, it can reduce the cost of performing the undo operation and improve the efficiency of performing the undo operation.

[0087] Please see Figure 7 , Figure 7This is a schematic diagram of a framework of an embodiment of the chess-playing device 70 of this application. The chess-playing device 70 includes a display device 71, a chess-playing device 72, and a main control device 73 as described in any of the above embodiments. The display device 71 and the chess-playing device 72 are respectively coupled to the main control device 73. The display device 71 is used to display the chess-playing interface under the control of the main control device 73, and the chess-playing device 72 is used to perform chess-playing operations under the control of the main control device 73. For details on the chess-playing interface and chess-playing operations, please refer to the relevant descriptions in the foregoing disclosed embodiments, which will not be repeated here.

[0088] In one implementation scenario, the display device 71 can be configured as a touch display; or, the display device 71 can also be configured as a non-touch display. In this case, in order to facilitate the user to input information to the main control device 73, the game device 70 may further include an input device (not shown). For details, please refer to the relevant descriptions in the foregoing disclosed embodiments, which will not be repeated here.

[0089] In one implementation scenario, the display device 71 can be set on the side of the real chessboard facing the user, and the chess-playing device 72 can be set on the side of the real chessboard adjacent to the display device 71, or the chess-playing device 72 can be set on the same side as the display device 71, without limitation.

[0090] In one implementation scenario, the display device 71 and the chess-playing device 72 can be set separately, or the display device 71 and the chess-playing device 72 can be set together, without limitation.

[0091] In the above-described scheme, the chess-playing device 70 includes a main control device 73 as described in any of the above embodiments. On one hand, it achieves automatic notation of the game sequence without manual notation, helping to reduce labor costs. On the other hand, in response to a reversal command, it directly determines the target board based on the game sequence and controls the chess-playing device to rearrange the actual board without manually repositioning the pieces, thus improving efficiency. Furthermore, if a new game operation is detected by the user, the device skips the associated pieces during board rearrangement, thereby minimizing unnecessary rearrangement for the user's next move and further improving efficiency. Therefore, it can reduce the cost of performing a reversal operation and improve its efficiency.

[0092] Please see Figure 8 , Figure 8 This is a schematic diagram of a framework of an embodiment of the computer-readable storage medium 80 of this application. The computer-readable storage medium 80 stores program instructions 81 that can be executed by a processor. The program instructions 81 are used to implement the steps in any of the above-described chessboard arrangement method embodiments.

[0093] The above-described solution, implemented by the computer-readable storage medium 80, allows for the execution of the steps described in the chessboard arrangement method embodiment. On one hand, it achieves automatic notation of the game sequence without manual notation, reducing labor costs. On the other hand, in response to a reversal command, it directly determines the target chessboard based on the game sequence and controls the chessboard device to arrange the actual chessboard without manual repositioning, improving efficiency. Furthermore, if a new game operation is detected, the chessboard device skips the associated pieces during the chessboard arrangement process, minimizing unnecessary arrangement for the user's next move and further improving efficiency. Therefore, it reduces the cost of reversing a move and improves the efficiency of reversing a move.

[0094] In some embodiments, the functions or modules of the apparatus provided in this disclosure can be used to perform the methods described in the above method embodiments. The specific implementation can be referred to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.

[0095] The description of the various embodiments above tends to emphasize the differences between the various embodiments. The similarities or similarities between them can be referred to, and for the sake of brevity, they will not be repeated here.

[0096] In the several embodiments provided in this application, it should be understood that the disclosed methods and apparatus can be implemented in other ways. For example, the apparatus implementations described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0097] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.

[0098] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0099] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods of various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0100] If the technical solution of this application involves personal information, the product using this technical solution has clearly informed the user of the personal information processing rules and obtained the user's voluntary consent before processing the personal information. If the technical solution of this application involves sensitive personal information, the product using this technical solution has obtained the user's separate consent before processing the sensitive personal information, and also meets the requirement of "express consent". For example, at personal information collection devices such as cameras, clear and prominent signs are set up to inform users that they have entered the scope of personal information collection and that personal information will be collected. If an individual voluntarily enters the collection scope, it is deemed that they have agreed to the collection of their personal information; or on the personal information processing device, with clear signs / information informing users of the personal information processing rules, authorization is obtained from the individual through pop-up information or by asking the individual to upload their personal information; wherein, the personal information processing rules may include information such as the personal information processor, the purpose of personal information processing, the processing method, and the types of personal information processed.

Claims

1. A method for arranging chess pieces, characterized in that, include: In response to a move-recall instruction, the target board to be returned by the move-recall instruction is determined based on the game sequence; wherein each node in the game sequence represents the board after performing a game operation. The control device organizes the real chess pieces on the real chessboard, and if a new chess-playing operation performed by the user on the real chessboard is detected during the chess-playing process, it checks whether the new chess-playing operation conforms to the rules of chess moves; wherein, the new chess-playing operation refers to the next chess-playing operation performed by the user during the chess-playing process. In response to the newly executed chess-playing operation conforming to the chess-playing rules, the chess-playing device is controlled to skip the associated pieces of the newly executed chess-playing operation during the chess-playing process, and to continue adding new nodes under the latest current node in the chess-playing sequence until the local chess-playing surface on the actual chessboard, excluding the associated pieces, is consistent with the target chess-playing surface; wherein, the chess-playing surface corresponding to the newly added node is the chess-playing surface after the newly executed chess-playing operation is superimposed on the target chess-playing surface.

2. The method according to claim 1, characterized in that, Prior to responding to the undo instruction, the method further includes: In response to a confirmation instruction following a selection instruction for a target node in the game sequence, the undo instruction is generated; wherein the target node is any node other than the current node in the game sequence, and the confirmation instruction indicates the start of a game on the real chessboard; Determining the target board to be returned by the undo instruction based on the game sequence includes: The selected node in the game sequence is determined as the new current node, and the board corresponding to the new current node is selected as the target board.

3. The method according to claim 2, characterized in that, The method further includes: Based on the new current node, determine the target player to perform the next move on the target board. Determine whether the target player is a user; The associated pieces for which the chess-playing device skips the newly executed chess-playing operation during the chessboard arrangement process include: In response to the target player being a user, the step of controlling the game device to skip the associated pieces of the newly executed game operation during the game board arrangement process is performed.

4. The method according to claim 3, characterized in that, The method further includes: In response to the target player being the local machine, the game device is controlled to rearrange the actual game board to match the target game board.

5. The method according to claim 1, characterized in that, Prior to responding to the undo instruction, the method further includes: Receive undo commands triggered during the game; Determining the target board to be returned by the undo instruction based on the game sequence includes: Based on the two players, the number of moves to undo a move is determined. Then, using the corresponding node of the actual chess board in the game sequence as a reference, the number of moves to undo a move is moved towards the root node to determine the new current node. Finally, the chess board corresponding to the new current node is selected as the target chess board.

6. The method according to claim 5, characterized in that, The determination of the number of moves to undo a move, based on both players, includes at least one of the following: In response to the representation of human-computer interaction between the two players, the number of moves to undo a move is determined based on the player who made the move corresponding to the current node. In response to the self-play of the two players, the number of moves to undo a move is determined to be 1.

7. The method according to claim 6, characterized in that, The determination of the number of undo moves based on the player executing the move corresponding to the current node includes at least one of the following: In response to the fact that the player performing the chess operation corresponding to the current node is a user, the number of undo moves is determined to be 1. In response to the fact that the player performing the move corresponding to the current node is the local machine, the number of moves to undo a move is determined to be 2.

8. The method according to any one of claims 1 to 7, characterized in that, The method further includes: The virtual chessboard on the control interface is synchronized with the real chessboard in real time, and the differences between the real chessboard and the target chessboard are determined in real time. The control prompts the difference in the chess pieces.

9. The method according to claim 8, characterized in that, The control prompts the difference pieces, including at least one of the following: Control the display of sorting marks on the grid points where the differing pieces are located in the virtual chessboard; Control the display of the first prompt message on the chess interface; Control the playback of the second prompt message; The sorting marker, the first prompt message, and the second prompt message are all used to prompt the sorting of the difference pieces.

10. The method according to any one of claims 1 to 7, characterized in that, The control device for playing chess organizes the actual chess pieces on the real chessboard, including: Compare the actual chessboard with the target chessboard to identify the different pieces; wherein, the different pieces include at least one of the pieces to be added or the pieces to be removed. The chess-playing device is controlled to process the chess pieces to be removed and the chess pieces to be added in sequence.

11. A chessboard arrangement device, characterized in that, include: A determination module is used to determine the target board that the undo command expects to return based on the game sequence in response to an undo command; wherein each node in the game sequence represents the board after performing a game operation. The organization module is used to control the chess-playing device to organize the real chess pieces on the real chessboard. It is also used to, if a new chess-playing operation performed by the user is detected on the real chessboard during the organization process, and the new chess-playing operation conforms to the move rules, control the chess-playing device to skip the associated pieces of the newly executed chess-playing operation during the organization process, and control the device to continue adding new nodes under the latest current node in the chess-playing sequence until the local chess pieces on the real chessboard other than the associated pieces match the target chess piece. Here, the newly executed chess-playing operation represents the next chess-playing operation performed by the user during the organization process, and the chess piece corresponding to the newly added node is the chess piece after the newly executed chess-playing operation is superimposed on the target chess piece. An operation detection module is used to detect whether the newly executed chess operation conforms to the chess move rules.

12. A computer-readable storage medium, characterized in that, The device stores program instructions that can be executed by a processor, the program instructions being used to implement the chessboard arrangement method according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Interaction method of electric chess type chessboard with computer system

    CN101380515A

  • Chess set for human-computer fighting, chess set system and interaction method

    CN105413154A

  • Data analysis method and device, electronic equipment and storage equipment

    CN116108228A