Game processing methods, devices and electronic devices

By constructing scene mirrors and assigning virtual characters in multiplayer online games, and utilizing multiple game processes for data calculation, the problem of limited virtual character numbers is solved, resulting in more efficient data processing and a better user experience.

CN116637369BActive Publication Date: 2026-03-13NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-31
Publication Date
2026-03-13

AI Technical Summary

Technical Problem

In existing technologies, the number of virtual characters in multiplayer online games is limited, resulting in insufficient data processing capabilities, causing game lag or inability to continue, affecting user experience and the data processing efficiency of the development platform.

Method used

The game scene is constructed into scene mirrors, each of which runs through a different game process. Virtual characters are assigned in each mirror, and character mirrors are created in other mirrors. State change data is calculated through the mirror process to keep the game synchronized.

Benefits of technology

It increased the number of virtual characters in the game scene, reduced the data processing pressure, ensured the consistency of the user's game experience and the efficiency of data interaction, and enhanced the game's playability and data processing capabilities.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116637369B_ABST
    Figure CN116637369B_ABST
Patent Text Reader

Abstract

This application discloses a game processing method, apparatus, electronic device, and computer-readable storage medium. The method includes: constructing scene mirrors corresponding to a game scene, with each scene mirror running through a different game process; allocating virtual characters in each scene mirror; creating a first character mirror corresponding to the first virtual character in a second scene mirror (excluding the first scene mirror where the first virtual character resides) based on the character metadata of the first virtual character; and, in response to a state change of the first virtual character in the first scene mirror, controlling the first character mirror in the second scene mirror to perform a corresponding state change based on the change data corresponding to the game process of the first scene mirror. This solution can increase the number of virtual characters that a game scene can support, thereby enabling the game to process more data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, specifically to a game processing method, apparatus, electronic device, and computer-readable storage medium. Background Technology

[0002] Multiplayer online games (MOBAs) are a common type of virtual game, such as multiplayer battle games (MMOs) and multiplayer role-playing games (MRPGs). In MMOs, a game scene may contain multiple virtual characters controlled by multiple users. As each virtual character performs game tasks, its corresponding game data may change. For example, if virtual character A attacks virtual character B, virtual character A's position in the game scene may change. When the game data of a virtual character in a game scene changes, this change needs to be synchronized with the other users controlling virtual characters in that game scene.

[0003] In practical applications, since game scenes run on backend servers, data processing in a game scene is done through the backend servers. However, the computing power of servers currently has an upper limit, so the data processing that can be performed in a game scene also has an upper limit. In other words, the number of virtual characters that a game scene can support has an upper limit.

[0004] However, the more virtual characters in a game scene, the higher the game's playability and the greater its appeal to users. When a large number of users need to play in the same game scene, the game will undergo a massive amount of data processing, potentially leading to lag or game crashes. This results in extremely low data processing capabilities within the game, while efficient data processing is crucial for both users and the game development platform. Summary of the Invention

[0005] This application provides a game processing method, apparatus, electronic device, and computer-readable storage medium, which can increase the number of virtual characters that a game scene can support, thereby enabling the game to process more data. The specific solution is as follows:

[0006] In a first aspect, embodiments of this application provide a game processing method, the method comprising:

[0007] Construct scene images corresponding to the game scenes, and each scene image is run through a different game process;

[0008] Assign virtual characters to each of the aforementioned scene mirrors;

[0009] Based on the character metadata of the first virtual character, create a first character image corresponding to the first virtual character in a second scene image other than the first scene image where the first virtual character is located;

[0010] In response to a state change of the first virtual character in the first scene mirror, the change data corresponding to the state change is calculated through the game process corresponding to the first scene mirror, and the first character image in the second scene mirror is controlled to perform a corresponding state change based on the change data.

[0011] Secondly, embodiments of this application provide a game processing device, the device comprising:

[0012] A construction unit is used to construct scene images corresponding to game scenes, and each scene image is run through a different game process;

[0013] An allocation unit is used to allocate virtual characters in each of the scene mirrors;

[0014] A creation unit is used to create a first character image corresponding to the first virtual character in a second scene image other than the first scene image where the first virtual character is located, based on the character metadata of the first virtual character.

[0015] The synchronization unit is used to respond to a state change of the first virtual character in the first scene mirror, calculate the change data corresponding to the state change through the game process corresponding to the first scene mirror, and control the first character image in the second scene mirror to perform the corresponding state change based on the change data.

[0016] Thirdly, this application also provides an electronic device, including:

[0017] Processor; and

[0018] A memory for storing a data processing program, which, when the electronic device is powered on and runs through the processor, executes the method described in the first aspect.

[0019] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a data processing program that is executed by a processor to perform the method described in the first aspect.

[0020] Compared with the prior art, this application has the following advantages:

[0021] The game processing method provided in this application constructs scene mirrors corresponding to game scenes, with each scene mirror running through a different game process; assigns virtual characters to each scene mirror; creates a first character mirror corresponding to the first virtual character in a second scene mirror other than the first scene mirror where the first virtual character is located, based on the character metadata of the first virtual character; in response to a state change of the first virtual character in the first scene mirror, calculates change data corresponding to the state change through the game process corresponding to the first scene mirror, and controls the first character mirror in the second scene mirror to perform a corresponding state change based on the change data.

[0022] As can be seen, in this application, different game processes run scene images of the same game scene. Virtual characters for that game scene are assigned to each scene image, and character images of those virtual characters are created in scene images where no virtual character has been assigned. Thus, a virtual character is an entity in one scene image and a character image in other scene images. Therefore, some "virtual characters" displayed in a scene image are entities, and some are images corresponding to the entities. The state changes of a virtual character in the game scene are calculated by the game process corresponding to the scene image. Therefore, the data calculation in a game scene is distributed among multiple game processes running multiple scene images corresponding to that game scene. Since multiple game processes share the computational load of the same game scene, the game processing method provided in this application allows a game scene to bear more data computation pressure, thereby effectively increasing the number of virtual characters that a game scene can accommodate.

[0023] Furthermore, this application controls the synchronization of state changes in character images in other scene mirrors based on state changes of virtual character entities in one scene mirror. This ensures that changes of the same character in multiple scene mirrors of the same game scene remain consistent in real time, guaranteeing the user's gaming experience on the terminal device. Therefore, the game processing method provided by this application can increase the number of virtual characters that a game scene can support without affecting the user's gaming experience, thereby enabling the game to process more data and improving the efficiency of data interaction. Attached Figure Description

[0024] Figure 1 This is a scene architecture diagram of the game processing method provided in the embodiments of this application;

[0025] Figure 2 This is a client interface diagram of the same game scene in the game processing method provided in the embodiments of this application;

[0026] Figure 3This is a flowchart of the game processing method provided in the embodiments of this application;

[0027] Figure 4 This is an example diagram of the interaction between the first game process and the second game process provided in the embodiments of this application;

[0028] Figure 5 This is a structural block diagram of an example of the game processing device provided in the embodiments of this application;

[0029] Figure 6 This is a structural block diagram of an example of an electronic device provided in an embodiment of this application. Detailed Implementation

[0030] Many specific details are set forth in the following description to provide a full understanding of this application. However, this application can be implemented in many other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of this application; therefore, this application is not limited to the specific embodiments disclosed below.

[0031] It should be noted that the terms "first," "second," "third," etc., in the claims, specification, and drawings of this application are used to distinguish similar objects and are not used to describe a specific order or sequence. Such data are interchangeable where appropriate so that the embodiments of this application described herein can be implemented in a sequence other than that shown or described herein. Furthermore, the terms "comprising," "having," and their variations are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products, or apparatuses.

