Virtual chess piece control method and device, equipment, storage medium and program product
By dividing virtual chess grids in auto-chess games and controlling the movement of the chess pieces to the path with the smallest number of chess pieces for interaction, the problem of ineffective movement of chess pieces is solved, and the winning rate of chess pieces and the strategy of the game is improved.
Patent Information
- Application Number
- CN202410178213.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-02-08
- Publication Date
- 2025-08-08
AI Technical Summary
In the prior art, the movement of chess pieces in the auto-chess game is relatively simple and cannot adapt to complex game situations, resulting in the movement of chess pieces being ineffective enough.
By dividing virtual chess grids in the virtual scene, the virtual chess pieces are controlled to move to the target virtual chess grid. The target chess grid is adjacent to the current chess grid and on the target path, the target path contains the smallest number of virtual chess grids, and interacts with the second virtual chess pieces within the interaction range.
It improves the movement effectiveness and winning rate of virtual chess pieces, and enhances the strategic nature of virtual games.
Smart Images

Figure CN120437599A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of virtual world technology, and in particular to a method, device, equipment, storage medium, and program product for controlling virtual chess pieces. Background Art
[0002] Auto Chess is a turn-based chess game in which players select virtual chess pieces (usually referred to as "pieces") from newly acquired virtual chess pieces or from existing virtual chess pieces, and then automatically battle against the enemy's virtual chess piece lineup.
[0003] In the related art, there are usually multiple enemy chess pieces, and the chess piece can automatically select the enemy chess piece with the closest logical distance among all enemy chess pieces as the battle target based on its own position and the positions of all enemy chess pieces.
[0004] However, in the above solution, the movement of chess pieces is relatively simple and cannot adapt to complex game situations. Summary of the Invention
[0005] The present application provides a method, device, equipment, storage medium and program product for controlling virtual chess pieces, which can ensure the effectiveness of moving virtual chess pieces; the technical solution is as follows.
[0006] According to one aspect of the present application, a method for controlling a virtual chess piece is provided, the method comprising:
[0007] A scene interface for displaying a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are each located in one of the virtual chess squares;
[0008] In response to the second virtual chess piece not being present within the interactive range of the first virtual chess piece, controlling the first virtual chess piece to move to a target virtual chess square; the target virtual chess square being adjacent to the virtual chess square where the first virtual chess piece was located before the movement, and the target virtual chess square being located on a target path; the target path being the path containing the fewest virtual chess squares among the reference paths; and the reference path being the path along which the first virtual chess piece moves to the second virtual chess piece through the adjacent virtual chess squares in sequence;
[0009] In response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece being within the interaction range of the first virtual chess piece, the first virtual chess piece is controlled to interact with the second virtual chess piece within the interaction range.
[0010] According to one aspect of the present application, a device for controlling a virtual chess piece is provided, the device comprising:
[0011] an interface display module, configured to display a scene interface of a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece, and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are each located in one of the virtual chess squares;
[0012] a movement control module configured to, in response to the absence of the second virtual chess piece within the interaction range of the first virtual chess piece, control the first virtual chess piece to move to a target virtual chess square; the target virtual chess square being adjacent to the virtual chess square where the first virtual chess piece was located before the movement, and the target virtual chess square being located on a target path; the target path being the path containing the fewest virtual chess squares among the reference paths; and the reference path being the path along which the first virtual chess piece moves to the second virtual chess piece, sequentially passing through the adjacent virtual chess squares.
[0013] The interaction control module is configured to control the first virtual chess piece to interact with the second virtual chess piece within the interaction range in response to the first virtual chess piece being within the target virtual chess square and the second virtual chess piece being within the interaction range of the first virtual chess piece.
[0014] In some embodiments, the apparatus further comprises: an information acquisition module configured to:
[0015] In response to the absence of the second virtual chess piece within the interactive range of the first virtual chess piece, obtaining position information of at least two virtual chess squares adjacent to each other of the second virtual chess pieces;
[0016] acquiring each of the reference paths based on position information of virtual chess squares adjacent to at least two of the second virtual chess pieces and position information of the virtual chess square where the first virtual chess piece is located;
[0017] Obtaining the number of virtual chess squares contained in each of the reference paths;
[0018] The target path is determined from each of the reference paths based on the number of virtual squares contained in each of the reference paths.
[0019] In some embodiments, the information acquisition module is further used to re-acquire position information of at least two virtual chess squares adjacent to each other of the second virtual chess pieces in response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece not being within the interaction range of the first virtual chess piece.
[0020] In some embodiments, the information acquisition module is configured to select a reference path from the multiple reference paths as the target path in response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths.
[0021] In some embodiments, the information acquisition module is used to determine the path with the least number of changes in moving direction among the multiple reference paths as the target path in response to the reference path with the least number of virtual chess squares among the reference paths comprising multiple reference paths.
[0022] In some embodiments, the information acquisition module is used to determine the path with the shortest reference distance among the multiple reference paths as the target path in response to the reference path containing the least number of virtual chess squares among the reference paths containing multiple reference paths; the reference distance is the straight-line distance between the first virtual chess piece and the last virtual chess square in the reference path.
[0023] In some embodiments, the information acquisition module is used to determine the path in the multiple reference paths where the corresponding second virtual chess piece is closest to the designated area as the target path in response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths.
[0024] In some embodiments, the information acquisition module is used to determine the path passing through the designated area among the multiple reference paths as the target path in response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths.
[0025] In some embodiments, the designated area is the central area of the virtual venue; or,
[0026] The designated area is an area in the virtual field having a designated effect.
[0027] In some embodiments, the information acquisition module is used to determine the reference path with the weakest or strongest interactive ability of the corresponding second virtual chess piece among the multiple reference paths as the target path in response to the reference path with the least number of virtual chess squares among the reference paths containing multiple reference paths.
[0028] In some embodiments, the information acquisition module is used to determine the reference path with the highest or lowest designated attribute value of the corresponding second virtual chess piece among the multiple reference paths as the target path in response to the reference path with the least number of virtual chess squares among the reference paths containing multiple reference paths.
[0029] In some embodiments, the information acquisition module is used to determine, in response to the reference path containing the least number of virtual chess squares among the reference paths including multiple reference paths, the reference path among the multiple reference paths in which there is no designated terrain on the straight line between the corresponding second virtual chess piece and the first virtual chess piece as the target path.
[0030] According to another aspect of the present application, a computer device is provided, comprising a processor and a memory, wherein the memory stores at least one computer instruction, and the at least one computer instruction is loaded and executed by the processor to implement the method for controlling a virtual chess piece as described above.
[0031] According to another aspect of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores at least one computer instruction, and the at least one computer instruction is loaded and executed by a processor to implement the control method of the virtual chess piece as described above.
[0032] According to another aspect of the present application, a computer program product is provided, which includes computer instructions stored in a computer-readable storage medium. A processor reads and executes the computer instructions from the computer-readable storage medium to implement the control method of the virtual chess piece as described above.
[0033] The technical solutions provided by the embodiments of the present application may have the following beneficial effects:
[0034] In the solution shown in the embodiment of the present application, a computer device can control a first virtual chess piece to interact with a second virtual chess piece within an interaction range; when the second virtual chess piece does not exist within the interaction range of the first virtual chess piece, the computer device can control the first virtual chess piece to move to a target virtual chess square that is closer to the second virtual chess piece; this solution determines the target virtual chess square based on the number of virtual chess squares included in the path of the first virtual chess piece moving sequentially through adjacent virtual chess squares to the second virtual chess piece, which can ensure the effectiveness of moving the first virtual chess piece, improve the winning rate of the first virtual chess piece, and thereby improve the strategy of the virtual game. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0036] Figure 1This is a structural block diagram of a computer system provided by one embodiment of the present application;
[0037] Figure 2 This is a flow chart of a game interaction method for a turn-based chess game provided by one embodiment of the present application;
[0038] Figure 3 This is a schematic diagram of an interface for a turn-based chess game provided by one embodiment of the present application;
[0039] Figure 4 This is a card diagram of a chess piece card provided by one embodiment of the present application;
[0040] Figure 5 This is a card diagram of an effect card provided by one embodiment of the present application;
[0041] Figure 6 This is a card diagram of an equipment card provided by one embodiment of the present application;
[0042] Figure 7 This is a card diagram of a chess player card provided by one embodiment of the present application;
[0043] Figure 8 This is a flow chart of a game interaction method for a turn-based chess game provided by one embodiment of the present application;
[0044] Figure 9 This is a schematic diagram of a chess player selection interface provided by an embodiment of the present application;
[0045] Figure 10 This is a schematic diagram of a game interface in the preparation phase provided by an embodiment of the present application;
[0046] Figure 11 This is a schematic diagram of the interface for playing cards in the preparation phase provided by one embodiment of the present application;
[0047] Figure 12 This is a schematic diagram of an upgrade process of an upgrade button provided by an embodiment of the present application;
[0048] Figure 13 This is a schematic diagram of an upgrade process of an upgrade button provided by an embodiment of the present application;
[0049] Figure 14 This is a schematic diagram of a game interface during the battle phase provided by one embodiment of the present application;
[0050] Figure 15 This is a schematic diagram of a settlement interface provided by an embodiment of the present application;
[0051] Figure 16This is a flow chart of a method for controlling a virtual chess piece provided by one embodiment of the present application;
[0052] Figure 17 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0053] Figure 18 This is a flow chart of a method for controlling a virtual chess piece provided by one embodiment of the present application;
[0054] Figure 19 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0055] Figure 20 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0056] Figure 21 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0057] Figure 22 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0058] Figure 23 This is a flowchart of a multi-stage pathfinding system for determining a target chess piece provided by an embodiment of the present application;
[0059] Figure 24 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0060] Figure 25 This is a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application;
[0061] Figure 26 is a block diagram of a control device for a virtual chess piece shown in an exemplary embodiment of the present application;
[0062] Figure 27 It is a structural block diagram of a computer device provided by an exemplary embodiment of the present application.
[0063] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application. DETAILED DESCRIPTION
[0064] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0065] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.
[0066] The terms used in this disclosure are for the purpose of describing specific embodiments only and are not intended to limit the disclosure. As used in this disclosure and the appended claims, the singular forms "a," "an," "the," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and / or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
[0067] In the embodiments of this application, the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, storage, and display, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use, and processing of relevant data must comply with the relevant laws, regulations, and standards of the relevant countries and regions. For example, the object behaviors such as attack operations involved in this application are all obtained with full authorization.
[0068] It should be understood that although the terms first, second, etc. may be used in this disclosure to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. For example, a first parameter may also be referred to as a second parameter, and similarly, a second parameter may also be referred to as a first parameter without departing from the scope of this disclosure. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".
[0069] First, the nouns involved in the embodiments of this application are introduced:
[0070] Turn-based chess games: These are chess games in which the "chess pieces" are arranged in advance before the game begins, and during the game, the "chess pieces" can automatically fight according to the pre-arranged layout. The "chess pieces" are usually represented by virtual characters, such as virtual heroes. During the game, the virtual characters automatically unleash various skills to fight. The game usually adopts a turn-based system. When all the "chess pieces" of one side are killed (i.e., the health points of the virtual characters are reduced to zero), that side is deemed the loser of the round. In some embodiments, in addition to the "chess piece-type virtual characters" that play the game, each side also has a chess player character representing the current user participating in the game. The chess player character cannot be moved as a "chess piece" to the battle area or chess piece candidate area. The chess player character is also equipped with health points (or health points). The health points of the chess player character are reduced accordingly (battle failure) or remain unchanged (battle victory) based on the results of each game. When the health points of the virtual character are reduced to zero, the user corresponding to the chess player character exits the game, and the remaining users continue to play. Optional, turn-based chess games include Auto Chess.
[0071] Auto Chess: It is a multiplayer, turn-based competitive game with collectible hero chess pieces. For example, there are eight or six players in the game, each of whom occupies an area on the board. Two of the multiple players compete one-on-one. Each round of a game consists of two stages: the preparation phase and the battle phase. In the preparation phase, users purchase chess pieces (heroes) from the store and arrange them on the board. In the battle phase, both teams lock their lineups, and the chess pieces will automatically engage until all of one team's pieces are dead. The player who destroys all of their chess pieces loses the round and will have a certain amount of health deducted. The game rounds are repeated, and new opponents are matched until a player's health is ≤ 0 and they are eliminated. The last remaining player wins the game (1st place).
[0072] Chessboard: refers to the area in the battle interface of a turn-based chess game used to prepare for and conduct battles. The chessboard can be any one of a two-dimensional virtual chessboard, a 2.5-dimensional virtual chessboard, and a three-dimensional virtual chessboard, and this application does not limit this.
[0073] The traditional Auto Chess board is divided into a battle area and a piece candidate area. The battle area includes several equally sized squares, which are used to place the pieces that will be used in the battle. The piece candidate area includes several candidate pieces, which are used to place candidate pieces. These candidate pieces do not participate in the battle but can be dragged and placed in the battle area during the preparation phase. The board area provided in the embodiments of this application does not include the piece candidate area, but only the battle area.
[0074] Regarding the arrangement of the chess squares in the battle area, in some embodiments, the battle area includes n (rows) × m (columns) chess squares, schematically, n is an integer multiple of 2, and two adjacent rows of chess squares are aligned, or two adjacent rows of chess squares are staggered. In addition, the battle area is divided into two parts according to the rows, namely the own battle area and the enemy battle area, and the users participating in the battle are located on the upper and lower sides of the battle interface, and in the preparation stage, the users can only place chess pieces in the own battle area. In other embodiments, the battle area is divided into two parts according to the columns, namely the own battle area and the enemy battle area, and the users participating in the battle are located on the left and right sides or the upper and lower sides of the battle interface. The shape of the chess square can be any one of square, rectangle, circle, and hexagon. The embodiment of the present application does not limit the shape of the chess square.
[0075] Cards: A common term for a game genre, originating from tabletop games. Unlike chess, where players manipulate chess pieces directly, cards represent game content on cards. Compared to chess pieces, cards are more convenient for carrying text descriptions, card attribute information, and key values. "Cardization" involves converting hero resources into card resources, making it easier for players to understand and categorize card effects, and to carry more diverse information.
[0076] Energy: A game resource. In this application, energy is defined as the resource used by players to play cards. When a card is played, the energy corresponding to the value marked on the card is consumed.
[0077] Equipment: In Auto Chess games, each chess piece can typically wear three pieces of equipment (or other equipment). Equipment provides attributes or effects such as attack power, defense, health, healing, penetration, and shields to the hero. Auto Chess games in related art typically include a jungle phase, where players defeat monsters and receive equipment dropped by them, which they then pick up and add to their backpacks. Equipment can also be combined individually to create higher-quality equipment.
[0078] Player: refers to a virtual character played by the player. Each player has different special abilities that can help the player to play the game better.
[0079] Figure 1 The following is a block diagram of a computer system according to an exemplary embodiment of the present application: The computer system 100 includes a first terminal 110 , a server 120 , and a second terminal 130 .
[0080] A first terminal 110 has a client 111 installed and running that supports a virtual environment. This client 111 may be a turn-based chess game program. When the first terminal runs client 111, the user interface of client 111 is displayed on the screen of the first terminal 110. This client may be a client for an Auto Chess game. First terminal 110 is used by a first user 112. During the preparation phase of a game, first user 112 uses first terminal 110 to place chess pieces in the battle area of the chessboard. During the battle phase, first terminal 110 or server 120 automatically controls the chess pieces based on the attributes, skills, and placement of the pieces in the battle area.
[0081] The second terminal 130 has a client 131 installed and running that supports a virtual environment. This client 131 can be a turn-based chess game program. When the second terminal 130 runs the client 131, the user interface of the client 131 is displayed on the screen of the second terminal 130. This client can be the client of an Auto Chess game. The second terminal 130 is used by a second user 132. During the preparation phase of a game, the second user 132 uses the second terminal 130 to place chess pieces in the battle area of the chessboard. During the battle phase, the second terminal 130 or the server 120 automatically controls the chess pieces based on the attributes, skills, and placement of the pieces in the battle area.
[0082] Optionally, the chess pieces placed by the first user via the first terminal 110 and the second user via the second terminal 130 are located in different playing areas on the same chessboard, i.e., the first user and the second user are on the same chessboard in the same game. Alternatively, the chess pieces placed by the first user via the first terminal 110 and the second user via the second terminal 130 are located on different chessboards, i.e., the first user and the second user are on different chessboards in the same game. It should be noted that, in an optional embodiment, a game of a turn-based chess game is jointly participated in by six user accounts, and the six user accounts are matched up in pairs in each round, and the two matched user accounts play against each other on the same chessboard during the round.
[0083] Optionally, the client installed on the first terminal 110 and the second terminal 130 is the same, or the client installed on the two terminals is the same type of client on different operating system platforms (Android or iOS). The first terminal 110 can generally refer to one of multiple terminals, and the second terminal 130 can generally refer to another of the multiple terminals. This embodiment only uses the first terminal 110 and the second terminal 130 as an example. The first terminal 110 and the second terminal 130 can be the same or different device types, including at least one of a smartphone, a tablet computer, an e-book reader, an MP3 player, an MP4 player, a laptop computer, and a desktop computer. The following embodiments are described using the example of a smartphone as the terminal.
[0084] Those skilled in the art will appreciate that the number of terminals may be greater or less. For example, there may be only one terminal (i.e., the user plays against the AI), or there may be six, eight, or more terminals. The present embodiment does not limit the number of terminals or device types.
[0085] Figure 1 Only two terminals are shown, but in different embodiments, multiple other terminals 140 can access the server 120. Optionally, one or more terminals 140 are terminals corresponding to developers. A development and editing platform for a client that supports a virtual environment is installed on the terminal 140. The developer can edit and update the client on the terminal 140 and transmit the updated client installation package to the server 120 via a wired or wireless network. The first terminal 110 and the second terminal 130 can download the client installation package from the server 120 to update the client.
[0086] The first terminal 110 , the second terminal 130 , and the other terminals 140 are connected to the server 120 via a wireless network or a wired network.
[0087] Server 120 includes at least one of a single server, multiple servers, a cloud computing platform, and a virtualization center. Server 120 provides backend services for clients supporting a three-dimensional virtual environment (turn-based chess game clients / Auto Chess game clients). Optionally, server 120 performs primary computing tasks, while terminals perform secondary computing tasks; alternatively, server 120 performs secondary computing tasks, while terminals perform primary computing tasks; alternatively, server 120 and terminals utilize a distributed computing architecture for collaborative computing.
[0088] In an illustrative example, the server 120 includes a processor 122, a user account database 123, a battle service module 124, and a user-facing input / output interface (I / O interface) 125. The processor 122 is configured to load instructions stored in the server 120 and process data in the user account database 123 and the battle service module 124. The user account database 123 is configured to store user account data used by the first terminal 110, the second terminal 130, and other terminals 140, such as user account avatars, user account nicknames, user account combat power indexes, and the service areas where the user accounts are located. The battle service module 124 is configured to provide multiple battle rooms for users to engage in battles. The user-facing I / O interface 125 is configured to establish communication and exchange data with the first terminal 110 and / or the second terminal 130 via a wireless network or a wired network.
[0089] The embodiment of the present application provides a turn-based chess game (auto chess) based on card operations. The various complicated operations involved in traditional auto chess, such as store purchases, store upgrades, chess piece preparations, chess piece deployments, chess piece upgrades, and chess piece equipment additions, are all simplified in the card playing process. On the one hand, the card-based playing process is relatively simple and suitable for use on small-screen terminals such as mobile phones and tablets; on the other hand, the three-dimensional model of the virtual chess piece can only carry limited text information, while the card face can carry more "labels", "values", "attributes", "entry effects" and other information, thereby improving the utilization efficiency of the display area where the card is located.
[0090] Figure 2 A flowchart of a game interaction method for a turn-based chess game provided by an exemplary embodiment of the present application is shown. This embodiment takes the method as an example executed by a terminal, in which a client supporting turn-based chess games is running.
[0091] The method includes:
[0092] Step 220: Displaying a game interface of a turn-based chess game, the game interface including a chessboard area and a hand area, wherein the hand area displays at least one card;
[0093] The game interface is where two player objects play against each other in a turn-based chess game. Player objects can be understood as at least one of the following concepts: user, account, player, chess player, or virtual chess player.
[0094] Combined with reference Figure 3 The game interface includes a chessboard area 10 and a hand area 11.
[0095] The chessboard area 10 is used to accommodate at least one friendly chess piece and at least one enemy chess piece participating in the battle. The chessboard area 10 includes a plurality of chess squares 12 arranged in an array. These chess squares 12 are always displayed or displayed only at certain times. Optionally, the chessboard area 10 is a two-dimensional chessboard or a three-dimensional chessboard. This embodiment illustrates the chessboard area 10 as a three-dimensional chessboard viewed from above. A three-dimensional chessboard in this context refers to the chessboard being located in a three-dimensional environment, not necessarily the chessboard itself being three-dimensional.
[0096] The hand area 11 is used to display at least one card held or dealt to the player object. This at least one card is typically a plurality of cards. This at least one card includes at least one of the following: cards automatically drawn or dealt to the player object by the background program, cards obtained by playing certain cards with draw effects, and player cards acquired through player skills. This plurality of cards has an upper limit, for example, a maximum of eight cards; excess cards are automatically discarded.
[0097] Optionally, the multiple cards are arranged in a fan-shaped pattern in the hand area 11. The order of arrangement can be determined based on at least one of the following factors: the time of draw, the card type, the number of cards of the same type, the number of cards of the same card, and the quality of the cards. Optionally, at least one card held by the player object has an upper limit, such as a maximum of 8 or 10 cards. When the upper limit is exceeded, the excess cards are discarded. The player object can play all or part of the cards in each battle round. Optionally, the player object can also replace all or part of the cards in each battle round. Optionally, different cards have different card types. Different card types have different battle preparation functions.
[0098] A round of turn-based chess and card games consists of multiple rounds, each of which includes a preparation phase and a battle phase.
[0099] Step 240: In the preparation phase, in response to the play operation of at least one card, perform preparation operations related to the own side;
[0100] The playing operation refers to the operation of playing one or more cards held. Schematically, the playing operation is the operation of dragging a selected card toward the board area. Alternatively, the playing operation includes a first click operation and a second click operation, wherein the first click operation is the operation of clicking to select a card, and the second click operation is the operation of clicking a specific square in the board area. The embodiments of the present application do not limit the specific form of the playing operation. In some embodiments, a function of intelligently recommending playing cards can also be provided, whereby the player object plays cards on behalf of the player in certain rounds, such as the client intelligently recommending playing cards for novice players in the first few rounds.
[0101] At least one local chess piece is a virtual chess piece that has participated in at least one round (including the current round). If the chessboard area is a two-dimensional chessboard, the virtual chess piece is also a two-dimensional chess piece, displayed as a two-dimensional icon or two-dimensional image; if the chessboard area is a three-dimensional chessboard, the virtual chess piece is also a three-dimensional chess piece, displayed as a three-dimensional model or three-dimensional image. In the initial state, there may be zero local chess pieces on the chessboard area, and the local player object can add, delete, or supplement the chessboard area. Local chess pieces that did not die in the previous round are automatically carried over to the next round.
[0102] The display state of the selected card is different from the display state of the unselected card. Optionally, the selected card has a highlighting effect, which includes: a bold border, a highlighted border, a dynamic border, and the placement position in the card queue is moved a preset distance toward the board area.
[0103] Preparation operations include at least one of: increasing one's own chess pieces, reducing one's own chess pieces, upgrading one's own chess pieces, adding equipment to one's own chess pieces, reducing equipment to one's own chess pieces, and increasing the buff effect of one's own chess pieces.
[0104] Since different card types have different effects, a preparation operation is performed on at least one of the own chess pieces in the chessboard area based on the card type of the selected card.
[0105] During the preparation phase, the player object will prepare at least one of its own chess pieces in the chessboard area, and the enemy player object will prepare at least one enemy chess piece in the chessboard area.
[0106] Step 260: During the battle phase, the own chess piece and the enemy chess piece are automatically engaged in battle in the chessboard area.
[0107] The automatic battle process between your own chess pieces and enemy chess pieces in the chessboard area does not require manual control by your own player object. The client or server automatically controls the battle between the chess pieces of both sides based on the chess position on the chessboard, chess piece attributes, chess piece level, chess piece skills, chess piece attributes, joint enhancement attributes between chess pieces, etc., until all the chess pieces of one side are killed.
[0108] Both the player object and the enemy player object have health points. After the round ends, the health points of the losing player object will be deducted by a certain amount. This amount can be determined based on the number of chess pieces remaining on the winning side, or it can be a fixed value, which is not limited in this embodiment.
[0109] In summary, the method provided in this embodiment, by introducing a "card" mechanism into a turn-based chess game, simplifies and integrates various battle preparation operations into the multi-card playing process, eliminating the concept of a shop. Players no longer need to repeatedly interact with multiple sub-areas on the traditional battle interface, such as the shop, chess piece preparation area, and chess piece battle area, to complete chess piece acquisition, upgrades, and battles. The traditional chess piece purchasing process, which requires users to actively select chess pieces, is replaced by a passive receipt of distributed cards. The game system replaces some of the user's tedious operations, allowing users to complete various battle preparation operations using essentially the same card playing operations as in a card game, thereby improving the efficiency of human-computer interaction.
[0110] Especially when playing turn-based chess games on small-screen terminals such as mobile phones or tablets, players can complete a variety of battle preparation operations based on the limited operations in the hand area. Compared with traditional auto chess, it can significantly improve the efficiency of human-computer interaction.
[0111] Classification of card types:
[0112] In some embodiments, the card type includes at least one of: a chess piece card, an effect card, an equipment card, and a chess player card.
[0113] Chess Cards:
[0114] Pawn cards are used to summon your own pieces in the chessboard area or upgrade the piece level of your own pieces. Figure 4 A schematic diagram of a chess piece card is shown. The chess piece card displays at least one of the following information: a chess piece image 21, a chess piece name 22, the energy consumed when the card is played 23, the chess piece type or faction 24 to which the chess piece belongs, the level of the chess piece after the card is played 25, and a description of the additional effects of the chess piece 26.
[0115] The chess piece image 21 may be at least one of a head portrait, an icon, a bust portrait, a full-body portrait, and a display animation of a virtual chess piece. Figure 4 In the example, the chess piece image 21 is a bust of a virtual chess piece.
[0116] The chess piece name 22 is the name of the virtual chess piece. For example, if the virtual chess piece is a hero, the chess piece name is the hero name.
[0117] The energy value 23 refers to the energy required to play this chess piece. This energy value is an integer. Energy is a resource in turn-based chess games. Optionally, playing cards of different qualities requires different amounts of energy. For example, playing five cards of different qualities requires 0, 1, 2, 3, and 4 energy points, respectively.
[0118] Piece Type 24 is a categorization attribute that identifies the role a piece plays during combat. In one example, different pieces can be classified as at least one of the following: Tank, Warrior, Assassin, Mage, Shooter, or Support. Faction is a categorization attribute that identifies pieces belonging to the same group within the virtual worldview. In one example, different pieces can be classified into at least one of the following: Great Wall, Three Kingdoms, Xuanyong, Jigan, Yaotian, and Chang'an. For example, two pieces belonging to the same Great Wall Guards in the virtual worldview both belong to the Great Wall Faction. In various embodiments, piece type and faction can be considered the same categorization attribute; this embodiment uses piece type and faction as different categorization attributes as an example.
[0119] The level 25 that a piece is upgraded to after a card is played refers to the level that is increased after the card is played, if a piece with the same name (i.e., the same piece) already exists on the board. For example, if level 25 is 3 and the piece with the same name was originally at level 2, then after playing this card, the piece with the same name is upgraded to level 5. Alternatively, cards of different qualities can upgrade the same piece to different levels after being played. For example, five different quality cards can upgrade the same piece to levels 1, 2, 3, 4, and 5, respectively.
[0120] The additional effect description 26 of a chess piece is a description of the additional effect possessed by the chess piece. This additional effect can be triggered upon playing, or it can be activated when a trigger condition is met during the game. For example, chess piece 1 has an exclusive skill: when chess piece 1 is on the board, whenever another chess piece on the board is sold, a randomly selected chess piece of the "tank" type on the board is randomly selected, and the level of the randomly selected chess piece is increased by a first value, which is half the level of the sold chess piece.
[0121] Effect Cards:
[0122] Effect cards are cards used to apply effects to at least one game factor in the game. The at least one game factor includes chess pieces, skills, equipment, amplification effects, levels, combat processes, hand card acquisition processes, etc. Figure 5 A schematic diagram of an effect card is shown. The effect card displays at least one of the following information: an effect icon 31, an effect name 32, an energy value 33 consumed when the card is played, and an effect description 34 of the effect card.
[0123] The effect icon 31 may be an icon for representing the benefit effect of the effect card. Figure 5 The effect name 32 is the name of the effect card or the name of the gain effect.
[0124] The energy value 33 refers to the energy cost of playing this effect card. This energy value is an integer. Energy is a resource in turn-based chess games. Optionally, playing cards of different qualities may cost different amounts of energy. For example, playing five cards of different qualities may cost 0, 1, 2, 3, and 4 energy points, respectively.
[0125] The effect description 34 of the effect card is used to describe the effect of the effect card after use. The effect of the effect card includes but is not limited to at least one of the following:
[0126] 1. Increase the probability and / or quantity of chess cards obtained by your players;
[0127] 2. Increase the probability or number of players obtaining chess cards with the same name as the chess pieces on the field;
[0128] 3. Reduce the energy consumed by your players when acquiring chess cards;
[0129] 4. Increase the number of chess cards that your players can exchange for;
[0130] 5. Reduce the energy consumed by your players when exchanging chess cards;
[0131] 6. Improve the level of at least one chess piece on the field;
[0132] 7. Add equipment to at least one chess piece on the field;
[0133] 8. Upgrade the equipment level of at least one chess piece on the field;
[0134] 9. Reduce energy consumption when playing / changing cards;
[0135] 10. Increase the probability of obtaining certain cards;
[0136] 11. Increase the number of cards that can be obtained;
[0137] 12. Increase the chance of changing cards, and so on, I will not go into details one by one.
[0138] For example, the effect of the "Two Players" card is: randomly obtain 2 identical hero cards; the effect of the "Talent Search" card is: choose 1 of 3 highest quality hero cards available at the current player level; the effect of the "Copy" card is: randomly obtain a card with the same name as a hero on the field; the effect of the "Abundant Harvest" card is: immediately replenish your hand to 5 cards; the effect of the "Random Strengthen" card is: increase the level of a random hero on the field by +5; the effect of the "One More Time" card is: draw 1 card, and get 1 extra free card exchange in this round; the effect of the "Wish" card is: -1 the energy value consumed by all cards; the effect of the "Add Card" card is: draw 2 cards.
[0139] In some embodiments, effect cards can be categorized as at least one of general effect cards, piece-type effect cards, and faction effect cards. General effect cards are effect cards whose attributes are unrelated to piece type or faction. Card attributes include at least one of: acquisition conditions, usage conditions, card effects, and range of effect. Piece-type effect cards are effect cards whose attributes are related to piece type. For example, only pieces of a specific piece type can acquire, use, or benefit from a card. Faction effect cards are effect cards whose attributes are related to faction. For example, only pieces of a specific faction can acquire, use, or benefit from a card.
[0140] For example, a certain chess piece type effect card can only be obtained with a certain probability when a chess piece card of that chess piece type is played.
[0141] Equipment Cards:
[0142] Equipment cards are used to equip at least one of your own chess pieces. Figure 6A schematic diagram of an equipment card provided by an exemplary embodiment of the present application is shown. The equipment card displays at least one of the following information: an equipment icon 41, an equipment name 42, an energy value 43 consumed when the card is played, and an equipment description 44 of the equipment card.
[0143] The equipment icon 41 may be an icon used to represent an equipment image or equipment effect. Figure 6 The circular icon in the figure is used as an example. Equipment name 42 is the name of the equipment card or the name of the equipment. Different equipment can enhance the combat capability of the player's piece in different dimensions such as health, armor, defense, and mana, or weaken the combat capability of the enemy piece.
[0144] Energy value 43 refers to the amount of energy required to play this equipment card. This energy value is an integer. Energy is a resource in turn-based chess games. Optionally, cards of different qualities may require different amounts of energy to play. For example, five cards of different qualities may cost 0, 1, 2, 3, and 4 energy points to play, respectively. Optionally, the energy costs of different cards may be adjusted periodically or irregularly based on game balance.
[0145] The equipment description 44 of the equipment card is used to describe the effect of the equipment after being worn.
[0146] Chess player cards:
[0147] Player cards are cards acquired through the player skills of a player avatar. Player cards can be acquired through a passive skill of a player avatar, cards that only a certain player avatar can acquire, cards that only a certain player avatar can use, cards that are exclusive to a certain player avatar, and so on, and this embodiment of the application does not limit this.
[0148] Figure 7 A schematic diagram of a chess player card provided by an exemplary embodiment of the present application is shown. The chess player card displays at least one of the following information: a card icon 51, a chess player card name 52, an energy value 53 consumed when the card is played, and a description of the equipment 54 of the chess player card.
[0149] The card icon 51 may be an icon used to represent the effect of the card. Figure 7 The player card name 52 is the name of the player card or the name of the effect.
[0150] The energy value 53 refers to the energy consumed by the player when playing a card. This energy value is an integer. Energy is a resource in turn-based chess games. Optionally, cards of different qualities may consume varying amounts of energy when played. For example, playing five cards of different qualities may consume 0, 1, 2, 3, and 4 energy points, respectively. Optionally, the energy consumed by different cards may be adjusted periodically or irregularly based on game balance.
[0151] The effect description 54 of the player card is used to describe the effect that the player card can increase after use. The effect of the player card can be the same as or similar to the effect of the chess piece card, equipment card, or effect card, and can also exceed the effect range of the chess piece card, equipment card, or effect card. In the possible designs of different embodiments, the effect of the player card can be designed to summon chess pieces, upgrade chess pieces, add equipment, add gain effects, reduce energy consumption, or affect the acquisition process of the hand cards in any form. The effect of the player card can be designed to affect any process or detail in the game, and the embodiments of the present application are not limited to this.
[0152] Based on the introduction of the above four types of cards:
[0153] On the one hand, different types of cards have different functions. Piece cards can eliminate the shop in traditional Auto Chess based on the gameplay characteristics of the cards. Effect cards can eliminate the effect buttons or controls in traditional Auto Chess. Equipment cards can eliminate the jungle phase in traditional Auto Chess. Player cards can incorporate the gameplay characteristics of each player. By simplifying the different mechanics of turn-based chess games into the card-playing process based on different card types, this can reduce the number of user interface elements required to be displayed on the battle screen, simplify the operation of the player object, and improve the efficiency of human-computer interaction for the player object.
[0154] On the other hand, compared with three-dimensional chess pieces, two-dimensional cards cannot carry text information well because the text information that three-dimensional chess pieces can carry is limited. The card characteristics of two-dimensional cards can naturally carry more text information and icon information. Therefore, compared with the three-dimensional chess pieces in traditional preparation stages, two-dimensional cards can increase the amount of information carried within the limited display range of small-screen terminals and improve information transmission efficiency.
[0155] It should be noted that the above-mentioned cards can not only be played in the preparation phase, but some cards can also be played in the battle phase, such as certain equipment cards, effect cards that immediately draw 2 more cards, etc.
[0156] How to obtain cards:
[0157] The player object obtains at least one card if the acquisition conditions are met. The acquisition conditions include at least one of the following:
[0158] Obtaining Condition 1: Start a new round of turn-based battle. Each time a new round of turn-based battle starts, you will receive a certain number of cards. For example, the first round of turn-based battle will draw 4 cards, and the subsequent rounds of turn-based battle will draw 2 cards.
[0159] Acquisition Condition 2: Use a pre-set chess card. Pre-set chess cards are chess cards with additional abilities, such as drawing, adding, or duplicating cards. For example, a chess card with the same name as a currently playing chess piece will grant an additional effect card when played.
[0160] Acquisition condition 3: Use preset effect cards; preset effect cards refer to effect cards with effects such as drawing, adding, or copying cards.
[0161] Acquisition condition 4: Use preset player cards; preset player cards refer to effect cards that have effects such as drawing, adding, or copying cards.
[0162] Acquisition condition 5: Consume resources owned by the party in exchange; for example, consume energy to extract or exchange.
[0163] Acquisition condition 6: The player level of the chess player's virtual character is upgraded; after the chess player level is upgraded, higher quality or more cards can be unlocked.
[0164] Acquisition condition 7: Card pool level upgrade; after the card pool level is upgraded, you can unlock higher quality or more cards.
[0165] Obtaining condition 8: Purchase card operation.
[0166] Acquisition Condition 9: A preset player skill is triggered. A preset player skill is a passive skill that has the effect of extracting, adding, or duplicating cards. For example, you can extract a player card every two turns, or you can extract a player card every three cards played.
[0167] It should be noted that the above acquisition conditions can be combined. For example, some cards can only be obtained by using the preset player cards after reaching the player level 2. It should also be noted that the acquisition conditions for different types of cards can be completely different, completely the same, or some conditions can be the same and some different.
[0168] Figure 8 A flowchart of a method for interactively playing a turn-based chess game provided by an exemplary embodiment of the present application is shown. This embodiment uses the method executed by a terminal as an example. The method includes:
[0169] Player selection phase:
[0170] Step 320: Selecting a virtual chess player character of one's own side, where the virtual chess player character is used to represent a virtual character controlling at least one chess piece of one's own side;
[0171] Before each game begins, the player character selects their desired player avatar. Different player avatars have different player skills. Player skills are usually related to obtaining player cards, but can also be related to other game factors.
[0172] In some embodiments, different player skills have their own passive triggering mechanisms that allow the player character to obtain cards with special effects. For example, a player's skill effect is: every time three chess cards are played, the player obtains a Treasure Player card. The effect of this Treasure Player card is: consume 1 energy point and increase the level of a designated player on the board by 2.
[0173] For example, Figure 9 As shown, before starting a game, a player selection interface is displayed. This interface displays six virtual player characters selected by the player objects. Optionally, the virtual player character 61 selected by the player object is highlighted. For example, if the player object is player object 4, the virtual player character selected by player object 4 is highlighted in a standing, enlarged, and centered foreground manner. The virtual players selected by the other player objects are displayed in a normal sitting position, at normal size, and distributed on both sides.
[0174] On the player selection interface, several candidate player virtual characters 62 are displayed, for example, candidate players 1 to 5. Other candidate players can be viewed by swiping left or right, or all candidate players can be viewed by clicking the "All" button 63.
[0175] A player skill button 64 is also displayed on the player selection interface. In response to the player skill button 64 being clicked, the player skill name and effect description of the currently selected player virtual character can be viewed in the pop-up window on the right.
[0176] Optionally, the top of the player selection interface displays messages from other players, along with a countdown for selecting a player or entering a game. The left side of the player selection interface displays a button for sending text messages, a speaker off / on button, and a microphone off / on button. After the player object selects the player avatar, they can click the "Confirm" button 65 to enter the ready state.
[0177] N players participate in a game, each engaging in a round-based battle. Each round consists of a preparation phase and a battle phase.
[0178] Preparation phase for each round:
[0179] Step 340: Displaying a game interface of a turn-based chess game, the game interface including a chessboard area and a hand area;
[0180] Combined with reference Figure 10 The board area 10 is used to place at least one friendly chess piece and at least one enemy chess piece. Optionally, the upper half of the board area 10 is used to place at least one enemy chess piece, and the lower half of the board area 10 is used to place at least one friendly chess piece. The hand area 11 is used to display at least one card held by the player object. In the initial state or in certain situations (such as when all cards for the current round have been played), the number of cards displayed in the hand area 11 is 0.
[0181] Optionally, attribute information for the n player objects participating in the current game is displayed in the upper left corner of the game interface. This attribute information includes at least one of the following: player nickname, player portrait, player health, and player level. Player skill buttons 64 are displayed in the lower left corner of the game interface. A card swap button 14 and an upgrade button 15 are also displayed in the lower right corner of the game interface. The card swap button 14 is used to replace one or more cards in the hand area 11. The upgrade button 15 is used to upgrade the player's avatar's level to unlock higher-level cards, abilities, and equipment.
[0182] Optionally, an energy control 16 is displayed in the upper right corner of the game interface. This control displays the energy value of the player object. Energy is a game resource that may be consumed at various stages of the game. For example, playing cards requires energy, replacing cards requires energy, and upgrading player levels requires energy.
[0183] Step 360: In response to the play operation of at least one card, execute a battle preparation operation related to the own chess piece;
[0184] Card types include: chess piece cards, equipment cards, effect cards, and player cards. Players can perform different functions of battle preparation operations by playing different chess piece cards. This step includes at least one of the following steps:
[0185] Step 362: In response to the play operation on the chess piece card, executing a battle preparation operation related to at least one own chess piece in the chessboard area;
[0186] Step 364: In response to the play operation of the equipment card, equip all or part of the at least one chess piece with virtual equipment;
[0187] Step 366: In response to the play operation on the effect card, executing a preparation operation to add an effect to at least one factor in the game;
[0188] Step 368: In response to the play operation on the player's card, perform a preparation operation related to at least one factor in the game.
[0189] Since the battle situation in each round of turn-based battle is different, each player object has different cards in hand, and each player object has different card-playing habits, the number of times and order in which the above steps 362, 364, 366, and 368 are executed in each round of turn-based battle may change, and this embodiment does not limit this.
[0190] Regarding step 362 (chess card):
[0191] In some embodiments, the cards in the hand area include a first chess piece card. In response to a play operation on the first chess piece card, a first local chess piece is added to the board area. The first local chess piece is the chess piece corresponding to the first chess piece card. In some embodiments, the first local chess piece is a chess piece that has not been summoned to the board area.
[0192] That is, when the first own chess piece does not exist in the chessboard area, in response to the play operation on the first chess piece card, the first own chess piece is added to the chessboard area.
[0193] In response to a play operation on a first chess piece card, at least two candidate chess squares are displayed in the chessboard area, and a first indicator element corresponding to the first chess piece card is displayed, the first indicator element including at least one of a reduced first chess piece card, a first own chess piece, and a first indicator arrow; in response to a drag operation of dragging the first indicator element to the first candidate chess square, the first own chess piece is added to the first candidate chess square; wherein the first candidate chess square is one of the at least two candidate chess squares.
[0194] The at least two candidate squares may be all candidate squares or only candidate squares belonging to the player's side. The at least two candidate squares may be always displayed or only displayed when a card-playing operation is recognized.
[0195] The first chess card is Figure 10 Take the 4th card in as an example, combined with reference Figure 11 In response to a drag operation on the first chess piece card, a first own chess piece 17 and a first indicator arrow 18 are displayed. First own chess piece 17 is a three-dimensional piece that slides in response to the real-time position of the drag operation. First indicator arrow 18 starts at the position of the first chess piece card before it is played and ends at the real-time position of the drag operation. If the drag operation is released at the first candidate square, first own chess piece 17 is summoned to the first candidate square.
[0196] based on Figure 11 It can be seen that this interaction method cancels the chess piece preparation area, and the hand card area takes into account both the chess piece acquisition and preparation functions, realizing the sharing of multiple functions in one display area and improving the efficiency of human-computer interaction.
[0197] In some embodiments, the cards in the hand area include a second chess piece card. In response to a play operation on the second chess piece card and a second local chess piece already exists in the chessboard area, the chess piece level of the second local chess piece is upgraded in the chessboard area, where the second local chess piece is the chess piece corresponding to the second chess piece card.
[0198] Among them, the card-playing operation of the second chess piece card can also be a drag operation, but since there is already a second chess piece in the chessboard area, the release position of the drag operation can be completed at any position in the chessboard area, and it can take effect without the player object being accurately dragged to the second chess piece.
[0199] Regarding step 364 (equip the card):
[0200] In some embodiments, the cards in the hand area include equipment cards. In response to a play operation on the equipment card, a second indicator element corresponding to the equipment card is displayed, the second indicator element including at least one of a reduced equipment card, a virtual equipment corresponding to the equipment card, and a second indicator arrow.
[0201] In response to a dragging operation of dragging the second indicator element to the second own chess piece, dressing the second own chess piece with virtual equipment;
[0202] The second chess piece of the party is a chess piece of the party that already exists in the chessboard area.
[0203] Regarding step 366 (effect card):
[0204] In some embodiments, the cards in the hand area include effect cards. In response to a play operation on the effect card, an effect is added to at least one of the own chess pieces, and / or an effect is added to the card acquisition process.
[0205] According to the objects of action, effect cards are divided into two categories:
[0206] Type 1: Increases the effect on the own chess pieces within the chessboard area;
[0207] Type 2: Adds effects to the card acquisition process.
[0208] In response to playing a Type 1 effect card, an effect is added to at least one of your own chess pieces, such as increasing a buff specific to the chess piece type, or a combined buff when at least two chess pieces from the same faction are present.
[0209] In response to the play operation on the type 2 effect card, an effect is added to the card acquisition process, for example, two identical chess pieces are drawn consecutively.
[0210] Regarding step 368 (player card):
[0211] In response to the play operation on the player's card, at least one of the following preparation operations is performed:
[0212] Increasing your own chess pieces, reducing your own chess pieces, upgrading your own chess pieces, adding effects to your own chess pieces, equipping your own chess pieces with props, operations related to card acquisition, operations related to card sales, operations related to card exchanges, operations related to subsequent rounds, and operations related to the health value of your own player objects.
[0213] In other words, the function of a player card is relatively special. It can be any of the functions of a chess piece card, an equipment card, or an effect card. It can also be a function related to the card acquisition process, or a function related to the player's health. In different design implementations, any function that can affect a certain factor in the game may be designed as a function of a player card, and this embodiment of the application does not limit this.
[0214] During the preparation phase, the player object on this side can also use at least one of the card exchange function, card deletion function, and player level upgrade function.
[0215] Card swap function:
[0216] During the preparation phase, your player can also swap one or more cards from their hand. Clicking the swap button allows you to swap one or more cards, which consumes energy. For example, you can only swap cards once per round, but you can swap multiple cards at once. Each card swap costs 1 energy.
[0217] Delete card function:
[0218] During the card play process, dragging a card to a designated location will delete or sell it. The resources consumed by deleted cards cannot be recovered, or a portion or a fixed amount of energy can be recovered. For example, each deleted card will gain 1 energy point.
[0219] Player level upgrade function:
[0220] The player object on this side obtains a certain amount of energy in each round. The energy not used in this round can be accumulated to the next round, and the energy can be used to upgrade the player level. The higher the player level, the higher the quality of the cards that can be drawn in each round, and at the same time, some new abilities will be unlocked, such as talents, purchasable equipment, etc. Optionally, the upgrade button 15 can display quality indicators of different colors. As the player level is upgraded, the quality indicator corresponding to the current player level will light up to indicate the quality of the cards that can be obtained at the current player level. The quality indicator can be as follows: Figure 12 The small rounded rectangle shown is used as an example, but other shapes or forms are also possible.
[0221] For example, when our player object reaches player level 1 / 2 / 3 / 4 / 5, cards of quality 1 / 2 / 3 / 4 / 5 will be unlocked respectively.
[0222] The battle phase of each round:
[0223] Step 380: During the battle phase, the own chess piece and the enemy chess piece are automatically engaged in battle in the chessboard area;
[0224] The automatic battle process between your own chess pieces and enemy chess pieces in the chessboard area does not require manual control by your own player object. The client or server automatically controls the battle between the chess pieces of both sides based on the chess position on the chessboard, chess piece attributes, chess piece level, chess piece skills, chess piece attributes, joint enhancement attributes between chess pieces, etc., until all the chess pieces of one side are killed.
[0225] Figure 13 The figure shows an automatic battle diagram of a player's chess piece 17 and an enemy chess piece 19 in a melee battle on the chessboard. The movement, skill release, and functions of the two chess pieces during the battle do not require manual control by the player.
[0226] Battle settlement phase:
[0227] Step 390: Calculate the life value of the virtual character of the chess player on your side, and start the next round of turn-based battle or end the current game based on the life value.
[0228] Both the player object and the enemy player object have health points. After the round ends, the health points of the losing player object will be deducted by a certain amount. This amount can be determined based on the number of chess pieces remaining on the winning side, or it can be a fixed value, which is not limited in this embodiment.
[0229] When the health value is deducted to zero, the player is eliminated from the game.
[0230] When the health value has not been deducted to zero, the next round of turn-based battle will begin in this game, and the player will continue to fight with one of the n player objects until he is eliminated, or he will win the game as the last player who has not been eliminated.
[0231] In some embodiments, the damage calculation is based on the number of pieces remaining on the winning side's board. Figure 14 Shown is the animation effect of calculating the life value of the opponent's chess piece 19 when the opponent is the loser, and then calculating the life value of the opponent's chess piece virtual character 61. A life value progress bar can be displayed on the top of the chess piece virtual character 61.
[0232] Exemplary references Figure 15 The settlement information of the current game is displayed on the settlement interface. The settlement information includes player rankings, players used by each player, lineups, chess piece types, and other information.
[0233] In summary, the method provided in this embodiment, by introducing a "card" mechanism into a turn-based chess game, simplifies and integrates various battle preparation operations into the multi-card playing process, eliminating the concept of a shop. Players no longer need to repeatedly interact with multiple sub-areas on the traditional battle interface, such as the shop, chess piece preparation area, and chess piece battle area, to complete chess piece acquisition, upgrades, and battles. The traditional chess piece purchasing process, which requires users to actively select chess pieces, is replaced by a passive receipt of distributed cards. The game system replaces some of the user's tedious operations, allowing users to complete various battle preparation operations using essentially the same card playing operations as in a card game, thereby improving the efficiency of human-computer interaction.
[0234] Especially when playing turn-based chess games on small-screen terminals such as mobile phones or tablets, players can complete a variety of battle preparation operations based on the limited operations in the hand area. Compared with traditional auto chess, it can significantly improve the efficiency of human-computer interaction.
[0235] The method provided in this embodiment can eliminate the store in traditional Auto Chess based on the playing characteristics of the cards through chess piece cards. The tedious process that requires users to purchase the chess pieces they want from dozens of available chess pieces in the store is replaced by a process in which the game system automatically distributes several cards to the player, eliminating the need for users to manually select cards. This reduces the number of interactive operations required for users to obtain chess pieces and the amount of information that users need to process.
[0236] The method provided in this embodiment can eliminate effect buttons or controls in traditional Auto Chess through effect cards, eliminate the jungle phase in traditional Auto Chess through equipment cards, and incorporate the gameplay characteristics of each player through player cards. By simplifying the various mechanics of turn-based chess games into the card-playing process based on different card types, this can reduce the number of user interface elements required to be displayed on the battle interface, reducing the time users spend actively searching for relevant function entries, simplifying the operation difficulty of the player object, and improving the efficiency of human-computer interaction for the player object.
[0237] Please refer to Figure 16 , which shows a flow chart of a control method for a virtual chess piece provided by an embodiment of the present application. The method is executed by a computer device, which may be Figure 1 The first terminal 110 or the second terminal 130 in the system shown, or the computer device can also be Figure 1 The server 120 in the system shown, or the computer device may also include Figure 1 The first terminal 110, the server 120 and the second terminal 130 in the system shown in FIG. Figures 2 to 15 Turn-based chess games as shown. Figure 16 As shown, the method may include step 1610, step 1620 and step 1630.
[0238] Step 1610: Displaying a scene interface of a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece, and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are respectively located in a virtual chess square.
[0239] For example, a virtual scene is used to provide a turn-based chess game between different player characters; users can control one or more player characters through a user account logged into the terminal. The terminal may be installed with an application that runs or displays the virtual scene, and the application can display the scene interface of the virtual scene. The virtual venue refers to the environment created for virtual chess pieces and player characters to play, such as a virtual chessboard, virtual map, etc.
[0240] In an embodiment of the present application, a computer device displays a virtual scene interface including a virtual field, and the virtual field includes a plurality of virtual chess grids for placing virtual chess pieces.
[0241] Among them, the virtual chess piece is located in the virtual chess square, and can adjust its orientation or change its moving direction in the current virtual chess square, or move to an adjacent virtual chess square adjacent to the current virtual chess square; for example, the virtual chess piece is currently located in virtual chess square 1, and the virtual chess piece can move by itself to virtual chess square 2 adjacent to virtual chess square 1, and then move by itself to virtual chess square 3 adjacent to virtual chess square 2.
[0242] Exemplarily, the virtual field includes one or more first virtual chess pieces and one or more second virtual chess pieces; the first virtual chess piece can interact with each second virtual chess piece, for example, the first virtual chess piece can release one or more virtual skills to launch a virtual attack on the second virtual chess piece within a specific range.
[0243] Before controlling the first virtual chess piece to interact, the computer device may determine whether a second virtual chess piece exists within the current interactive range of the first virtual chess piece:
[0244] If a second virtual chess piece exists within the interaction range of the current first virtual chess piece, the computer device controls the first virtual chess piece to interact with the second virtual chess piece corresponding to the interaction range;
[0245] If there is no second virtual chess piece within the interaction range of the current first virtual chess piece, the computer device can control the first virtual chess piece to move to adjacent virtual chess squares in sequence until a second virtual chess piece appears within its interaction range. The computer device then stops the movement of the first virtual chess piece and controls the first virtual chess piece to interact with the corresponding second virtual chess piece within the interaction range.
[0246] Exemplarily, the first user places one or more first virtual chess pieces on the virtual chess square through the first terminal 110, and the second user places one or more second virtual chess pieces on the virtual chess square through the first terminal 130; wherein the first virtual chess piece and the second virtual chess piece are located on different virtual chess squares of the same virtual field, and the first virtual chess piece and the second virtual chess piece can automatically fight against each other on the virtual field; when there is no second virtual chess piece that can be fought against within the skill range of the first virtual chess piece, the first virtual chess piece can automatically move to the adjacent virtual chess squares in turn until there is a second virtual chess piece that can be fought against within its skill range, and then stop moving and release its corresponding skill / execute a virtual attack.
[0247] Figure 17 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application. Figure 17 As shown, the virtual field 1701 includes 8 (rows)×8 (columns), with two adjacent rows of virtual chess squares 1702 staggered; the number of adjacent virtual chess squares corresponding to the virtual chess square 1702 is 2 to 6.
[0248] The virtual field 1701 includes virtual chess pieces of two virtual camps, and the two virtual camps can place up to 6 virtual chess pieces in the virtual field 1701; the virtual field 1701 includes a first virtual chess piece 1703 corresponding to the first virtual camp (1 / 6), and a second virtual chess piece 1704, a second virtual chess piece 1705, and a second virtual chess piece 1706 corresponding to the second virtual camp (3 / 6).
[0249] A first virtual chess piece 1703 is located on virtual chess square 1702a. Virtual chess square 1702a has six adjacent virtual chess squares 1702 (solid rectangular chess squares adjacent to virtual chess square 1702a). This means that first virtual chess piece 1703 can move to one of the six virtual chess squares 1702 surrounding virtual chess square 1702a. When first virtual chess piece 1703 moves to virtual chess square 1702b, virtual chess square 1702b has four adjacent virtual chess squares 1702.
[0250] Step 1620: In response to the absence of the second virtual chess piece within the interactive range of the first virtual chess piece, control the first virtual chess piece to move to a target virtual chess square; the target virtual chess square is adjacent to the virtual chess square where the first virtual chess piece was located before the movement, and the target virtual chess square is located on a target path; the target path is the path containing the least number of virtual chess squares among the reference paths; the reference path is the path along which the first virtual chess piece moves to the second virtual chess piece through adjacent virtual chess squares in sequence.
[0251] In an embodiment of the present application, when there is no second virtual chess piece with which the first virtual chess piece can interact within its interaction range, the computer device may control the first virtual chess piece to move to a target virtual chess square adjacent to the virtual chess square where the first virtual chess piece was located before it moved.
[0252] The target virtual chess square is a virtual chess square corresponding to the target path, and the target path is a path including the least number of virtual chess squares among the paths from the first virtual chess piece to each second virtual chess piece.
[0253] Exemplarily, the number of virtual chess squares included in the reference path may correspond to the step length of the first virtual chess piece; that is, the target path is a path with the shortest step length among the paths from the first virtual chess piece to each second virtual chess piece.
[0254] Exemplarily, when there is no second virtual chess piece with which the first virtual chess piece can interact within its interaction range, the computer device may obtain information such as the position, interaction ability, life value, score value, etc. of the first virtual chess piece, as well as the number, position, interaction ability, life value, score value, etc. of the second virtual chess piece; the computer device obtains, based on the position of the first virtual chess piece and the number and position of the second virtual chess piece, each reference path for the first virtual chess piece to move to each corresponding second virtual chess piece, as well as the number of virtual chess squares contained in each reference path; the computer device determines the path with the least number of virtual chess squares in each reference path as the target path and the target virtual chess square; the computer device moves the first virtual chess piece to the target virtual chess square.
[0255] like Figure 17 As shown, when the first virtual chess piece 1703 is located at the virtual chess square 1702a, and the second virtual chess piece 1704, the second virtual chess piece 1705, and the second virtual chess piece 1706 are outside the interactive range 1707 of the first virtual chess piece 1703, the computer device can obtain a reference path 1708 containing the least number of virtual chess squares in the path from the first virtual chess piece 1703 to the second virtual chess piece 1704 based on the positions of the first virtual chess piece 1703, the second virtual chess piece 1704, the second virtual chess piece 1705, and the second virtual chess piece 1706. The path from the first virtual chess piece 1703 to the second virtual chess piece 1705 includes the reference path 1709 with the least number of virtual chess squares, and the path from the first virtual chess piece 1703 to the second virtual chess piece 1706 includes the reference path 1710 with the least number of virtual chess squares. Reference path 1708, reference path 1709, and reference path 1708 with the least number of virtual chess squares in reference path 1710 are determined as the target path of the first virtual chess piece 1703, and the first virtual chess piece 1703 is moved to the virtual chess square 1702c.
[0256] Step 1630: In response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece being within the interaction range of the first virtual chess piece, controlling the first virtual chess piece to interact with the second virtual chess piece within the interaction range.
[0257] For example, when the first virtual chess piece moves to the target virtual chess square, the computer device may obtain whether there is a second virtual chess piece that can interact with the first virtual chess piece within the interactive range when the first virtual chess piece is located at the target virtual chess square.
[0258] In an embodiment of the present application, when a first virtual chess piece moves to a target virtual chess square, and at this time there is a second virtual chess piece within the interaction range of the first virtual chess piece, that is, when the first virtual chess piece is located at the target virtual chess square, there is a second virtual chess piece that can interact with it within the interaction range, the computer device controls the first virtual chess piece to interact with the second virtual chess piece within the interaction range.
[0259] When a first virtual chess piece and at least two second virtual chess pieces belong to different virtual objects / teams / camps, the first virtual chess piece interacts with the second virtual chess pieces within the interaction range, and the first virtual chess piece may perform a combat action on the second virtual chess piece within the interaction range. For example, the first virtual chess piece may activate one or more virtual skills corresponding to the first virtual chess piece, or may inflict a negative effect on the second virtual chess piece.
[0260] For example, a virtual skill may have a cooldown period of a certain length, or a virtual skill may have specific release conditions. Based on information such as the interactive ability, health value, and points of the first virtual chess piece, and the interactive ability, health value, and points of the second virtual chess piece, the computer device may select one or more of the first virtual chess piece's virtual skills that are most suitable for release, thereby avoiding wasting virtual skill resources and helping the first user corresponding to the first virtual chess piece win the current match.
[0261] Alternatively, when a first virtual chess piece and at least two second virtual chess pieces belong to the same virtual object / team / camp, the first virtual chess piece interacts with the second virtual chess pieces within the interaction range, and the first virtual chess piece performs an assistive action on the second virtual chess pieces within the interaction range. For example, the first virtual chess piece may release one or more corresponding recovery-related virtual skills, or release a buff effect on the second virtual chess piece.
[0262] Exemplarily, when there is still no interactive virtual chess piece within the interactive range when the first virtual chess piece is located at the target virtual chess square, that is, there is no second virtual chess piece within the interactive range of the first virtual chess piece, step 1620 is executed.
[0263] In summary, according to the scheme shown in the embodiment of the present application, the computer device can control the first virtual chess piece to interact with the second virtual chess piece within the interaction range; when the second virtual chess piece does not exist within the interaction range of the first virtual chess piece, the computer device can control the first virtual chess piece to move to the target virtual chess square that is closer to the second virtual chess piece; this scheme determines the target virtual chess square based on the number of virtual chess squares contained in the path of the first virtual chess piece moving to the second virtual chess piece through adjacent virtual chess squares in sequence, which can ensure the effectiveness of moving the first virtual chess piece, improve the winning rate of the first virtual chess piece, and thereby improve the strategy of the virtual game.
[0264] based on Figure 16 For the solution in the embodiment shown, please refer to Figure 18 , which shows a flow chart of a control method for a virtual chess piece provided by an embodiment of the present application. The method is executed by a computer device, which may be Figure 1 The first terminal 110 or the second terminal 130 in the system shown, or the computer device can also be Figure 1 The server 120 in the system shown, or the computer device may also include Figure 1 The first terminal 110, the server 120 and the second terminal 130 in the system shown in FIG. Figures 2 to 15 Turn-based chess games as shown. Figure 18 As shown above Figure 16 Before step 1620 in the illustrated embodiment, steps 1612 , 1614 , 1616 and 1618 are also included.
[0265] Step 1612: In response to the absence of a second virtual chess piece within the interactive range of the first virtual chess piece, obtain position information of virtual chess squares adjacent to at least two second virtual chess pieces.
[0266] The position information of the virtual chess square may include coordinate information of the virtual chess square on the chessboard.
[0267] Step 1614: Based on the position information of the virtual chess squares adjacent to the at least two second virtual chess pieces and the position information of the virtual chess square where the first virtual chess piece is located, obtain each reference path.
[0268] In an embodiment of the present application, the computer device can use the position information of the virtual chess square where the first virtual chess piece is located as the starting point of the path, and the position information of the virtual chess square adjacent to the second virtual chess piece as the end point of the path, and determine the shortest path from the first virtual chess piece to the second virtual chess piece through a pre-set path search algorithm (such as a greedy algorithm) as a reference path.
[0269] Optionally, the reference path may be formed by connecting a plurality of virtual chess squares adjacent to each other in sequence.
[0270] Step 1616: Obtain the number of virtual chess squares contained in each reference path.
[0271] The computer device may count the number of virtual chess squares included in each reference path.
[0272] Step 1618: Determine a target path from each reference path based on the number of virtual squares included in each reference path.
[0273] In an embodiment of the present application, when there is no second virtual chess piece within the interactive range of a first virtual chess piece, the computer device can obtain the position information of the adjacent virtual chess squares where each second virtual chess piece is located. For example, the computer device can convert the virtual field into a coordinate system, with each virtual chess piece corresponding to a coordinate point.
[0274] For example, the current virtual scene includes N second virtual chess pieces, and each virtual chess piece has 6 adjacent virtual chess squares corresponding to the virtual chess square where the second virtual chess piece is located. The computer device obtains the position information of the adjacent virtual chess squares (up to 6N) where each of the 6 second virtual chess pieces is located.
[0275] In an embodiment of the present application, in combination with the position information of the virtual chess square where the first virtual chess piece is located, the computer device can obtain various reference paths for the first virtual chess piece to pass through adjacent virtual chess squares in sequence and move to the adjacent virtual chess square where the second virtual chess piece is located; based on each reference path, the computer device obtains the number of virtual chess squares contained in each reference path; and then the computer device can determine the reference path with the least number of virtual chess squares among the reference paths as the target path, and then determine the target virtual chess square of the first virtual chess piece.
[0276] In some embodiments, the computer device may further determine the target path by:
[0277] Step 1: In response to the absence of a second virtual chess piece within the interactive range of the first virtual chess piece, the computer device obtains the number M of the second virtual chess pieces and the position information of the virtual chess squares adjacent to each of the M second virtual chess pieces.
[0278] Step 2: The computer device sequentially obtains a reference path containing the least number of virtual chess squares among the reference paths corresponding to the M second virtual chess pieces.
[0279] For example, the computer device obtains multiple reference paths corresponding to the second virtual chess piece 1, and the number of virtual chess squares contained in each of the multiple reference paths; the reference path with the least number of virtual chess squares among the multiple reference paths corresponding to the second virtual chess piece 1 is used as the reference path corresponding to the second virtual chess piece 1; and so on, the computer device obtains M reference paths and the number of virtual chess squares corresponding to the M reference paths.
[0280] Step 3: Based on the number of virtual squares contained in each of the M reference paths, the computer device determines the target path from the M reference paths; that is, the reference path containing the least number of virtual squares among the M reference paths is determined as the target path, and then the target virtual square is determined.
[0281] Based on the above embodiments, this embodiment proposes a feasible solution for determining a target path, specifically including obtaining multiple reference paths based on the acquired position information of the virtual chess squares adjacent to each second virtual chess piece and the position information of the virtual chess square where the first virtual chess piece is located; determining the path with the least number of virtual chess squares among the multiple reference paths as the target path; this solution can improve the efficiency and accuracy of obtaining the target path, thereby improving the accuracy of the target virtual chess square and ensuring the effectiveness of moving the first virtual chess piece.
[0282] In some embodiments, the above Figure 18 The method in the illustrated embodiment further includes:
[0283] In response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece not being within the interactive range of the first virtual chess piece, position information of virtual chess squares adjacent to at least two second virtual chess pieces is reacquired.
[0284] When the first virtual chess piece moves to a new virtual chess square based on the current target path, the positions of the second virtual chess pieces may have changed. In other words, the current target path may no longer be the path with the shortest step length among the paths for the first virtual chess piece to move to the second virtual chess pieces. Therefore, the computer device can re-acquire the position information of the second virtual chess pieces to update the target path.
[0285] In an embodiment of the present application, after the first virtual chess piece moves to the target virtual chess square, if there is no second virtual chess piece within the interactive range of the first virtual chess piece, the computer device re-acquires the position information of the virtual chess squares adjacent to at least two second virtual chess pieces, that is, the position information of the virtual chess squares adjacent to each second virtual chess piece when the first virtual chess piece moves to the target virtual chess square; and then repeats the above steps 1614 to 1618.
[0286] Exemplarily, the computer device obtains each reference path based on the position information of the virtual chess squares adjacent to at least each second virtual chess piece and the position information of the virtual chess square where the first virtual chess piece is located; the computer device determines the reference path containing the least number of virtual chess squares among the reference paths as the new target path; and determines a new target virtual chess square based on the new target path; the computer device controls the first virtual chess piece to move to the new target virtual chess square.
[0287] Based on the above embodiments, this embodiment proposes a solution for re-acquiring the position information corresponding to the second virtual chess piece when the second virtual chess piece still does not exist within the interaction range of the first virtual chess piece after the first virtual chess piece moves to the target virtual chess square. The computer device can then determine a new target path and a new target virtual chess square, and move the first virtual chess piece to the new target virtual chess square. This solution can minimize the time that the first virtual chess piece is unable to interact with the second virtual chess piece in the virtual field, further improving the effectiveness of moving the first virtual chess piece.
[0288] In some embodiments, the above Figure 18 Step 1618 in the illustrated embodiment may be implemented as step 1618a.
[0289] Step 1618a: In response to the reference path including the least number of virtual squares among the reference paths including multiple reference paths, select a reference path from the multiple reference paths as the target path.
[0290] In an embodiment of the present application, when there are multiple reference paths obtained in the above step 1614, and the number of virtual squares corresponding to the reference paths is the same and the minimum, the computer device may determine one of the reference paths as the target path.
[0291] In some embodiments, the computer device can pre-set a priority condition for selecting a reference path from multiple reference paths as a target path. When the reference path containing the least number of virtual chess squares among the reference paths contains multiple reference paths, the computer device can select a reference path from the multiple reference paths as the target path based on the priority condition.
[0292] For example, under the condition that the number of virtual chess squares is the same, the reference path whose corresponding second virtual chess piece has the weakest interactive ability among multiple reference paths is preferentially selected as the target path; for another example, under the condition that the number of virtual chess squares is the same, the reference path whose corresponding second virtual chess piece has the same attributes as the first virtual chess piece is preferentially selected as the target path.
[0293] For example, the computer device can obtain the interactive capabilities (such as combat capability, attack capability, defense capability, etc.) and designated attribute values (such as health value, score value, etc.) of the first virtual chess piece and the second virtual chess piece as the basis for judging the priority conditions.
[0294] The above-mentioned priority conditions can be used individually or in combination.
[0295] For example, the scene interface of the virtual scene can display setting controls that allow users to automatically define priority conditions, providing users with more strategic choices and deeper game interaction.
[0296] Based on the above embodiments, this embodiment proposes a feasible solution for determining the target path when the reference path corresponding to the minimum number of virtual chess squares is not unique, which can expand the moving path selection method of the first virtual chess piece in this application.
[0297] In some embodiments, step 1618a may be implemented as follows:
[0298] Step 1618a1: In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, determine the path with the least number of movement direction changes among the multiple reference paths as the target path.
[0299] Exemplarily, when there are multiple reference paths obtained in step 1614 that have the same and minimum number of virtual squares corresponding to them, the computer device may obtain the number of movement direction changes corresponding to each of the multiple reference paths.
[0300] In an embodiment of the present application, the computer device may obtain a reference path with the least number of movement direction changes among multiple reference paths, and determine the reference path as the target path; and then the computer device determines the target virtual chess square based on the target path.
[0301] Figure 19 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application. Figure 19 As shown, the first virtual chess piece 1901 is located at the virtual chess square 1906a, the second virtual chess piece 1902 is located at the virtual chess square 1906b, and the second virtual chess piece 1903 is located at the virtual chess square 1906c.
[0302] Among them, the reference path 1904 for the first virtual chess piece 1901 to move to the virtual chess piece 1906 on the right side of the virtual chess piece 1906b and the reference path 1905 for the first virtual chess piece 1901 to move to the virtual chess piece 1906 on the left side of the virtual chess piece 1906c contain the least number of virtual chess pieces (step lengths) and are both 3.
[0303] Since reference path 1904 corresponds to a straight line path (the number of changes in moving direction is 0) and reference path 1905 corresponds to a broken line path (the number of changes in moving direction is 1), the computer device determines reference path 1904 as the target path of the first virtual chess piece 1901 and controls the first virtual chess piece 1901 to move to the virtual chess square 1906d.
[0304] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on the number of changes in the moving direction in the reference path. Since the virtual chess piece requires a certain amount of time to change its moving direction, this solution can further improve the effectiveness of moving the first virtual chess piece.
[0305] In some embodiments, step 1618a may be implemented as follows:
[0306] Step 1618a2: In response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths, the path with the shortest reference distance among the multiple reference paths is determined as the target path; the reference distance is the straight-line distance between the first virtual chess piece and the last virtual chess square in the reference path.
[0307] For example, when, among the reference paths obtained in step 1614 , there are multiple reference paths corresponding to the same and least number of virtual squares, the computer device may obtain the reference distance corresponding to each of the multiple reference paths.
[0308] In an embodiment of the present application, the reference distance is the straight-line distance between the first virtual chess piece and the last virtual chess square in the reference path; alternatively, the reference distance may be the straight-line distance between the first virtual chess piece and the second virtual chess piece corresponding to the reference path; the computer device may obtain a reference path with the shortest reference distance among multiple reference paths, and determine the reference path as the target path; and then the computer device determines the target virtual chess square based on the target path.
[0309] Figure 20 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application. Figure 20 As shown, the first virtual chess piece 2001 is located at the virtual chess square 2006a, the second virtual chess piece 2002 is located at the virtual chess square 2006b, and the second virtual chess piece 2003 is located at the virtual chess square 2006c.
[0310] Among them, the reference path 2004 for the first virtual chess piece 2001 to move to the virtual chess square 2006 on the right side of the virtual chess square 2006b and the reference path 2005 for the first virtual chess piece 2001 to move to the virtual chess square 2006 on the lower left side of the virtual chess square 2006c contain the least number of virtual chess squares (step lengths) and are both 3.
[0311] When the reference distance between virtual squares 2006a and 2006b is less than the reference distance between virtual squares 2006a and 2006c, the computer device may determine reference path 2004 as the target path of the first virtual chess piece 2001 and control the first virtual chess piece 2001 to move to virtual square 2006d.
[0312] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on the reference distance, which can further improve the effectiveness of moving the first virtual chess piece.
[0313] In some embodiments, step 1618a may be implemented as follows:
[0314] Step 1618a3: In response to the reference path including the least number of virtual chess squares among the reference paths comprising multiple reference paths, determine the path among the multiple reference paths where the corresponding second virtual chess piece is closest to the designated area as the target path.
[0315] Exemplarily, when there are multiple reference paths obtained in step 1614 with the same and minimum number of virtual chess squares corresponding to the multiple reference paths, the computer device may obtain the distance between the corresponding second virtual chess piece in the multiple reference paths and the designated area.
[0316] In an embodiment of the present application, the computer device can obtain a reference path among multiple reference paths, in which the corresponding second virtual chess piece is closest to the designated area, and determine the reference path as the target path; then the computer device determines the target virtual chess square based on the target path.
[0317] Exemplarily, the designated area is an area in the virtual field with a gain effect. When the second virtual chess piece is closer to the designated area, it may first obtain the corresponding gain effect, which is not conducive to the winning rate of the game for the side where the first virtual chess piece is located.
[0318] Figure 21 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application. Figure 21 As shown, the first virtual chess piece 2101 is located at the virtual chess square 2106a, the second virtual chess piece 2102 is located at the virtual chess square 2106b, and the second virtual chess piece 2103 is located at the virtual chess square 2106c; the designated area is the battlefield center 2107 of the virtual battlefield corresponding to the 8×8 virtual chess squares 2106.
[0319] Among them, the reference path 2104 for the first virtual chess piece 2101 to move to the virtual chess piece 2106 on the right side of the virtual chess piece 2106b and the reference path 2105 for the first virtual chess piece 2101 to move to the virtual chess piece 2106 on the lower left side of the virtual chess piece 2106c contain the least number of virtual chess pieces, both of which are 2.
[0320] Since the distance between the virtual chess square 2106b and the battlefield center 2107 is smaller than the distance between the virtual chess square 2106c and the battlefield center 2107, the computer device determines the reference path 2104 as the target path of the first virtual chess piece 2101 and controls the first virtual chess piece 2101 to move to the virtual chess square 2106d.
[0321] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on a designated area, which can further improve the effectiveness of moving the first virtual chess piece.
[0322] In some embodiments, step 1618a may be implemented as follows:
[0323] Step 1618a4: In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, determine the path among the multiple reference paths that passes through the designated area as the target path.
[0324] In an embodiment of the present application, the computer device may obtain a reference path passing through a specified area from among multiple reference paths, and determine the reference path as a target path; and then the computer device may determine a target virtual chess square based on the target path.
[0325] Exemplarily, the designated area is an area in the virtual field having a gain effect, and when the first virtual chess piece passes through the designated area, the corresponding gain effect can be obtained.
[0326] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes another feasible solution for determining the target path based on a designated area, which can further improve the effectiveness of moving the first virtual chess piece.
[0327] In some embodiments, the designated area is a central area of the virtual venue; or,
[0328] The designated area is an area in the virtual field having a designated effect.
[0329] In an embodiment of the present application, the designated area may be the central area of the virtual venue; for example, the designated area is the center point of a virtual chessboard composed of virtual chess squares.
[0330] The designated area may also be an area in the virtual venue with a designated effect; the designated effect may be a gain effect or a weakening effect.
[0331] For example, the computer device may set a designated virtual chess square in the virtual field that has a designated attribute value, interactive ability, etc. of the virtual chess piece. For example, when the virtual chess piece moves to the designated virtual chess square, the virtual chess piece may obtain a buff effect such as increased movement speed or increased health.
[0332] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece, proposes multiple types of designated areas, and can expand the multiple selection methods of the designated areas of this application.
[0333] In some embodiments, step 1618a may be implemented as follows:
[0334] Step 1618a5: In response to the reference path including the least number of virtual chess squares among the reference paths comprising multiple reference paths, the reference path corresponding to the weakest or strongest second virtual chess piece interaction ability among the multiple reference paths is determined as the target path.
[0335] Exemplarily, when there are multiple reference paths obtained in step 1614 having the same and minimum number of virtual chess squares corresponding to the multiple reference paths, the computer device may obtain the interactive capabilities of the corresponding second virtual chess pieces in the multiple reference paths.
[0336] In an embodiment of the present application, the computer device can obtain a reference path corresponding to the second virtual chess piece with the weakest interaction ability among multiple reference paths, and determine the reference path as the target path; that is, the first virtual chess piece selects the second virtual chess piece with the weakest interaction ability as the interaction object; and then the computer device determines the target virtual chess square based on the target path.
[0337] In an embodiment of the present application, the computer device can obtain a reference path with the strongest interactive ability of the corresponding second virtual chess piece among multiple reference paths, and determine the reference path as the target path; that is, the first virtual chess piece selects the second virtual chess piece with the strongest interactive ability as the interactive object; and then the computer device determines the target virtual chess square based on the target path.
[0338] For example, the computer device may obtain the interactive capability of the first virtual chess piece, select a second virtual chess piece that is beneficial to the game as an interactive object based on the interactive capability of the first virtual chess piece, and then determine the target path.
[0339] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on the interactive ability of the second virtual chess piece, which can further improve the effectiveness of moving the first virtual chess piece.
[0340] In some embodiments, step 1618a may be implemented as follows:
[0341] Step 1618a6: In response to the reference path containing the least number of virtual chess squares among the reference paths including multiple reference paths, the reference path corresponding to the second virtual chess piece with the highest or lowest designated attribute value among the multiple reference paths is determined as the target path.
[0342] Exemplarily, when there are multiple reference paths obtained in step 1614 having the same and minimum number of virtual chess squares corresponding to the multiple reference paths, the computer device may obtain the designated attribute values of the corresponding second virtual chess pieces in the multiple reference paths.
[0343] In an embodiment of the present application, a computer device can obtain a reference path corresponding to the second virtual chess piece with the weakest specified attribute value among multiple reference paths, and determine the reference path as the target path; that is, the first virtual chess piece selects the second virtual chess piece with the weakest specified attribute value as the interactive object; and then the computer device determines the target virtual chess square based on the target path.
[0344] In an embodiment of the present application, a computer device can obtain a reference path corresponding to the second virtual chess piece with the strongest specified attribute value among multiple reference paths, and determine the reference path as the target path; that is, the first virtual chess piece selects the second virtual chess piece with the strongest specified attribute value as the interactive object; and then the computer device determines the target virtual chess square based on the target path.
[0345] Exemplarily, the computer device may obtain a specified attribute value of a first virtual chess piece, select a second virtual chess piece that is beneficial to the game as an interactive object based on the specified attribute value of the first virtual chess piece, and then determine a target path.
[0346] For example, taking the life value of a virtual chess piece as an example, Figure 22 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application. Figure 22 As shown, the first virtual chess piece 2201 is located at the virtual chess square 2206a, the second virtual chess piece 2202 is located at the virtual chess square 2206b, and the second virtual chess piece 2203 is located at the virtual chess square 2206c.
[0347] The reference path 2204 for the first virtual chess piece 2201 to move to the virtual square 2206 on the right side of the virtual square 2206b and the reference path 2205 for the first virtual chess piece 2201 to move to the virtual square 2206 on the lower left side of the virtual square 2206c contain the least number of virtual squares, both being 2.
[0348] Since the health value 2208 of the second virtual chess piece 2202 is less than the health value 2209 of the second virtual chess piece 2203, the first virtual chess piece 2201 can select the second virtual chess piece 2202 as the interactive object. The computer device determines the reference path 2204 as the target path of the first virtual chess piece 2201 and controls the first virtual chess piece 2201 to move to the virtual chess square 2206d.
[0349] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on the specified attribute value of the second virtual chess piece, which can further improve the effectiveness of moving the first virtual chess piece.
[0350] In some embodiments, step 1618a may be implemented as follows:
[0351] Step 1618a7: In response to the reference path including the least number of virtual chess squares among the reference paths including multiple reference paths, a reference path among the multiple reference paths in which no designated terrain exists on the straight line between the corresponding second virtual chess piece and the first virtual chess piece is determined as the target path.
[0352] Exemplarily, when there are multiple reference paths obtained in the above step 1614, and the number of virtual chess squares corresponding to the reference paths is the same and the least, the computer device can obtain the location of the specified terrain, as well as the straight-line paths of the corresponding second virtual chess piece and the first virtual chess piece in the multiple reference paths.
[0353] In an embodiment of the present application, the computer device determines, among multiple reference paths, a reference path in which there is no designated terrain on the straight line between the corresponding second virtual chess piece and the first virtual chess piece as a target path; and then the computer device determines the target virtual chess square based on the target path.
[0354] Based on the above embodiments, this embodiment expands the method for determining the moving path of the first virtual chess piece and proposes a feasible solution for determining the target path based on the specified terrain. Since the terrain occlusion of the specified terrain may affect the interactive effect of the virtual chess piece; therefore, this solution can further improve the effectiveness of moving the first virtual chess piece.
[0355] In some embodiments, step 1618a may be implemented as follows:
[0356] Step 1618a8: In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, a random reference path among the multiple reference paths is determined as the target path.
[0357] Among them, the schemes shown in the above steps 1618a1 to 1618a8 can be used alone or in combination. Among them, when multiple schemes among the schemes shown in steps 1618a1 to 1618a8 are used in combination, they can be used according to a pre-set priority.
[0358] For example, taking the combined use of step 1618a1, step 1618a2 and step 1618a8 as an example, the scheme shown in step 1618a1 is used first, and the scheme shown in step 1618a2 is used second best; for example, in response to the reference path containing the least number of virtual chess squares among the reference paths containing multiple reference paths, the path with the least number of changes in moving direction among the multiple reference paths is determined as the target path; if there are multiple paths containing the least number of virtual chess squares and the least number of changes in moving direction, then the path with the shortest reference distance among the paths containing the least number of virtual chess squares and the least number of changes in moving direction can be determined as the target path; if there are multiple paths containing the least number of virtual chess squares, the least number of changes in moving direction, and the shortest reference distance, then a random path among the paths containing the least number of virtual chess squares, the least number of changes in moving direction, and the shortest reference distance can be determined as the target path.
[0359] The traditional Auto Chess game's piece movement mechanism lacks flexibility and strategic depth. During combat, pieces choose the shortest path to their predetermined target and then launch their attack. This target is often chosen based on the closest logical distance, but this doesn't necessarily mean the move will be the shortest or take the shortest time. Pieces move solely based on the nearest target, without considering battlefield dynamics and other strategic factors. This can lead to chaotic piece movement in complex battle situations, resulting in unexpected and unexpected routes.
[0360] The technical solution of this application improves the chess piece movement and attack decision-making process in traditional Auto Chess games. It allows chess pieces to consider multiple factors when selecting attack paths, such as the number of corners in the path, the logical step length, the distance between the target and the center of the battlefield, and the target's health, making the game's combat more diverse and strategic.
[0361] The solutions shown in the above embodiments of this application can be applied as a multi-stage pathfinding system, providing users with a more complex and strategic gaming experience. This multi-stage pathfinding system makes the movement and attack decisions of virtual chess pieces more intelligent, adapting to the dynamic changes of the battlefield, thereby increasing the challenge and fun of the game. Furthermore, the multi-stage pathfinding system provides users with more strategic options and deeper game interaction.
[0362] Please refer to Figure 23, which shows a flow chart of a multi-stage pathfinding system for determining a target chess piece provided by an embodiment of the present application. Take the case where there is no enemy chess piece (corresponding to the second virtual chess piece) within the skill range of a chess piece of one side (corresponding to the first virtual chess piece) and the computer device searches for the enemy chess piece as the target chess piece. Figure 23 As shown, the target chess piece determination process includes the following steps 231 to 239.
[0363] Step 231, Find Target: The computer device selects n enemy chess pieces from all attackable virtual chess pieces, denoted as A1, A2...A n .
[0364] Figure 24 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application; FIG. Figure 24 As shown, the first virtual chess piece 2401 can attack three virtual chess pieces, namely the second virtual chess piece 2402 , the second virtual chess piece 2403 and the second virtual chess piece 2404 .
[0365] Step 232, determine the reference step length: the computer device obtains the reference step lengths corresponding to the movement of the own chess piece to n enemy chess pieces, which are recorded as D1, D2...D n ; Among them, the minimum number of virtual chess squares that the chess piece of the party moves to the adjacent virtual chess squares of the virtual chess squares where n enemy chess pieces are located in the reference path according to the adjacent virtual chess squares is used as the reference step length D; for example, the first enemy chess piece has 5 adjacent virtual chess squares, and the minimum number of virtual chess squares included in the path of moving the chess piece of the party to the 5 adjacent virtual chess squares is the reference step length D1, and so on, the reference step lengths are obtained, which are recorded as D1, D2...D n .
[0366] like Figure 24 As shown, there are 6 adjacent virtual chess squares at the position of the second virtual chess piece 2402, and the minimum number of virtual chess squares included in the path of the first virtual chess piece 2401 moving to the 6 adjacent virtual chess squares is 2, such as the reference step length corresponding to the reference path 2405 is D1=2; similarly, the computer device obtains the reference path 2406 corresponding to the movement of the first virtual chess piece 2401 to the second virtual chess piece 2403, and the reference step length D2=3; the computer device obtains the reference path 2407 corresponding to the movement of the first virtual chess piece 2401 to the second virtual chess piece 2404, and the reference step length D3=6.
[0367] Step 233, Determine Shortest Path, D min ): Get reference step size D1, D2…D n The shortest step length D inmin The number of
[0368] Step 234, determine the shortest step length D min Is there only one, that is, the shortest step length D min Is the corresponding reference path unique?
[0369] If the shortest step length D min There is only one, the shortest step length D min The corresponding reference path is determined as the target path, and step 235 is executed; Figure 24 As shown, the computer device may determine the reference path 2405 as the target path;
[0370] If the shortest step length D min There are multiple, get multiple shortest step lengths D min For the corresponding multiple reference paths, execute step 236.
[0371] Step 235, moving to the target chess piece: the chess piece of the own side determines the target chess piece based on the target path and moves (Move) to the corresponding target virtual chess square; wherein, when the chess piece of the own side moves to the new virtual chess square, the above process is restarted.
[0372] Figure 25 FIG. 1 shows a schematic diagram of a scene interface of a virtual scene provided by an embodiment of the present application; FIG. Figure 25 As shown, after the computer device determines the second virtual chess piece 2502 as the target chess piece of the first virtual chess piece 2501 , it controls the first virtual chess piece 2501 to move toward the second virtual chess piece 2502 .
[0373] Step 236, determine the reference path R with the least number of turns min Is there only one, that is, multiple shortest step lengths D mentioned above? min Is the minimum number of times the chess piece needs to change its moving direction unique among the corresponding multiple reference paths?
[0374] If the reference path R with the least turning angle min Is there only one reference path R corresponding to the corner? min If it is determined to be the target path, execute step 235; Figure 19 As shown, when the step lengths corresponding to the reference path 1904 and the reference path 1905 are the same, the corner corresponding to the reference path 1904 is the least and unique; therefore, the computer device can determine the reference path 1904 as the target path;
[0375] If the path with the least turning angles R min There are multiple reference paths R corresponding to multiple corners. min, execute step 237.
[0376] Step 237, determine the reference path S with the shortest logical step length. min Is there only one, that is, the minimum number of reference paths R corresponding to the above multiple corners? min Is the straight-line distance between the start point and the end point (logically the shortest distance when ignoring path obstacles) unique?
[0377] If the reference path of the shortest logic step length S min Is there only one reference path S for the shortest logical step? min If it is determined to be the target path, execute step 235; Figure 20 As shown, when the reference path 2004 and the reference path 2005 have the same step length and the same turning angle, the logical step length corresponding to the reference path 2004 is the shortest; therefore, the computer device can determine the reference path 2004 as the target path;
[0378] If the reference path of the shortest logic step length S min There are multiple reference paths S with the shortest logical steps. min , execute step 238.
[0379] Step 238, determine the reference path C closest to the battlefield center min Is there only one reference path S with the shortest logical steps? min Is the enemy piece closest to the center of the battlefield (such as the center of the virtual chessboard) unique?
[0380] If the reference path C closest to the center of the battlefield min If there is only one, the reference path C closest to the center of the battlefield min If it is determined to be the target path, execute step 235; Figure 21 As shown, when the reference path 2104 and the reference path 2105 have the same step length, the same turning angle, and the same logical step length, the second virtual chess piece 2102 corresponding to the reference path 2104 is closest to the center 2107 of the battlefield; therefore, the computer device can determine the reference path 2104 as the target path;
[0381] If the reference path C closest to the center of the battlefield min There are multiple reference paths C closest to the center of the battlefield. min , execute step 239.
[0382] Step 239, determine the reference path L corresponding to the enemy chess piece with the lowest health value (Lowest Health Target) min Is there only one, that is, the multiple reference paths C closest to the center of the battlefield? min Is the enemy chess piece with the lowest health (virtual health) unique?
[0383] If the enemy chess piece with the lowest health value corresponds to the reference path L min Is there only one? Set the reference path L corresponding to the enemy chess piece with the lowest health value. min If it is determined to be the target path, execute step 235; Figure 22 As shown, the designated area is the battlefield center 2207 of the virtual battlefield corresponding to the 8×8 virtual chess squares 2206; when the reference path 2204 and the reference path 2205 have the same step length, the same turning angle, and the same logical step length, and the second virtual chess piece 2202 corresponding to the reference path 2204 and the second virtual chess piece 2203 corresponding to the reference path 2205 are at the same distance from the battlefield center 2207, the health value 2208 of the second virtual chess piece 2202 is lower than the health value 2209 of the second virtual chess piece 2203; therefore, the computer device can determine the reference path 2204 as the target path;
[0384] If the enemy chess piece with the lowest health value corresponds to the reference path L min There are multiple reference paths L corresponding to multiple enemy chess pieces with the lowest health value. min , randomly select a reference path as the target path and execute step 235.
[0385] This solution introduces a multi-stage pathfinding system to solve the problem of selecting the optimal path and the problem of cross-movement of chess pieces during the process. This solution not only improves the accuracy of path selection, but also increases the strategic depth and playability of the game.
[0386] Figure 26 It shows a block diagram of a virtual chess piece control device according to an exemplary embodiment of the present application. The device can be used to perform the following operations: Figure 16 or Figure 18 In the method shown, all or part of the steps performed by the computer device are as follows Figure 26 As shown, the device includes:
[0387] Interface display module 2601 is used to display a scene interface of a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece, and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are respectively located in a virtual chess square;
[0388] Movement control module 2602 is configured to control the first virtual chess piece to move to a target virtual chess square in response to the absence of the second virtual chess piece within the interaction range of the first virtual chess piece; the target virtual chess square being adjacent to the virtual chess square where the first virtual chess piece was located before the move, and being located on a target path; the target path being the path containing the fewest virtual chess squares among the reference paths; and the reference path being the path along which the first virtual chess piece moves to the second virtual chess piece through adjacent virtual chess squares in sequence;
[0389] The interaction control module 2603 is configured to control the first virtual chess piece to interact with the second virtual chess piece in the interaction range in response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece being in the interaction range of the first virtual chess piece.
[0390] In some embodiments, the above Figure 26 The device shown also includes an information acquisition module, which is used to:
[0391] In response to the absence of a second virtual chess piece within the interactive range of the first virtual chess piece, obtaining position information of virtual chess squares adjacent to at least two second virtual chess pieces;
[0392] Acquire each reference path based on position information of virtual chess squares adjacent to each of the at least two second virtual chess pieces and position information of the virtual chess square where the first virtual chess piece is located;
[0393] Obtain the number of virtual chess squares contained in each reference path;
[0394] A target path is determined from each reference path based on the number of virtual squares included in each reference path.
[0395] In some embodiments, the information acquisition module is further configured to, in response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece not being within the interaction range of the first virtual chess piece, reacquire position information of virtual chess squares adjacent to at least two second virtual chess pieces.
[0396] In some embodiments, the information acquisition module is configured to select a reference path from the multiple reference paths as the target path in response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths.
[0397] In some embodiments, the information acquisition module is configured to determine, in response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, the path with the least number of changes in moving direction among the multiple reference paths as the target path.
[0398] In some embodiments, the information acquisition module is used to determine the path with the shortest reference distance among the multiple reference paths as the target path in response to the reference path containing the least number of virtual chess squares among the reference paths containing multiple reference paths; the reference distance is the straight-line distance between the first virtual chess piece and the last virtual chess square in the reference path.
[0399] In some embodiments, the information acquisition module is used to determine, in response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths, the path in which the corresponding second virtual chess piece is closest to the designated area among the multiple reference paths as the target path.
[0400] In some embodiments, the information acquisition module is configured to determine a path passing through a designated area among the multiple reference paths as the target path in response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths.
[0401] In some embodiments, the designated area is a central area of the virtual venue; or,
[0402] The designated area is an area in the virtual field having a designated effect.
[0403] In some embodiments, the information acquisition module is used to determine, in response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths, the reference path corresponding to the second virtual chess piece with the weakest or strongest interactive ability among the multiple reference paths as the target path.
[0404] In some embodiments, the information acquisition module is used to determine the reference path with the highest or lowest designated attribute value of the corresponding second virtual chess piece among the multiple reference paths as the target path in response to the reference path with the least number of virtual chess squares among the reference paths containing multiple reference paths.
[0405] In some embodiments, the information acquisition module is used to respond to the fact that the reference path containing the least number of virtual chess squares among the reference paths contains multiple reference paths, and to determine the reference path among the multiple reference paths in which there is no designated terrain on the straight line between the corresponding second virtual chess piece and the first virtual chess piece as the target path.
[0406] It should be noted that the device provided in the above embodiment only uses the division of the above-mentioned functional modules as an example to implement its functions. In actual applications, the above-mentioned functions can be assigned to different functional modules according to actual needs, that is, the content structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0407] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method; the technical effects achieved by each module performing operations are the same as the technical effects in the embodiment of the method, and will not be elaborated here.
[0408] Figure 27 1 shows a block diagram of a computer device 2700 according to an exemplary embodiment of the present application. The computer device can be implemented as the server in the above-mentioned solution of the present application. The computer device 2700 includes a central processing unit (CPU) 2701, a system memory 2704 including a random access memory (RAM) 2702 and a read-only memory (ROM) 2703, and a system bus 2705 connecting the system memory 2704 and the central processing unit 2701. The computer device 2700 also includes a mass storage device 2706 for storing an operating system 2709, application programs 2710, and other program modules 2711.
[0409] The mass storage device 2706 is connected to the central processing unit 2701 via a mass storage controller (not shown) connected to the system bus 2705. The mass storage device 2706 and its associated computer-readable media provide non-volatile storage for the computer device 2700. In other words, the mass storage device 2706 may include a computer-readable medium (not shown) such as a hard disk or a Compact Disc Read-Only Memory (CD-ROM) drive.
[0410] Without loss of generality, the computer-readable medium may include computer storage media and communication media. Computer storage media include volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer-readable instructions, data structures, program modules or other data. Computer storage media include RAM, ROM, Erasable Programmable Read Only Memory (EPROM), Electronically Erasable Programmable Read-Only Memory (EEPROM), flash memory or other solid-state storage technology, CD-ROM, Digital Versatile Disc (DVD) or other optical storage, tape cassettes, magnetic tape, disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that the computer storage medium is not limited to the above-mentioned ones. The above-mentioned system memory 2704 and mass storage device 2706 can be collectively referred to as memory.
[0411] According to various embodiments of the present disclosure, the computer device 2700 can also be connected to a remote computer on a network such as the Internet for operation. That is, the computer device 2700 can be connected to the network 2708 via the network interface unit 2707 connected to the system bus 2705, or the network interface unit 2707 can be used to connect to other types of networks or remote computer systems (not shown).
[0412] The memory also includes at least one computer instruction, which is stored in the memory. The central processing unit 2701 implements all or part of the steps in the methods shown in the above embodiments by executing the at least one computer instruction.
[0413] In an exemplary embodiment, a chip is also provided. The chip includes a programmable logic circuit and / or program instructions. When the chip runs on a computer device, it is used to implement the control method of the virtual chess piece in the above aspect.
[0414] In an exemplary embodiment, a computer program product is also provided. The computer program product includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions to implement the virtual chess piece control methods provided in the above-described method embodiments.
[0415] In an exemplary embodiment, a computer-readable storage medium is further provided, in which computer instructions are stored. The computer instructions are loaded and executed by a processor to implement the control method of the virtual chess piece provided by the above-mentioned method embodiments.
[0416] Those skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware, or by a program to instruct the relevant hardware, and the program may be stored in a computer-readable storage medium, which may be a read-only memory, a disk, or an optical disk, etc.
[0417] Those skilled in the art will appreciate that in one or more of the above examples, the functions described in the embodiments of the present application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, these functions can be stored in a computer-readable medium or transmitted as one or more instructions or codes on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any media that facilitates the transmission of computer programs from one place to another. The storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer.
[0418] The above description is merely an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A method for controlling a virtual chess piece, characterized in that: The method comprises: A scene interface for displaying a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are each located in one of the virtual chess squares; In response to the second virtual chess piece not being present within the interactive range of the first virtual chess piece, controlling the first virtual chess piece to move to a target virtual chess square; the target virtual chess square being adjacent to the virtual chess square where the first virtual chess piece was located before the movement, and the target virtual chess square being located on a target path; the target path being the path containing the fewest virtual chess squares among the reference paths; and the reference path being the path along which the first virtual chess piece moves to the second virtual chess piece through the adjacent virtual chess squares in sequence; In response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece being within the interaction range of the first virtual chess piece, the first virtual chess piece is controlled to interact with the second virtual chess piece within the interaction range.
2. The method according to claim 1, characterized in that The controlling the first virtual chess piece to move to the target virtual chess square includes: In response to the absence of the second virtual chess piece within the interactive range of the first virtual chess piece, obtaining position information of at least two virtual chess squares adjacent to each other of the second virtual chess pieces; acquiring each of the reference paths based on position information of virtual chess squares adjacent to at least two of the second virtual chess pieces and position information of the virtual chess square where the first virtual chess piece is located; Obtaining the number of virtual chess squares contained in each of the reference paths; The target path is determined from each of the reference paths based on the number of virtual squares contained in each of the reference paths.
3. The method according to claim 2, characterized in that The method further comprises: In response to the first virtual chess piece being in the target virtual chess square and the second virtual chess piece not being within the interaction range of the first virtual chess piece, position information of at least two virtual chess squares adjacent to each other of the second virtual chess pieces is reacquired.
4. The method according to claim 2, characterized in that The determining the target path from each of the reference paths based on the number of virtual squares included in each of the reference paths comprises: In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, a reference path is selected from the multiple reference paths as the target path.
5. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the reference path including the least number of virtual chess squares among the reference paths comprising multiple reference paths, the path with the least number of changes in moving direction among the multiple reference paths is determined as the target path.
6. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the reference path containing the least number of virtual chess squares among the reference paths comprising multiple reference paths, the path with the shortest reference distance among the multiple reference paths is determined as the target path; the reference distance is the straight-line distance between the first virtual chess piece and the last virtual chess square in the reference path.
7. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the reference path including the least number of virtual chess squares among the reference paths comprising multiple reference paths, the path in which the corresponding second virtual chess piece is closest to the designated area among the multiple reference paths is determined as the target path.
8. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, a path passing through a designated area among the multiple reference paths is determined as the target path.
9. The method according to claim 7 or 8, characterized in that The designated area is the central area of the virtual venue; or The designated area is an area in the virtual field having a designated effect.
10. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the reference path including the least number of virtual chess squares among the reference paths, the reference path among the multiple reference paths, in which the interaction ability of the corresponding second virtual chess piece is the weakest or the strongest, is determined as the target path.
11. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the fact that the reference path containing the least number of virtual chess squares among the reference paths includes multiple reference paths, the reference path among the multiple reference paths whose corresponding designated attribute value of the second virtual chess piece is the highest or lowest is determined as the target path.
12. The method according to claim 4, characterized in that In response to the reference path including the least number of virtual squares among the reference paths comprising multiple reference paths, selecting a reference path from the multiple reference paths as the target path includes: In response to the fact that the reference path containing the least number of virtual chess squares among the reference paths includes multiple reference paths, the reference path among the multiple reference paths, in which there is no designated terrain on the straight line between the corresponding second virtual chess piece and the first virtual chess piece, is determined as the target path.
13. A control device for a virtual chess piece, characterized in that: The device comprises: an interface display module, configured to display a scene interface of a virtual scene, wherein the virtual scene includes a virtual field, the virtual field includes a first virtual chess piece, and at least two second virtual chess pieces; the virtual field is divided into a plurality of virtual chess squares; the first virtual chess piece and the second virtual chess piece are each located in one of the virtual chess squares; a movement control module configured to, in response to the absence of the second virtual chess piece within the interaction range of the first virtual chess piece, control the first virtual chess piece to move to a target virtual chess square; the target virtual chess square being adjacent to the virtual chess square where the first virtual chess piece was located before the movement, and the target virtual chess square being located on a target path; the target path being the path containing the fewest virtual chess squares among the reference paths; and the reference path being the path along which the first virtual chess piece moves to the second virtual chess piece, sequentially passing through the adjacent virtual chess squares. The interaction control module is configured to control the first virtual chess piece to interact with the second virtual chess piece within the interaction range in response to the first virtual chess piece being within the target virtual chess square and the second virtual chess piece being within the interaction range of the first virtual chess piece.
14. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one computer instruction, and the at least one computer instruction is loaded and executed by the processor to implement the control method of the virtual chess piece according to any one of claims 1 to 12.
15. A computer-readable storage medium, characterized in that The computer-readable storage medium stores at least one computer instruction, and the computer instruction is loaded and executed by the processor to implement the control method of the virtual chess piece according to any one of claims 1 to 12.
16. A computer program product, characterized in that The computer program product includes computer instructions, which are stored in a computer-readable storage medium; the computer instructions are read and executed by a processor of a computer device to implement the control method for a virtual chess piece according to any one of claims 1 to 12.