[0032] In virtual environment-based applications, such as multiplayer online battle games (MOBAs) and multiplayer role-playing games (MMORPGs), when the game data corresponding to a virtual character in the game scene changes, the changed game data for that virtual character needs to be synchronized to other virtual characters in the game scene. When there are n virtual characters in the game scene, the number of messages generated in the game scene may be n*n. As described in the background technology, there is an upper limit to the data processing that a game scene can perform. With the current server computing power, a game scene can accommodate a maximum of 150 players. When faced with the demand for a large number of users to play the game simultaneously, the relevant technologies are clearly unable to meet this demand, resulting in a low data processing capacity for the game. The ability to perform large-scale data processing in a game is of paramount importance to both users and the game development platform.

[0033] For the reasons mentioned above, in order to increase the number of virtual characters that a game scene can support, thereby enabling the game to process more data, the first embodiment of this application provides a game processing method. This method is applied to an electronic device, which may be a desktop computer, laptop computer, mobile phone, tablet computer, server, terminal device, etc., or other electronic devices capable of executing game processing methods. This application embodiment is not specifically limited.

[0034] Before introducing the game processing method provided in the embodiments of this application, the following will first combine... Figure 1 and Figure 2 This paper introduces the scene architecture of the game processing method provided in the embodiments of this application, as well as the client interface of the same game scene in the game processing method provided in the embodiments of this application.

[0035] like Figure 1 The diagram illustrates the scenario architecture of a game processing method provided in this application embodiment, including multiple terminals 101 and at least one server 102. The terminals 101 and server 102 are connected via a network. Terminals 101 include, but are not limited to, desktop computers, laptops, mobile phones, tablets, and servers. Server 102 can be a server or other device that provides computing and storage functions to clients. The network can be a wireless network or a wired network, such as a wireless local area network (WLAN), local area network (LAN), cellular network, 2G network, 3G network, 4G network, or 5G network. Server 102 can provide data storage for data or logs generated during the game. When the scenario architecture includes multiple terminals, multiple servers, and multiple networks, different terminals and different servers can be interconnected through different networks.

[0036] Terminal 101 can be any device with computing hardware capable of supporting and executing software applications corresponding to the game. The game software application can be any of the following: Multiplayer Online Battle Arena Games (MOBA) or Multiplayer Online Role-Playing Games (MMORPG). The game type can include, but is not limited to, at least one of the following: Two-Dimensional (2D) game applications, Three-Dimensional (3D) game applications, Virtual Reality (VR) game applications, Augmented Reality (AR) game applications, or Mixed Reality (MR) game applications. This is merely an example, and this embodiment does not impose any limitations on it.

[0037] One of the multiple terminals 101 is referred to as the first terminal. The first terminal can be a terminal used by a user, who uses the first terminal to operate virtual objects in a virtual game scene to perform activities, including but not limited to: adjusting body posture, crawling, walking, running, jumping, driving, picking up, shooting, attacking, throwing, moving, sprinting, and defending. Additionally, the terminal can have one or more multi-touch screens for sensing and obtaining input from touch or swipe operations performed by the user at multiple points on one or more touch displays. The terminal can also be connected to a keyboard and / or mouse and / or game controller, enabling the user to operate the interface via the keyboard and / or mouse and / or game controller. Furthermore, different terminals can connect to other terminals or to a server using their own Bluetooth network or hotspot network.

[0038] Server 102 may include a first game process, a second game process, a third game process, ..., an nth game process, where each game process may reside on a single physical machine or on different physical machines. When all game processes reside on the same physical machine, the number of game processes cannot exceed the number of CPU cores corresponding to that physical machine. When all game processes reside on different physical machines, there is no limit to the number of game processes. The game processes are interconnected via a network and communicate using a Remote Procedure Call (RPC) protocol.

[0039] RPC is an inter-process communication method that allows calling remote services as if they were local services. RPC standardizes the way character data changes are invoked, specifying that each data change is a function call. This allows for the synchronous updating of both the character entity and its image through a wrapped protocol. For example, if game process 1 calls function A to change the energy value of character B, then when game process 1 calls function A, it can use RPC to instruct game process 2 that the character image corresponding to character B also calls function A to change its energy value. In this way, all users in their respective game processes will see the same changes to "character B".

[0040] like Figure 2 The image shown is a client interface for the same game scene in the game processing method provided in this application embodiment. Figure 2This includes a first client, ..., an nth client, displaying the same game scene. The first client through the nth client displays different scene mirrors for that game scene. In the first scene mirror displayed on the first client, the first virtual character 201, which is controlled by the user, is the first virtual character entity, and the "second virtual character" displayed in the first scene mirror is the second character mirror 202 corresponding to the second virtual character. In the nth scene mirror displayed on the nth client, the second virtual character 204, which is controlled by the user, is the second virtual character entity, and the "first virtual character" displayed in the nth scene mirror is the first character mirror 203 corresponding to the first virtual character. The information of the character mirrors and the virtual character entities is kept synchronized. Figure 2 As can be seen, the information displayed on the first client and the nth client pages is completely identical.

[0041] Below, in conjunction with Figure 3 The game processing method provided in the embodiments of this application will be described in detail. Figure 3 A flowchart of a game processing method provided in an embodiment of this application.

[0042] like Figure 3 As shown, the game processing method provided in this application includes the following steps 301 to 304.

[0043] Step 301: Construct scene images corresponding to the game scene, with each scene image running through a different game process.

[0044] In this context, a game scene refers to the game environment in which virtual characters and non-player characters (NPCs) exist within a virtual game. NPCs are game characters not controlled by players, but who guide the user through the game and interact with the user-controlled virtual character. A game scene is a virtual environment constructed and designed by game developers, not a real-world environment. A virtual character refers to a character that does not exist in reality; it can be a fictional character from at least one creative work such as a TV series, movie, comic book, or game. Virtual characters can include, but are not limited to, virtual figures and virtual animals.

[0045] A scene mirror corresponding to a game scene refers to a copy that is completely identical to the game scene. Mirroring is a type of redundancy; data on one disk exists as an exact copy on another disk. A mirror is a file storage format that allows many files to be created into a single image file. This image file can be placed on the same disk as programs like GHOST (General Hardware Oriented System Transfer). After opening the image file with software like GHOST, it can be restored into many files. In step 301, multiple scene mirrors can be built for a single game scene, and these multiple scene mirrors corresponding to one game scene are completely identical.

[0046] In an optional implementation, in step S301, a scene mirror corresponding to the game scene can be constructed using the scene information of the game scene.

[0047] A game scene typically includes multiple scene elements, which refer to the various elements required to constitute the game scene. These may include, but are not limited to, at least one of the following: mountains, rivers, lakes, seas, flowers, grass, trees, forests, houses, and the sky. The scene information in this step can be understood as the information corresponding to the multiple scene elements contained in the game scene; that is, the scene metadata generated by game developers when constructing and designing the game scene.

[0048] It should be noted that the scene information required to construct the scene mirror refers to the information of the scene elements contained in the game scene when it is initially displayed. In virtual games, there are also some scene elements that appear in the game scene at a certain moment during the game. These scene elements are not created in the game scene when the game scene is created. Therefore, in step 301, the scene mirror of the game scene can be constructed based on the information of the scene elements initially contained in the game scene.

[0049] In practical applications, a virtual game will face different game scenarios. Loading all game scenarios within a large game process would be extremely costly. Therefore, typically, one game scenario corresponds to one game process, and the corresponding game process is loaded only when loading a specific game scenario. This reduces the memory and CPU (Central Processing Unit) processing pressure on a single game process. Game servers are usually single-threaded, so a game scenario corresponds to a single-process, single-threaded architecture. The following explains processes and threads: A process is an application running in memory. Each process has its own independent memory space, and a process can have multiple threads. A thread is an execution task (control unit) within a process, responsible for executing the program within that process.

[0050] In step 301, multiple scene images built for a game scene run on multiple game processes, with each scene image running through one game process. Each process is processed by one CPU core. Thus, in step 301, multiple game processes run multiple scene images through multiple CPU cores, and the multiple game processes and multiple scene images for the same game scene are completely identical in their initial state.

[0051] This step constructs multiple scene images for the game scene, each running through a separate game process. Data within each scene image is processed by a single CPU core. Thus, multiple CPU cores process data from multiple scene images corresponding to a single game scene. Therefore, the maximum number of virtual characters that can be accommodated in each scene image of a game scene in this application is the same as the maximum number of virtual characters that can be accommodated in a single game scene running with a single process. Therefore, this application effectively increases the maximum number of virtual characters that can be accommodated in a single game scene when multiple scene images correspond to a single game scene.

[0052] For example, a single process running a game scene can accommodate a maximum of 150 virtual characters playing simultaneously. When a game scene corresponds to 10 scene mirrors, then theoretically, a game scene can accommodate a maximum of 1500 virtual characters playing simultaneously. Since there is no limit to the number of scene mirrors corresponding to a game scene, theoretically, the number of virtual characters in a game scene provided in this application is not limited.

[0053] Step 302: Assign virtual characters in each scene mirror.

[0054] The virtual game in this application is a multiplayer game. Therefore, upon initial entry into the game, the game scene corresponds to multiple virtual characters. These virtual characters may include those controlled by real users, as well as non-player characters. In this application's embodiments, the multiple virtual characters can be evenly distributed across multiple scene mirrors, or virtual characters can be randomly assigned to each scene mirror to ensure that at least one virtual character is assigned to each scene mirror. This application does not specifically limit the number of virtual characters assigned to each scene mirror.

[0055] For example, if there are 300 virtual characters entering the game scene and 6 scene mirrors, you can assign 50 virtual characters to each scene mirror, or you can randomly select 3 scene mirrors from the 6 scene mirrors and assign 60 virtual characters to each of those 3 scene mirrors, and assign 40 virtual characters to each of the remaining 3 scene mirrors. Understandably, one virtual character is assigned to one scene mirror, but multiple virtual characters may be assigned to a single scene mirror.

[0056] It should be noted that since data processing in a scene image is run by a CPU core, and the amount of data that a CPU core can process has an upper limit, the number of virtual characters that a scene image can support has a preset upper limit. When allocating virtual characters to each scene image, the total number of virtual characters allocated in each scene image shall not exceed the preset upper limit.

[0057] In practical applications, a virtual character can be assigned to each scene mirror when it initially enters the game scene. Specifically, a virtual character can be assigned to each scene mirror in response to a trigger command for a virtual character entering the game scene. The trigger command for a virtual character entering the game scene can be automatically triggered upon detection of the virtual character's entry, or it can be triggered by the user operating the virtual character clicking the corresponding control in the graphical user interface of their terminal. This ensures that at least one virtual character is assigned to each scene mirror corresponding to that game scene.

[0058] In this step, the virtual character refers to the virtual character contained in the game scene corresponding to the scene mirror. The game behavior of each virtual character in the game scene can be implemented through the game process corresponding to the scene mirror. Specifically, in response to the game behavior command for the virtual character, the game logic corresponding to the game behavior command is executed in the game process corresponding to the scene mirror of the virtual character, and the execution result is sent to the terminal device communicating with the game process through the game process corresponding to the scene mirror. The terminal device then calls the rendering logic corresponding to the execution result to present the interface of the virtual character performing the game behavior.

[0059] For example, if a virtual character 1 is assigned to scene mirror 1, then for the movement commands of virtual character 1 in the game scene, the movement logic can be executed in the game process corresponding to scene mirror 1, and the execution result can be sent to the terminal device that communicates with the game process corresponding to scene mirror 1. The interface of virtual character 1 moving in the game scene can be presented by calling the rendering logic of the terminal device.

[0060] In a specific implementation, each virtual character in the game can perform game behaviors under the corresponding user operation. The game behaviors can be game behaviors performed by a single virtual character or game interaction behaviors between multiple virtual characters. For example, it can include, but is not limited to, at least one of the following: adjusting body posture, crawling, walking, running, jumping, driving, picking up, shooting, attacking, throwing, moving, sprinting, and defending.

[0061] It should be noted that, since each scene mirror runs through a different game process, the game scene displayed on the graphical user interface of each user's terminal is based on the game process running in the scene mirror where the virtual character being operated by that user resides. When two virtual characters in the same game scene reside in different scene mirrors corresponding to that game scene, the game scenes displayed on the user's terminal operating the two virtual characters are actually different scene mirrors of the same game scene displayed based on different game processes.

[0062] For example, if a virtual character A is assigned to scene mirror A, then the virtual character A displayed in scene mirror A is the entity of that virtual character A. In this case, the game scene displayed on the graphical user interface of the terminal held by the user operating the virtual character A is based on the game process corresponding to scene mirror A. When another virtual character B is assigned to a different scene mirror B than the scene mirror A assigned to virtual character A, then the scene mirror where the entity of virtual character B resides is different from the scene mirror where the entity of virtual character A resides. In this case, the game scene displayed on the graphical user interface of the terminal held by the user operating the virtual character B is based on the game process corresponding to scene mirror B where the entity of virtual character B resides.

[0063] This step distributes the virtual characters in the game scene across multiple scene mirrors, ensuring that each scene mirror contains fewer virtual characters than the total number of virtual characters in the game scene. This reduces the data processing load on each scene mirror. Furthermore, data processing in each scene mirror is executed by a single CPU core. Thus, a game scene can be understood as being processed by multiple CPU cores across multiple scene mirrors. Compared to a single CPU core performing data calculations within the same game scene, multiple CPU cores processing the same game scene undoubtedly handles a greater workload.

[0064] Step 303: Based on the character metadata of the first virtual character, create the first character image corresponding to the first virtual character in the second scene image other than the first scene image where the first virtual character is located.

[0065] This step is used to create a character image corresponding to a specific virtual character in a scene image that has not yet been assigned to a particular virtual character. The purpose is to ensure that the scene elements in multiple scene images corresponding to the same game scene are identical. In this step, the first virtual character is any one of the multiple virtual characters in step 302.

[0066] Understandably, the second scene mirror and the first scene mirror are scene mirrors of the same game scene containing different virtual character entities. In order to keep the game scene displayed on the user's graphical user interface consistent, it is necessary to create a character mirror corresponding to a virtual character on a scene mirror that does not contain a virtual character entity. The character mirror of a virtual character in other scene mirrors can be understood as the "clone" of the virtual character in other scene mirrors. The virtual character is displayed in the form of a "clone" on a scene mirror that does not contain the virtual character entity.

[0067] In a specific implementation, when a virtual character entity is contained in a scene mirror of a game scene, the other scene mirrors of the game scene will display the character mirror of that virtual character. In this application, "a scene mirror containing a virtual character" can be understood as "a scene mirror containing the virtual character entity".

[0068] Specifically, a first character image corresponding to the first virtual character can be created in the second scene image based on the character metadata of the first virtual character in the first scene image. The character metadata of the first virtual character can be understood as data containing the character attribute information of the first virtual character, such as character shape information, character color information, etc. In this way, a character image exactly the same as the first virtual character can be created based on the character metadata of the first virtual character.

[0069] It should be noted that the first character image in the second scene mirror can be understood as a "puppet," which will not actively perform any game actions in the game, nor will it collect any game data. The behavior of the first character image in the second scene mirror is controlled by the behavior of the first virtual character in the first scene mirror.

[0070] This step creates a character mirror image corresponding to a virtual character in a scene mirror image that does not contain a specific virtual character entity. This ensures that the scene elements contained in multiple scene mirror images corresponding to the same game scene remain synchronized, and that the character mirror image and the virtual character entity displayed for the same virtual character appear completely identical.

[0071] Step 304: In response to the state change of the first virtual character in the first scene mirror, calculate the change data corresponding to the state change through the game process corresponding to the first scene mirror, and control the first character image in the second scene mirror to perform the corresponding state change based on the change data.

[0072] Because virtual characters in a game scene may perform game tasks, the game scene is dynamic and changes over time. To ensure that the graphical user interface of each user's terminal displays the same game interface for the same game scene, multiple scene mirrors corresponding to the same game scene can remain synchronized as the scene mirrors dynamically change. For example, when a user controlling the first virtual character moves the first virtual character from position A to position B in the first scene mirror, the position of the first character's mirror image in the corresponding second scene mirror also changes from position A to position B. That is, the character mirror image corresponding to the virtual character in a scene mirror that does not contain the virtual character entity changes accordingly following the changes of the virtual character in the scene mirror that contains the virtual character entity.

[0073] Therefore, when the state of the first virtual character changes in the game, it is necessary to calculate the change data corresponding to the state change of the first virtual character through the game process corresponding to the first scene mirror, and synchronize the data of the character image corresponding to the virtual character in the game processes corresponding to other scene mirrors based on the change data calculated by the game process corresponding to the first scene mirror. In this way, the user holding the terminal running the game process corresponding to the virtual character entity and the user holding the terminal running the game process corresponding to the character image will see the same display effect of the virtual character entity and the character image on their respective terminals.

[0074] The state changes in this step can include at least one of the following: changes in the virtual character's location, changes in the virtual character's experience points, changes in the virtual character's health, changes in items in the virtual character's inventory, etc. Typically, user actions on the virtual character within the game scene will cause state changes. For example, if virtual character A moves from location B to location C in the game scene, then virtual character A's location has changed. Correspondingly, the changed data can include at least one of the following: virtual character location change data, virtual character experience point change data, virtual character health change data, changes in items in the virtual character's inventory, etc.

[0075] In this step, it is possible to detect in real time whether the first virtual character undergoes a state change in the first scene mirror. When a state change is detected, the change data corresponding to the state change is calculated in real time through the game process corresponding to the first scene mirror. The change data can be the data after the change, or the difference between the data after the change and the data before the change. This application does not specifically limit this.

[0076] Furthermore, the system controls the first character image in the second scene mirror to make corresponding state changes in real time based on the changed data. In this way, when the first virtual character undergoes a certain state change, the first character image in the second scene mirror can be changed to the same state as the first virtual character in the first scene mirror in real time, so that the actions of the first character image and the actions of the first virtual character are kept synchronized in real time.

[0077] When the changed data is the updated data, the state of the first character image in the second scene mirror is changed accordingly based on the changed data. Specifically, the state data of the first character image in the second scene mirror is changed to the changed data. When the first changed data is the difference between the data before and after the change, the state of the first character image in the second scene mirror is changed accordingly based on the changed data. Specifically, the sum of the state data and the changed data of the first character image in the second scene mirror is determined as the updated state data of the first character image in the second scene mirror, and the state data of the first character image is changed to the updated state data.

[0078] For example, when a user controlling virtual character A moves virtual character A from position B to position C in the first scene mirror, the corresponding character mirror image of virtual character A in the second scene mirror will also move from position B to position C. Thus, users whose game scene is displayed on their devices as the second scene mirror image will also see the character mirror image of virtual character A move from position B to position C. Therefore, when a user performs a game action on their device, resulting in a state change, the "virtual character" (essentially the corresponding character mirror image) displayed on other users' devices will perform the same game action and experience the same state change.

[0079] In this way, when the state of the first virtual character entity changes, the state of the first character image corresponding to the first virtual character in other scene images is changed in real time, so that the state of the same virtual character in multiple scene images remains synchronized. In addition, it also ensures that the information contained in different scene images of the same game scene displayed on the terminals held by each user is the same at the same time.

[0080] For example, a game scene may have scene mirror 1 and scene mirror 2. The calculation of player A and player C's skill release, data changes, and status changes is performed in game process A corresponding to scene mirror 1, while the calculation of player B and player D's data is performed in game process B corresponding to scene mirror 2. In this way, the original 100% of the calculation in the game scene is distributed between game process A and game process B, with game process A and game process B each bearing 50% of the calculation.

[0081] It should be noted that, since the computational load is distributed among multiple game processes, theoretically, two game processes can support twice the number of players compared to one game process running a game scene, and three game processes can support three times the number of players compared to one game process running a game scene. However, because synchronizing data between multiple game processes requires additional data computation, in practical applications, the number of players that can be supported in a game scene for each additional game process is less than the theoretically multiplied number. The specific number depends on the amount of data computation required for data synchronization in the game scene.

[0082] The game processing method provided in this application constructs scene mirrors corresponding to game scenes, with each scene mirror running through a different game process; assigns virtual characters to each scene mirror; based on the character metadata of the first virtual character, creates a first character mirror corresponding to the first virtual character in a second scene mirror other than the first scene mirror where the first virtual character is located; in response to a state change of the first virtual character in the first scene mirror, calculates the change data corresponding to the state change through the game process corresponding to the first scene mirror, and controls the first character mirror in the second scene mirror to perform the corresponding state change based on the change data.

[0083] As can be seen, in this application, different game processes run various scene images of the same game scene. Virtual characters for that game scene are assigned to each scene image, and character images of those virtual characters are created in scene images where no virtual character has been assigned. Thus, a virtual character is an entity in one scene image and a character image in other scene images. Therefore, some "virtual characters" displayed in a scene image are entities, and some are images corresponding to the entities. The state changes of a virtual character in the game scene are calculated by the game process corresponding to the scene image. Therefore, the data calculation in a game scene is distributed among multiple game processes running multiple scene images corresponding to that game scene. Since multiple game processes share the computational load of the same game scene, the game processing method provided in this application can handle more data computation pressure in a single game scene, thereby effectively increasing the number of virtual characters that a single game scene can accommodate.

[0084] Furthermore, this application controls the synchronization of state changes in character images in other scene mirrors based on state changes of virtual character entities in one scene mirror. This ensures that changes of the same character in multiple scene mirrors of the same game scene remain consistent in real time, guaranteeing the user's gaming experience on the terminal device. Therefore, the game processing method provided by this application can increase the number of virtual characters that a game scene can support without affecting the user's gaming experience, thereby enabling the game to process more data and improving the efficiency of data interaction.

[0085] In practical applications, virtual games also include NPCs that appear during the game. These NPCs do not exist when you first enter the game scene. Therefore, it is necessary to assign a scene mirror to NPCs that appear during the game.

[0086] In a specific implementation, NPCs that appear during the game can be randomly placed into one of the multiple scene mirrors corresponding to the game scene. Alternatively, scene mirrors can be assigned to NPCs that appear during the game using the following optional methods.

[0087] Optionally, the game processing method provided in this application embodiment may further include the following steps:

[0088] When the moment arrives at the moment when the target non-player character appears in the game scene, determine the second virtual character with the smallest distance between its current position and the preset appearance position of the target non-player character in the game scene from all virtual characters in the game scene. The target non-player character is the character that appears at the preset appearance position during the game.

[0089] Place the target non-player character at a preset appearance position in the third scene mirror image where the second virtual character is located;

[0090] Based on the non-player character metadata of the target non-player character, create a target non-player character image in all scene images except the third scene image.

[0091] Since virtual characters can interact with NPCs in the game—for example, attacking NPCs to gain experience points or giving them gifts—the nearest virtual character is likely to interact with an NPC first when the NPC appears in the game. Therefore, when an NPC appears, it can be placed in a mirror image of the scene containing the nearest virtual character, allowing them to interact with the NPC within the same mirror image. Interactions between virtual characters and NPCs within the same mirror image can run through the same game process, making data interaction and response within the game scene more timely, faster, and more efficient.

[0092] Subsequently, similar to creating a first character image corresponding to the first virtual character in a second scene image that does not contain the first virtual character, a target non-player character image corresponding to the target non-player character can be created in a scene image that does not contain the target non-player character, so as to ensure that the information in each scene image corresponding to the same game scene remains synchronized.

[0093] Optionally, when the state change of the first virtual character in step 304 is caused by the interaction between the first virtual character and other virtual characters, step 304 can be implemented through the following steps:

[0094] Step 304-1: In response to the interaction between the first virtual character and other virtual characters or the character mirror corresponding to other virtual characters in the first scene mirror, calculate the interaction data generated during the interaction through the game process corresponding to the first scene mirror.

[0095] Step 304-2: Based on the interaction data, control the first character mirror in the second scene mirror to synchronously perform the interaction process indicated by the interaction data on other virtual characters and / or the character mirrors corresponding to other virtual characters.

[0096] The above steps are used to synchronize the interaction between the first virtual character in the first scene mirror and other virtual characters and / or other virtual character corresponding character mirrors in the second scene mirror, based on the interaction between the first virtual character in the first scene mirror and other virtual characters or other virtual character corresponding character mirrors.

[0097] Understandably, the other virtual characters in steps 304-1 and 304-2 can be virtual characters operated by real users or NPCs in the game scene. In practical applications, virtual characters can interact not only with virtual characters operated by real users but also with NPCs in the game to gain game experience or skill bonuses.

[0098] It should be noted that the "other virtual characters" displayed in the first scene mirror can be other virtual character entities or character mirrors corresponding to other virtual characters. There can be multiple second scene mirrors. The "first virtual character" displayed in multiple second scene mirrors is the first character mirror. The "other virtual characters" displayed in multiple second scene mirrors may be other virtual character entities or character mirrors corresponding to other virtual characters.

[0099] When the "other virtual character" displayed in the first scene mirror is an entity of another virtual character, the "other virtual character" displayed in the second scene mirror is a character mirror corresponding to that other virtual character; when the "other virtual character" displayed in the first scene mirror is a character mirror corresponding to another virtual character, if one of the scene mirrors in the second scene mirror is an entity of another virtual character, then the "other virtual characters" displayed in the scene mirrors in the second scene mirror other than that scene mirror are character mirrors corresponding to that other virtual character.

[0100] Specifically, when the first virtual character interacts with other virtual characters or their corresponding character mirrors in the first scene mirror, each piece of interaction data generated during the interaction process from start to finish can be calculated through the game process corresponding to the first scene mirror. For each piece of interaction data generated, the second scene mirror is guided to perform the interaction process indicated by that data. In this way, based on the interaction data generated during the interaction process, the first character mirror in the second scene mirror can be guided to synchronously perform the same interaction process in real time with other virtual characters and / or their corresponding character mirrors as the first virtual character interacted with other virtual characters or their corresponding character mirrors in the first scene mirror.

[0101] In this way, when a virtual character entity in a certain scene mirror interacts with other virtual character entities or the character mirror corresponding to other virtual character entities, the corresponding interaction data can be calculated through the game process corresponding to the first scene mirror, and this interaction process can be synchronized in other scene mirrors that belong to the same game scene as that scene mirror, so that each client displays the same graphical user interface for the same game scene.

[0102] Optionally, the interaction between the first virtual character and other virtual characters or the character mirror image corresponding to other virtual characters can be an attack launched by the first virtual character against other virtual characters, an attack on the first virtual character by other virtual characters, or a counterattack launched by the first virtual character based on an attack launched by other virtual characters against the first virtual character.

[0103] Therefore, when the interaction process involves the first virtual character launching an active attack on other virtual characters or the character mirror corresponding to other virtual characters in the first scene mirror, the "calculating the interaction data generated during the interaction process through the game process corresponding to the first scene mirror" in step 304-1 is the attack data generated during the active attack process calculated through the game process corresponding to the first scene mirror.

[0104] Accordingly, step 304-2 can be implemented according to the following steps: based on the attack data, control the first character image in the second scene image to synchronously perform the active attack indicated by the attack data on other virtual characters and / or the character images corresponding to other virtual characters.

[0105] Among them, an active attack includes at least one of the following: an attack initiated by the first virtual character, or a counterattack by the first virtual character based on the attack it has received.

[0106] In the case where the first virtual character is attacked by other virtual characters or the character mirror corresponding to other virtual characters in the first scene mirror during the interaction process, the "calculate the interaction data generated during the interaction process through the game process corresponding to the first scene mirror" in step 304-1 is to calculate the attacked data generated during the attack process through the game process corresponding to the first scene mirror.

[0107] Accordingly, step 304-2 can be implemented according to the following steps: based on the attacked data, control the first character image in the second scene image to be synchronously attacked by other virtual characters and / or the character images corresponding to other virtual characters, as indicated by the attacked data.

[0108] The following section details how a first virtual character attacks a second virtual character, and how the second virtual character is attacked and retaliates based on the attack received.

[0109] In this application, the attack launched by the first virtual character in the second scene mirror can be synchronized through the following steps: in response to the first virtual character launching an attack on the second virtual character or the second character mirror of the second virtual character in the first scene mirror, attack data is calculated through the game process corresponding to the first scene mirror; based on the attack data, the first character mirror in the second scene mirror is controlled to attack the second virtual character and / or the second character mirror corresponding to the second virtual character.

[0110] Understandably, a user controlling the first virtual character can launch an attack on the displayed "second virtual character" within the first scene mirror. To ensure consistency between the second scene mirror, which belongs to the same game scene as the first scene mirror, and the first scene mirror, the first character's image in the second scene mirror can also perform the same attack on the displayed "second virtual character," mirroring the attack by the first virtual character in the first scene mirror. Specifically, the attack data corresponding to the first virtual character's attack on the "second virtual character" in the first scene mirror is calculated through the game process corresponding to the first scene mirror, and the attack indicated by that attack data is synchronously executed in the game process corresponding to the second scene mirror.

[0111] Attack data may include, but is not limited to, at least one of the following: game skills used by the first virtual character to launch an attack, game items used by the first virtual character to launch an attack, changes in the position of the first virtual character during the attack, changes in the experience points of the first virtual character, and changes in the health of the first virtual character. Game skills are used to assist the virtual character in performing game tasks within the virtual game. Game skills can be categorized by skill type, including but not limited to attack skills, defensive skills, and support skills, and by whether they are actively triggered by the virtual character, including active skills and passive skills. Game skills can be triggered by the user operating the virtual character through specific gesture or touch operations in the graphical user interface.

[0112] In this way, when a virtual character entity in a certain scene mirror attacks other virtual character entities or the character mirror corresponding to other virtual character entities, this attack action can be synchronized in other scene mirrors that belong to the same game scene as the scene mirror, so that each client displays the same graphical user interface for the same game scene.

[0113] Since an attack by the first virtual character on the second virtual character may also cause a change in the state of the second virtual character, the game processing method provided in this application embodiment can synchronize the state change of the second virtual character through the following steps:

[0114] In response to an attack by the first virtual character or the first character's image in the fourth scene mirror on the second virtual character, the system calculates the change data of the second virtual character through the game process corresponding to the fourth scene mirror; based on the change data of the second virtual character, the system controls the second character's image in the fifth scene mirror (excluding the fourth scene mirror) to make corresponding state changes.

[0115] Among them, the fourth scene mirror is the scene mirror assigned to the second virtual character, and the "second virtual character" displayed in the fifth scene mirror is the character mirror corresponding to the second virtual character.

[0116] In this step, when the "first virtual character" displayed in the fourth scene mirror is the first virtual character entity, the fourth scene mirror is the first scene mirror; when the "first virtual character" displayed in the fourth scene mirror is the first character mirror corresponding to the first virtual character, the fourth scene mirror can be one of the scene mirrors in the second scene mirror. To better understand the game processing method provided in this application, the following steps are described with the first virtual character and the second virtual character assigned to different scene mirrors, and are not intended to limit this application.

[0117] In a specific implementation, based on the attack launched by the first virtual character in the first scene mirror against the second character mirror, the first character mirror corresponding to the first virtual character in the fourth scene mirror launches the same attack against the second virtual character. Therefore, the step "responding to the attack launched by the first virtual character or the first character mirror in the fourth scene mirror against the second virtual character" essentially means: responding to the attack launched by the first character mirror in the fourth scene mirror against the second virtual character when the first virtual character in the first scene mirror attacks the second character mirror corresponding to the second virtual character. At this time, the status data of the second virtual character in the fourth scene mirror may change, for example, the second virtual character's health may decrease, or the second virtual character's experience points may decrease. The changed data of the second virtual character is similar to the changed data of the first virtual character in step 304, and will not be described in detail here.

[0118] In this scenario, the change data based on the second virtual character will be updated accordingly, along with the state data of the second character image in the fifth scene mirror, which belongs to the same game scene as the fourth scene mirror. For details, please refer to step 304, "Controlling the first character image in the second scene mirror to perform corresponding state changes based on the change data," which will not be elaborated upon here.

[0119] By keeping the state data of the character mirror image consistent with that of the virtual character entity, the game actions performed by the virtual character entity and its corresponding virtual character mirror image in different scene mirror images of the same game scene displayed on various clients remain consistent. Furthermore, when a virtual character entity in one scene mirror attacks the character mirror image corresponding to another virtual character, the state data of that character mirror image can be updated accordingly to respond to the attack, enhancing the user's game immersion and experience.

[0120] In practical applications, after one virtual character attacks another, the other virtual character may retaliate against the attack. Therefore, the game processing method provided in this application embodiment can also synchronize the retaliatory action through the following steps: in response to the second virtual character in the fourth scene mirror attacking the first character mirror, calculate retaliatory data through the game process corresponding to the fourth scene mirror; based on the retaliatory data, control the second character mirror in the fifth scene mirror to retaliate against the first virtual character and / or the first character mirror; in response to the secondary state change of the first virtual character in the first scene mirror in response to the retaliatory data, calculate secondary change data through the game process corresponding to the first scene mirror, and control the first character mirror in the second scene mirror to perform the corresponding state change based on the secondary change data.

[0121] The game scene displayed on the graphical user interface of the terminal held by the user operating the second virtual character is the fourth scene mirror image of the game scene. When the user operating the second virtual character sees the "first virtual character" (which is actually the first character mirror image of the first virtual character in the fourth scene mirror image) attacking the second virtual character on the graphical user interface of the terminal held by the user, the user can operate the second virtual character to counterattack against the first character mirror image of the first virtual character in the fourth scene mirror image.

[0122] Similar to attack data, counterattack data may include, but is not limited to, at least one of the following: game skills used by the second virtual character when counterattacking, game items used by the second virtual character when counterattacking, position changes of the second virtual character when counterattacking, experience value changes of the second virtual character, and health value changes of the second virtual character.

[0123] To ensure consistency across multiple scene mirrors corresponding to the same game scene, when the second virtual character in the fourth scene mirror launches a counterattack against the first character mirror, the second character mirror of the second virtual character in the fifth scene mirror, which belongs to the same game scene as the fourth scene mirror, also performs the same counterattack action. Specifically, in response to the second virtual character in the fourth scene mirror counterattacking the target first character mirror, the corresponding counterattack data is calculated through the game process corresponding to the fourth scene mirror, the execution result is obtained, and the counterattack process indicated by the execution result is presented on the terminal device communicating with the game process corresponding to the fourth scene mirror.

[0124] Understandably, the second virtual character in the above scheme can also be regarded as the first virtual character in step 304. Through this technical means, when the first virtual character in the first scene mirror initiates an attack, is attacked, or counterattacks based on the attack received, the first character mirror in the second scene mirror can be controlled to synchronously carry out the corresponding attack, be attacked, and counterattack based on the attack received, so that different scene mirrors corresponding to the same game scene can be synchronized in real time.

[0125] Since each scene mirror runs through a different game process, the state change in step 304 is essentially controlled through inter-process interaction. Therefore, step 304 can be implemented through the following steps:

[0126] In response to a state change of the first virtual character in the first scene mirror, the game process corresponding to the first scene mirror calculates the change data corresponding to the state change and sends the change data to the game process corresponding to the second scene mirror. The game process corresponding to the second scene mirror receives the change data and controls the first character image in the second scene mirror to perform the corresponding state change based on the change data.

[0127] This step is used to synchronize the first virtual character in the first scene mirror and the first character image corresponding to the first virtual character in the second scene mirror through the interaction between the game process corresponding to the first scene mirror and the game process corresponding to the second scene mirror.

[0128] Please refer to the details. Figure 4 ,like Figure 4 The diagram shown is an example of the interaction between the first game process and the second game process provided in this application embodiment. The attack action includes steps 401 to 403, and the counterattack action includes steps 404 to 406.

[0129] Step 401: In response to the first virtual character in the first scene mirror attacking the second character mirror, the first game process corresponding to the first scene mirror executes the game logic corresponding to the attack to calculate the corresponding attack data, and displays the attack action of the first virtual character entity on the second character mirror of the second virtual character indicated by the attack data on the terminal device communicating with the first game process.

[0130] Step 402: The first game process sends the attack data to the second game process corresponding to the second virtual character entity;

[0131] Step 403: The second game process receives the attack data and changes the corresponding attack data in the second game process based on the attack data. The attack action of the target first character image to the second virtual character indicated by the attack data is displayed on the terminal device corresponding to the second game process.

[0132] Step 404: In response to the user operating the second virtual character to counterattack the target first character image, the second game process corresponding to the fourth scene image executes the game logic corresponding to the counterattack to calculate the corresponding counterattack data, and displays the counterattack action of the second virtual character entity indicated by the counterattack data on the terminal device communicating with the second game process.

[0133] Step 405: The second game process sends the counterattack data to the first game process corresponding to the first virtual character entity;

[0134] Step 406: The first game process receives the counterattack data and changes the corresponding counterattack data in the second game process based on the counterattack data. The counterattack action of the second character image indicated by the counterattack data against the first virtual character entity is displayed on the terminal device corresponding to the first game process.

[0135] In a specific implementation, multiple game processes corresponding to the same game scene can communicate via RPC to synchronize the actions of virtual character entities and their corresponding character mirrors. Thus, when two virtual character entities do not belong to the same scene mirror, interaction between one virtual character entity and the corresponding character mirror of another virtual character can be achieved through the interaction of their respective game processes.

[0136] Specifically, the game process containing a character image can send state change information related to that character image on its own scene image to other game processes. This is used to control the virtual character entities corresponding to that character image in other scene images and the other character images corresponding to those virtual character entities to synchronize the state change. The game process containing a character image can also send state change information related to that character image on its own scene image to the game process corresponding to the virtual character entity of that character image. The game process corresponding to that virtual character entity then sends the received state change information to other game processes, which is used to control the character images corresponding to that virtual character in other scene images to synchronize the state change.

[0137] In addition, in practical applications, a certain state data may change continuously in a short period of time. For example, virtual character A's experience value drops from 3000 to 1000 in 10 seconds. During this process, the experience value may keep changing. In this case, if the state data after each change is synchronized in the scene mirror, it will increase the pressure of data interaction and also result in a large amount of redundant data in the game.

[0138] Therefore, to avoid frequent changes to a certain state data within a short period of time, step 304 can also be implemented according to the following steps:

[0139] In response to a change in the target type state data of the first virtual character in the first scene mirror, when the synchronization condition is met, the change result of the state data is calculated through the game process corresponding to the first scene mirror; based on the change result, the first character image in the second scene mirror is controlled to perform the corresponding state change.

[0140] Optionally, the synchronization conditions in the above steps may include at least one of the following conditions: synchronization is performed when the status data no longer changes within a preset time period, synchronization is performed according to a preset period, and synchronization is performed when the data changes in the status data accumulate to a preset amount.

[0141] The target type's status data can be, for example, at least one of health points, life points, experience points, etc. Slight changes in the target type's status data have little impact on the game's visual experience. The target type data can be determined based on user feedback or set by the game developers; this application does not specifically limit this.

[0142] Understandably, when the state data of the first virtual character entity in the first scene mirror is continuously changing, this application can, when the state data stops changing within a preset time period (e.g., 2 seconds, 5 seconds), calculate the final change result through the game process corresponding to the first scene mirror and send this final change result to the game process corresponding to the second scene mirror to control the first character mirror in the second scene mirror to synchronize this final change result; it can also calculate the change result through the game process corresponding to the first scene mirror according to a preset period (e.g., 2 seconds, 5 seconds) and send this final change result to the game process corresponding to the second scene mirror according to the preset period to control the first character mirror in the second scene mirror to synchronize this change result according to the preset period; it can also calculate the change result through the game process corresponding to the first scene mirror when the state data accumulates to a preset change amount and synchronize this change result to the first character mirror in the second scene mirror. The preset change amount can be the degree of change or the specific value of the change. For example, it can be set to synchronize data when the state data increases or decreases by 1%, or it can be set to synchronize data when the value of the state data increases or decreases by 20.

[0143] In a specific implementation, the same game scene contains multiple target type state data. The above synchronization conditions can be specifically set according to the specific situation. For example, the synchronization condition for target type state data A is to synchronize when the state data no longer changes within a preset time period; the synchronization condition for target type state data B is to synchronize according to a preset period; and the synchronization condition for target type state data C is to synchronize when the data changes of state data B accumulate to a preset amount. This application does not limit this.

[0144] Specifically, when synchronization is performed when the state data of the first virtual character no longer changes, the change result of the state data is calculated through the game process corresponding to the first scene mirror when the state data stops changing; when synchronization is performed when the state data of the first virtual character is synchronized according to a preset period, the change result of the state data is calculated through the game process corresponding to the first scene mirror according to the preset period; when synchronization is performed when the data changes of the state data of the first virtual character accumulate to a preset amount, the change result of the state data is calculated through the game process corresponding to the first scene mirror when the data changes of the state data of the first virtual character accumulate to the preset amount.

[0145] Since users are unaware of slight changes in the state data of the target type in the game, synchronizing the change in the state data of the target type through set synchronization conditions when the data of the target type changes, rather than synchronizing the state data of the target type in real time, can reduce the pressure of data transmission and reduce redundant data generated in the game.

[0146] In a specific implementation, when the virtual character's image is created for the first time, the state data of the target type corresponding to the virtual character entity and the virtual character image are synchronized. During the virtual game, when the state data of the target type corresponding to the virtual character entity changes, the changed state data can be cached in a data cache. When the synchronization conditions are met, the changed data is then synchronized to the character image corresponding to the virtual character entity. In this way, caching the data improves the efficiency of data synchronization.

[0147] Optionally, the virtual character in this application may include one or more of the character itself and the character clone.

[0148] Specifically, when the first virtual character is the original character, and a character clone is created for the first virtual character, the character clone can be synchronized through the following steps:

[0149] In response to a character clone creation command triggered on the character body of the first virtual character, a character clone of the first virtual character is created in the first scene mirror based on the character body; a mirror clone of the first character mirror is created in the second scene mirror based on the character body, and the actions of the mirror clone in the second scene mirror are kept synchronized with the actions of the character clone in the first scene mirror.

[0150] In this step, the character clone can be understood as a mirror image of the original character within the current scene. In practical applications, it's common to summon a character clone for the original character to perform game actions. When the original character creates a character clone, a corresponding mirror image of the original character will also be created in other scene mirror images, and the actions of the mirror image clone will be synchronized with those of the original character. This ensures that regardless of whether the first virtual character is the original character or a character clone, state changes will occur synchronously.

[0151] Corresponding to the game processing method provided in the first embodiment of this application, the second embodiment of this application also provides a game processing device, such as... Figure 5 As shown, the game processing device 500 includes:

[0152] The construction unit 501 is used to construct scene images corresponding to the game scene, and each scene image is run through a different game process;

[0153] Allocation unit 502 is used to allocate virtual characters in each of the scene mirrors;

[0154] The creation unit 503 is used to create a first character image corresponding to the first virtual character in a second scene image other than the first scene image where the first virtual character is located, based on the character metadata of the first virtual character.

[0155] The synchronization unit 504 is used to respond to the state change of the first virtual character in the first scene mirror, calculate the change data corresponding to the state change through the game process corresponding to the first scene mirror, and control the first character image in the second scene mirror to perform the corresponding state change based on the change data.

[0156] Optionally, the synchronization unit 504 is specifically configured to: respond to the interaction between the first virtual character and other virtual characters or the character mirror corresponding to the other virtual characters in the first scene mirror, calculate the interaction data generated during the interaction process through the game process corresponding to the first scene mirror; and control the first character mirror in the second scene mirror to synchronously perform the interaction process indicated by the interaction data with the other virtual characters and / or the character mirror corresponding to the other virtual characters.

[0157] Optionally, when the interaction process involves the first virtual character launching an active attack on other virtual characters or the character mirror corresponding to the other virtual characters in the first scene mirror, the synchronization unit 504 is further specifically configured to: calculate attack data generated during the active attack process through the game process corresponding to the first scene mirror; wherein the active attack includes at least one of the following: an attack launched by the first virtual character, a counterattack by the first virtual character based on the attack received; and control the first character mirror in the second scene mirror to synchronously launch the active attack indicated by the attack data against the other virtual characters and / or the character mirror corresponding to the other virtual characters based on the attack data.

[0158] Optionally, when the interaction process involves the first virtual character being attacked by other virtual characters or the character mirror corresponding to the other virtual characters in the first scene mirror, the synchronization unit 504 is further configured to: calculate the attacked data generated during the attack process through the game process corresponding to the first scene mirror; and control the first character mirror in the second scene mirror to be synchronized with the other virtual characters and / or the character mirror corresponding to the other virtual characters to perform the attacked process indicated by the attacked data based on the attacked data.

[0159] Optionally, the synchronization unit 504 is further configured to: in response to a change in the state data of the target type of the first virtual character in the first scene mirror, calculate the change result of the state data through the game process corresponding to the first scene mirror when the synchronization condition is met; and control the first character mirror in the second scene mirror to perform a corresponding state change based on the change result.

[0160] Optionally, the game processing device 500 further includes a determining unit 505, which is configured to: when the moment when the target non-player character appears in the game scene is reached, determine from among the virtual characters in the game scene the second virtual character whose current position is the smallest distance from the preset appearance position of the target non-player character in the game scene, wherein the target non-player character is the character that appears at the preset appearance position during the game; and place the target non-player character at the preset appearance position in the third scene mirror image where the second virtual character is located.

[0161] The creation unit 503 is further configured to: create a target non-player character image corresponding to the target non-player character in other scene images besides the third scene image, based on the non-player character metadata of the target non-player character.

[0162] Optionally, the synchronization unit 504 is specifically configured to: in response to a state change of the first virtual character in the first scene mirror, calculate change data corresponding to the state change through the game process corresponding to the first scene mirror, and send the change data to the game process corresponding to the second scene mirror through the game process corresponding to the first scene mirror; receive the change data through the game process corresponding to the second scene mirror, and control the first character image in the second scene mirror to perform a corresponding state change based on the change data.

[0163] Corresponding to the game processing method provided in the first embodiment of this application, the third embodiment of this application also provides an electronic device for executing the game processing method. For example... Figure 6As shown, the electronic device 600 includes: a processor 601; and a memory 602 for storing a program for a game processing method. After the device is powered on and the program for the game processing method is run by the processor, the following steps are performed:

[0164] Construct scene images corresponding to the game scenes, and each scene image is run through a different game process;

[0165] Assign virtual characters to each of the aforementioned scene mirrors;

[0166] Based on the character metadata of the first virtual character, create a first character image corresponding to the first virtual character in a second scene image other than the first scene image where the first virtual character is located;

[0167] In response to a state change of the first virtual character in the first scene mirror, the change data corresponding to the state change is calculated through the game process corresponding to the first scene mirror, and the first character image in the second scene mirror is controlled to perform a corresponding state change based on the change data.

[0168] Corresponding to the game processing method provided in the first embodiment of this application, the fourth embodiment of this application provides a computer-readable storage medium storing a program for the game processing method, which is executed by a processor to perform the following steps:

[0169] Construct scene images corresponding to the game scenes, and each scene image is run through a different game process;

[0170] Assign virtual characters to each of the aforementioned scene mirrors;

[0171] Based on the character metadata of the first virtual character, create a first character image corresponding to the first virtual character in a second scene image other than the first scene image where the first virtual character is located;

[0172] In response to a state change of the first virtual character in the first scene mirror, the change data corresponding to the state change is calculated through the game process corresponding to the first scene mirror, and the first character image in the second scene mirror is controlled to perform a corresponding state change based on the change data.

[0173] It should be noted that for a detailed description of the apparatus, electronic device and computer-readable storage medium provided in the second, third and fourth embodiments of this application, please refer to the relevant description of the first embodiment of this application, which will not be repeated here.

[0174] Although this application discloses preferred embodiments as described above, it is not intended to limit this application. Any person skilled in the art can make possible changes and modifications without departing from the spirit and scope of this application. Therefore, the scope of protection of this application should be determined by the scope defined in the claims of this application.

[0175] In a typical configuration, a node device in a blockchain includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0176] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0177] 1. Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage media, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include non-transitory computer-readable media, such as modulated data signals and carrier waves.

[0178] 2. Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0179] Although this application discloses preferred embodiments as described above, it is not intended to limit this application. Any person skilled in the art can make possible changes and modifications without departing from the spirit and scope of this application. Therefore, the scope of protection of this application should be determined by the scope defined in the claims of this application.

Claims

1. A game processing method characterized by comprising: The method comprises: constructing a scene mirror corresponding to a game scene, each of the scene mirrors being run through a different game process, the scene mirror corresponding to the game scene being a copy identical to the game scene; allocating a virtual role in each of the scene mirrors; creating a first role mirror corresponding to a first virtual role in a second scene mirror of the scene mirrors other than a first scene mirror in which the first virtual role is located, according to role metadata of the first virtual role, the role metadata comprising role attribute information of the first virtual role; in response to a state change of the first virtual role in the first scene mirror, calculating change data corresponding to the state change through a game process corresponding to the first scene mirror, and controlling the first role mirror in the second scene mirror to perform a corresponding state change based on the change data, the second scene mirror being a scene mirror corresponding to the same game scene as the first scene mirror and containing different virtual role entities.

2. The method of claim 1, wherein, The response to the state change of the first virtual role in the first scene mirror, the calculation of change data corresponding to the state change through a game process corresponding to the first scene mirror, and the control of the first role mirror in the second scene mirror to perform a corresponding state change based on the change data, comprises: in response to an interaction between the first virtual role and other virtual roles or role mirrors corresponding to the other virtual roles in the first scene mirror, calculating interaction data generated in the interaction process through a game process corresponding to the first scene mirror; controlling the first role mirror in the second scene mirror to synchronously perform the interaction process indicated by the interaction data on the other virtual roles and / or the role mirrors corresponding to the other virtual roles.

3. The method of claim 2, wherein, In the case where the interaction process is an active attack initiated by the first virtual role on other virtual roles or role mirrors corresponding to the other virtual roles in the first scene mirror, the calculation of interaction data generated in the interaction process through a game process corresponding to the first scene mirror comprises: calculating attack data generated in the process of the active attack through a game process corresponding to the first scene mirror; wherein the active attack comprises at least one of the following: an attack initiated by the first virtual role, a counterattack by the first virtual role based on an attack received; The control of the first role mirror in the second scene mirror to synchronously perform the interaction process indicated by the interaction data on the other virtual roles and / or the role mirrors corresponding to the other virtual roles based on the interaction data comprises: controlling the first role mirror in the second scene mirror to synchronously perform the process of the active attack indicated by the attack data on the other virtual roles and / or the role mirrors corresponding to the other virtual roles based on the attack data.

4. The method of claim 2, wherein, In a case where the interaction process is that the first virtual role is attacked by other virtual roles or the role mirror corresponding to the other virtual roles in the first scene mirror, the interaction data generated in the interaction process is calculated through the game process corresponding to the first scene mirror, and the interaction data includes: Attack data generated in the attack process is calculated through the game process corresponding to the first scene mirror; The first role mirror in the second scene mirror is controlled to synchronously perform the interaction process indicated by the interaction data on the other virtual roles and / or the role mirror corresponding to the other virtual roles based on the interaction data, and the interaction process includes: The first role mirror in the second scene mirror is controlled to synchronously perform the attack process indicated by the attack data based on the attack data.

5. The method of claim 1, wherein, In a case where the interaction process is that the first virtual role is attacked by other virtual roles or the role mirror corresponding to the other virtual roles in the first scene mirror, the interaction data generated in the interaction process is calculated through the game process corresponding to the first scene mirror, and the interaction data includes: Attack data generated in the attack process is calculated through the game process corresponding to the first scene mirror; The first role mirror in the second scene mirror is controlled to synchronously perform the interaction process indicated by the interaction data on the other virtual roles and / or the role mirror corresponding to the other virtual roles based on the interaction data, and the interaction process includes:

6. The method of claim 5, wherein, The first role mirror in the second scene mirror is controlled to synchronously perform the attack process indicated by the attack data based on the attack data.

7. The method of claim 1, wherein, The synchronization condition includes at least one of the following conditions: synchronization is performed when the state data no longer changes within a preset time length, synchronization is performed according to a preset period, and synchronization is performed when data changes of the state data accumulate to a preset change amount. The method further includes: When a time point at which a target non-player role appears in the game scene is reached, a second virtual role having a minimum distance between a current position of the second virtual role and a preset appearance position of the target non-player role in the game scene is determined from the virtual roles in the game scene, the target non-player role being a role appearing at the preset appearance position in a game process; The target non-player role is placed at the preset appearance position in a third scene mirror in which the second virtual role is located; 8. The method of claim 1, wherein, According to non-player role metadata of the target non-player role, a target non-player role mirror corresponding to the target non-player role is created in scene mirrors other than the third scene mirror.

9. The method of claim 1, wherein, The virtual role includes one or more of a role body and a role avatar. The first role mirror in the second scene mirror is controlled to synchronously perform the interaction process indicated by the interaction data on the other virtual roles and / or the role mirror corresponding to the other virtual roles based on the interaction data, and the interaction process includes: The first role mirror in the second scene mirror is controlled to synchronously perform the attack process indicated by the attack data based on the attack data. In response to a state change of the first virtual character in the first scene mirror, the first scene mirror corresponding game process calculates change data corresponding to the state change, and sends the change data to the second scene mirror corresponding game process through the first scene mirror corresponding game process; The second scene mirror corresponding game process receives the change data, and controls the first character mirror in the second scene mirror to make a corresponding state change based on the change data.

10. A game processing device, characterized by comprising: The device comprises: A construction unit for constructing a scene mirror corresponding to a game scene, each scene mirror being run through a different game process, the scene mirror corresponding to the game scene being a copy identical to the game scene; An allocation unit for allocating virtual characters in each scene mirror; A creation unit for creating a first character mirror corresponding to a first virtual character in a second scene mirror other than a first scene mirror where the first virtual character is located according to character metadata of the first virtual character, the character metadata including character attribute information of the first virtual character; A synchronization unit for, in response to a state change of the first virtual character in the first scene mirror, calculating change data corresponding to the state change through the first scene mirror corresponding game process, and controlling the first character mirror in the second scene mirror to make a corresponding state change based on the change data, the second scene mirror being a scene mirror containing different virtual character entities corresponding to the same game scene as the first scene mirror.

11. An electronic device, comprising: Comprise: A processor; And A memory for storing a data processing program, after the electronic device is powered on and the program is run through the processor, the method as claimed in any one of claims 1-9 is executed.

12. A computer-readable storage medium, characterized in that, A data processing program is stored, the program is run by a processor, and the method as claimed in any one of claims 1-9 is executed.

Citation Information

Patent Citations

  • Game control method and device, game terminal and storage medium

    CN109568937A

  • Role interaction method and device, terminal, storage medium and program product

    CN114432700A