A data synchronization method, device and medium

By establishing a direct communication connection between clients and directly sending and combining operational data packets, the problem of data synchronization delay in the prior art is solved, and more efficient data synchronization and lower server costs are achieved.

CN114432693BActive Publication Date: 2025-06-03TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202011121903.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-20
Publication Date
2025-06-03
Estimated Expiration
2040-10-20

AI Technical Summary

Technical Problem

There is a large delay in the data synchronization process in existing games, which makes it impossible for the client to update the display screen in time.

Method used

Establish a direct communication connection between clients, and each client sends operation data directly to other clients without having to pass the server. Each client generates the current data packet, combines the data packets of other clients to generate the current data frame, and updates the display screen according to the data frame.

Benefits of technology

It reduces the delay in the data synchronization process, improves the real-time performance of terminal updates on display screens based on data, and reduces server deployment and hardware costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114432693B_ABST
    Figure CN114432693B_ABST
Patent Text Reader

Abstract

This application relates to the field of computer technology, and provides a data synchronization method, device, and medium. This method is used to reduce the latency in the process of controlling data synchronization. The method includes: The first client generates the current data packet of the first client according to the operation data of the first collaborative user in the first client; sends the current data packet of the first client to the second clients of each other collaborative user respectively; receives the current data packets sent by each second client respectively; combines the operations in the current data packet of the first client and the current data packets sent by each second client respectively to obtain the current data frame of the first client; updates the display screen of the first client according to the current data frame. This method directly sends data packets between clients without the need for server transit. The client frames according to all the received data packets and updates the display, realizing low-latency display update.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and particularly to the field of game technology, and provides a data synchronization method, device, and medium. Background Art

[0002] In order for game players in a game session to play together, it is necessary to synchronize data between the clients of different game players, so as to ensure that the presentation of the game application on different clients is consistent.

[0003] Currently, a commonly used solution for data synchronization in games is frame synchronization. The specific idea of frame synchronization is as follows: The server receives the operation information of different game players from each client, combines the operation information of each game player into a data frame, and sends the data frame to each client. Each client processes and displays according to the received data frame. In frame synchronization, the data synchronization of each client depends on the server for relay, and there will inevitably be a certain delay during the server relay process. Summary of the Invention

[0004] Embodiments of this application provide a data synchronization method, device, and medium for reducing the delay during data synchronization.

[0005] On the one hand, a data synchronization method is provided for the client corresponding to a target application for multi-person collaboration, where the clients of each collaborating user in the multi-person collaboration are communicatively connected. The method includes:

[0006] After the first client of the first collaborating user updates its own display screen according to the previous data frame, a current data packet of the first client is generated according to the operation data of the first collaborating user in the first client;

[0007] The current data packet of the first client is respectively sent to the second clients of each other collaborating user;

[0008] The current data packets respectively sent by each second client are respectively received;

[0009] The operations in the current data packet of the first client and the current data packets respectively sent by each second client are combined to obtain the current data frame of the first client;

[0010] The display screen of the first client is updated according to the current data frame.

[0011] Embodiments of this application provide a data synchronization device, which is set in the client corresponding to a target application for multi-person collaboration, where the clients of each collaborating user in the multi-person collaboration are communicatively connected. The device includes:

[0012] A generation module, configured to generate a current data packet of the first client according to the operation data of the first collaborative user in the first client after updating its own display screen according to the previous data frame;

[0013] A transceiver module, configured to send the current data packet of the first client to the second clients of each other collaborative user respectively; and receive the current data packets sent by each second client respectively;

[0014] A frame combination module, configured to combine the operations in the current data packet of the first client and the current data packets sent by each second client respectively to obtain the current data frame of the first client;

[0015] An update module, configured to update the display screen of the first client according to the current data frame.

[0016] In a possible embodiment, the current data packet of the first collaborative user and the current data packets of each other collaborative user both include a data packet identifier, and the data packet identifier is used to indicate the order of generating the data packet by the client; the frame combination module is specifically configured to:

[0017] Determine the current data packets of each other collaborative user with the same data packet identifier as the current data packet of the first client;

[0018] Form a current data frame with the operation data in the current data packet of the first client and the operation data in the determined current data packets of each other collaborative user.

[0019] In a possible embodiment, if the second clients of each other collaborative user include a main client, and the device is arranged in a slave client; the transceiver module is specifically configured to:

[0020] If the current time error is not within a preset range, adjust the preset time interval; wherein, the current time error refers to the time difference between the current time of the main client and the current time of the first client;

[0021] After reaching the adjusted preset time interval, send the current data packet of the first client to the second clients of each other collaborative user.

[0022] In a possible embodiment, the transceiver module is specifically configured to:

[0023] If the current time error is greater than the maximum value of the preset range, the preset time interval will be reduced. After reaching the reduced preset time interval, the current data packet of the first client will be sent to the second clients of the respective other collaborating users; wherein, the current time error refers to the time difference between the current time of the master client and the current time of the first client.

[0024] If the current time error is less than the minimum value of the preset range, the preset time interval will be increased. After reaching the increased preset time interval, the current data packet of the first client will be sent to the second clients of the respective other collaborating users.

[0025] In a possible embodiment, the transceiver module is further configured to:

[0026] If the time error between the master client and the first client is already within the preset range, subsequent data packets will be sent to the second clients of the respective other collaborating users at the preset time interval.

[0027] Wherein, the subsequent data packets are generated based on the operation data of the first collaborating user in the first client after updating their display screens according to the current data frame.

[0028] In a possible embodiment, the device further includes a determination module, wherein:

[0029] The transceiver module is further configured to send a speed measurement detection packet to the master client and receive a speed measurement response packet feedback by the master client;

[0030] The determination module is further configured to determine the current delay value between the first client and the master client according to the time when the speed measurement detection packet is sent and the time when the speed measurement response packet is received;

[0031] According to the current delay value, the maximum value of the data packet identifier of the current data packet sent by the received master client, and the preset time interval, determine the current time error between the master client and the first client.

[0032] In a possible embodiment, the device further includes an establishment module, wherein:

[0033] The generation module is further configured to generate a game request in response to a requested game operation;

[0034] The transceiver module is further configured to receive the communication addresses of the clients of the respective other collaborating users participating in the current game feedback by the server after sending the game request to the server;

[0035] The establishing module is configured to establish a communication connection between the first client and the second clients of the respective other collaborating users according to the communication addresses of the clients of the respective other collaborating users.

[0036] In a possible embodiment, the updating module is specifically configured to:

[0037] Determine the current states of the game characters corresponding to the respective operation data according to the respective operation data in the current data frame;

[0038] Update the display screen of the first client according to the current states of the game characters corresponding to the respective operation data.

[0039] An embodiment of the present application provides a computer device, including:

[0040] At least one processor, and

[0041] A memory communicatively connected to the at least one processor;

[0042] Wherein, the memory stores instructions executable by the at least one processor, and the at least one processor realizes the method according to any one of the aspects by executing the instructions stored in the memory.

[0043] An embodiment of the present application provides a storage medium, and the storage medium stores computer instructions, and when the computer instructions run on a computer, the computer is caused to execute the method according to any one of the aspects.

[0044] Since the embodiment of the present application adopts the above technical solutions, it has at least the following technical effects:

[0045] In the embodiment of the present application, the client can directly send the obtained data packet including operation data to other clients without passing through the server for transfer, reducing the delay of data transmission and reception, thereby improving the real-time performance of the terminal to update the display screen based on the data, and without passing through the server for transfer, reducing the server deployment and hardware costs, etc. Moreover, since each client does not need to transmit and receive a large amount of data, it is applicable to the frequent transmission and reception of data packets between each client, and improves the frequency of the client to update the display screen. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 An interaction schematic diagram among devices in a frame synchronization provided for the related art;

[0047] Figure 2 An application scenario example diagram of a data synchronization method provided by an embodiment of the present application;

[0048] Figure 3 Provided by an embodiment of the present applicationFigure 1 Interaction schematic diagram among various devices

[0049] Figure 4 Example diagram of communication connection among various clients provided by an embodiment of the present application

[0050] Figure 5 Example diagram of a data frame provided by an embodiment of the present application

[0051] Figure 6 Example diagram of the process of updating a display screen provided by an embodiment of the present application

[0052] Figure 7 Example diagram of adjusting time provided by an embodiment of the present application

[0053] Figure 8 Schematic structural diagram of a data synchronization device provided by an embodiment of the present application

[0054] Figure 9 Schematic structural diagram of a computer device provided by an embodiment of the present application Detailed implementation manners

[0055] In order to better understand the technical solutions provided by the embodiments of the present application, the following will be described in detail in conjunction with the accompanying drawings of the specification and specific implementation manners.

[0056] In order to facilitate those skilled in the art to better understand the technical solutions of the present application, the following introduces the terms involved in the present application.

[0057] Cloud technology: It refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or a local area network to achieve data calculation, storage, processing, and sharing. Cloud technology is the general term for network technology, information technology, integration technology, management platform technology, application technology, etc. based on the cloud computing business model, which can form a resource pool, be used on demand, and be flexible and convenient. Cloud computing technology will become an important support. The background services of the technical network system require a large amount of computing and storage resources, such as video websites, picture websites, and more portal websites. With the high development and application of the Internet industry, in the future, each item may have its own identification mark and needs to be transmitted to the background system for logical processing. Data at different levels will be processed separately, and various industry data requires a powerful system background support, which can only be achieved through cloud computing.

[0058] Application: Generally refers to a program that can be used to implement certain functions. In the embodiments of the present application, an application generally refers to an application that can achieve multi-person collaboration. A client refers to the carrier of the application in each terminal, which can be a web version client, or a client pre-installed in the terminal, or a client embedded in a third-party application. Applications for multi-person collaboration include, for example, game applications, or instant messaging applications, etc.

[0059] Data frame: Refers to a data frame composed of the operation data of each collaborative user in multi-person collaboration. In the client, the client updates its own display screen according to a continuous data frame {rame1, frame2... frameN}. Each data frame includes the operation data of each collaborative user, that is, frame = [input of collaborative user 1] + [input of collaborative user 2] +... + [input of collaborative user n]. The input of a collaborative user can be an empty input without any valid information.

[0060] Preset time interval: In the embodiments of the present application, it refers to the period for the client to send data packets to other clients. At the beginning, the values of the preset time intervals of each client are the same. During the process of sending data packets, each client will adjust the value of the preset time interval according to the actual situation to achieve time synchronization with the main client. The preset time interval is inversely related to the frame rate of the client. For example, if the frame rate is 30 frames per second, then the corresponding preset time interval is 1 / 30 second.

[0061] The following introduces the related technologies:

[0062] Please refer to Figure 1 In the frame synchronization scheme provided by the related technology shown in the following, the interaction example diagram between the server and the client. The following combines Figure 1 to give an example and explanation of the frame synchronization scheme of the related technology.

[0063] The first client P1 collects the first operation data of the first user in the first time period. The first client P1 sends the first operation data to the server S. The second client P2 can send the second operation data to the server S. The server S receives the first operation data and the second operation data to form a data frame.

[0064] The server S distributes the data frame to the first client P1 and the second client P2. After the first client P1 and the second client P2 receive the data frame, they update their current display screens according to the data frame. After an interval of the preset duration, the above process is repeated, so as to achieve consistent game presentation of each client during the use of the application by each collaborative user.

[0065] However, in this related technology, the server S needs to receive each operation data for framing, and after framing, it needs to send the framing result to each client. That is to say, in fact, the server needs to transfer the operation data, and extra time is inevitably consumed during the transfer process, resulting in the client being unable to update the display screen in time after the operation, that is, there is a large time delay in the data synchronization process.

[0066] The design concept of the embodiments of the present application will be introduced below.

[0067] To this end, the embodiments of the present application provide a data synchronization method. After establishing communication between each client, each client sends the operation data to other clients. In this way, each client can receive the operation data sent by other clients, directly frame these operation data by the client, and update its own display screen according to the formed data frame. Since there is no need for the server to transfer the operation data in this solution, the delay in the process of sending the operation data can be reduced, and the real-time performance of the control application can be improved. Moreover, since the client does not need to bear a large amount of data transceiver, this solution can be applied to the situation where the client frequently sends and receives operation data, thereby improving the timeliness of sending and receiving operation data and the frequency of updating the display screen of the client.

[0068] Based on the above design concept, the application scenario of the data synchronization method of the embodiments of the present application will be introduced below.

[0069] Please refer to Figure 2 the shown scenario application diagram. This scenario includes multiple terminals 210 and a server 220. Each terminal 210 is installed with a client 211 corresponding to the multi-person collaboration application, and the server 220 is the background server corresponding to the multi-person collaboration application. The terminal 210 includes, for example, Figure 2 the first terminal 210-1 and the second terminal 210-2 in. The first terminal 210-1 is installed with the first client 211-1, the second terminal 210-2 is installed with the third client 211-2, and the third terminal 210-3 is installed with the fourth client 211-3. For the sake of description, the collaborative user corresponding to the first terminal 210-1 is called the first collaborative user, and can also be simply called the first user. The user corresponding to the second terminal 210-2 is called the second collaborative user, and can also be simply called the second user. The user corresponding to the third terminal 210-1 is called the third collaborative user, and can also be called the third user. Among them, both the third client 211-2 and the fourth client 211-3 can be regarded as the second clients of other users participating in the collaboration in the previous text.

[0070] When the first user is ready to use the application, the first user can operate through the first client 211-1. The first client 211-1 generates an application request and sends the application request to the server 220.

[0071] The server 220 determines the users participating in the application for the first client 211-1 and generates a multi-person collaboration team. The server 220 sends the multi-person collaboration team information to each client and sends the communication addresses of each client in the multi-person collaboration team to each client, so that the clients in the multi-person collaboration team can establish a communication connection.

[0072] Alternatively, the clients 211 do not need to establish a connection with the help of the server 220. For example, according to the user's operation, the corresponding account identifier of other clients can be obtained, and the communication with other clients 211 can be established using the account identifier. For example, in a click game scenario, each client 211 can establish a communication connection with other clients according to the game account of other users input by the user.

[0073] After the communication connections are established among the clients, each client can obtain operation data according to the user's operation and send the operation data to other clients in the multi-person collaboration team. Other clients can frame the operation data of all clients in the multi-person collaboration team and display according to the formed data frame, so as to realize the synchronization of the display screens of each client.

[0074] Among them, the server 220 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, Content Delivery Network (CDN), and big data and artificial intelligence platforms. The terminal 210 can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a smart game device, a vehicle-mounted terminal, etc., but is not limited thereto. The terminal 210 and the server 220 can be directly or indirectly connected through wired or wireless communication methods, and this application does not make any restrictions here.

[0075] Based on the above scenario, the following combines Figure 3 the Figure 1 interaction process diagram among the devices shown to introduce the data synchronization method involved in the embodiments of this application by taking the multi-person collaboration application as a game application:

[0076] S301, each client 211 sends a game request to the server 220.

[0077] Each client 211 generates a game request in the same way. Here, an example is given by taking the first client 211-1 generating a game request:

[0078] The first user can perform a game operation on the first client 211-1, and the first client 211-1 responds to the game operation and generates a game request. The game request is used to request the creation of a game session, and the communication address of the first client 211-1 can be carried in the game request.

[0079] It should be noted that the order in which each client 211 sends a game request can be arbitrary, and the present application does not make specific limitations.

[0080] It should be noted that when the first client 211-1 of the first user is used as the execution subject, both the third client 211-2 and the fourth client 211-3 can be regarded as the second clients of other users participating in cooperation in the foregoing text.

[0081] S302. The server 220 creates a game session and generates game session information.

[0082] After the server 220 receives the game requests sent by each client 211, if it determines that each client 211 needs to join the game session, it can create a game session and allocate each client 211 to the corresponding game session. For example, the server 220 can allocate a preset number of users within the same region of the client 211 to the same game session, or the server 220 can allocate users with the same game level to the same game session.

[0083] After the server 220 creates a game session and allocates a game session to each client, it also determines each client participating in the game session and can obtain the game session information. The game session information refers to the information of the currently created game session, and the game session information includes a game session identifier and the communication addresses of each client 211 participating in the game session.

[0084] S303. The server 220 sends the game session information to each client 211 participating in the game session.

[0085] For example, if the server 220 determines that the first client 211-1, the third client 211-2, and the fourth client 211-3 participate in the same game session, then the server 220 can send the game session information to the first client 211-1, the third client 211-2, and the fourth client 211-3 respectively.

[0086] S304. A communication connection is established between each client 211 participating in the game session.

[0087] The first client 211-1, the third client 211-2, and the fourth client 211-3 receive game session information. Each client 211 can establish a communication connection with other clients according to the communication addresses of other clients. The method for each client to establish communication with other clients is the same. The following uses the method of the first client 211-1 to establish communication connections with the third client 211-2 and the fourth client 211-3 as an example for illustration:

[0088] The first client 211-1 can send connection requests to the third client 211-2 and the fourth client 211-3. The connection requests can carry game session identifiers. After receiving the connection requests, the third client 211-2 and the fourth client 211-3 verify whether the game session identifiers are the same as the game session identifiers in the game session information they received. If they are the same, it is determined that the first client 211-1 is a legitimate client, and then a connection response can be sent to the first client 211-1, thus completing the communication connections between the first client 211-1, the third client 211-2, and the fourth client 211-3.

[0089] After the first client 211-1, the third client 211-2, and the fourth client 211-3 establish communications with each other, it can be represented as Figure 4 the example diagram shown Figure 4 in which P1 represents the first client, P2 represents the third client, and P3 represents the fourth client. As Figure 4 shown, after the first client 211-1, the third client 211-2, and the fourth client 211-3 establish communication connections, any two clients can communicate with each other.

[0090] As an embodiment, S301 to S304 are optional parts.

[0091] In a possible embodiment, for example, in a single-player game, the first client 211-1 can directly create a game session in the first client 211-1. The first client 211-1 can, according to the game account identifiers of the second user input by the first user and the game account identifier of the third user, establish communications with other clients respectively according to the game account identifiers of the second user and the third user.

[0092] Regardless of which of the above communication methods is adopted, after the clients 211 establish communication connections in the game session, they enter the game. After entering the game, each client 211 can display the initial screen of the game according to the game characters and game scenes corresponding to each user.

[0093] S305. The first client 211-1 generates a first data packet of the first user according to the operation of the first user.

[0094] During the game process, the first user can perform corresponding operations according to the game progress. The first client 211-1 can generate a first data packet based on the operations of the first user within a preset time period. It can be understood that the first data packet of the first user includes the operation data of the first user within the preset time period. The value of the preset time period can be arbitrary and is not specifically limited in this application. The operation data of the first user within the preset time period can specifically include the operation data of multiple operations, or the operation data of one operation, or there may be no operation. For example, during the game process, it is possible that the first user does not perform any operation within the preset time period, then the operation data of this first user in the first data packet is empty.

[0095] For example, the operation of the user clicking on skill 1 can be represented as 0001, and the operation of the user clicking on skill 2 can be represented as 0002.

[0096] It should be noted that the first data packet can be regarded as the current data packet when being processed. That is to say, the current data packet can be understood as the data packet currently being processed. That is, any data packet can be regarded as the current data packet when being processed.

[0097] As an embodiment, since the client continuously generates data packets, in order to facilitate distinguishing the data packets corresponding to each preset time period, the first data packet can also carry a data packet identifier. This data packet identifier is used to indicate the order of the data packets generated by the client. Since the client generates the data packets for each preset time period in a cycle, the data packet identifier actually indicates the time period when the data packet is generated. The data packet identifier can, for example, increase sequentially starting from 0.

[0098] For example, the first data packet generated by the first client 211-1 based on the operation data from the 0th second to the 1st second is represented as 0; the first data packet generated by the first client 211-1 based on the operation data from the 1st second to the 2nd second is represented as 1, and so on.

[0099] S306. The first client 211-1 sends the first data packet to other clients.

[0100] After generating the first data packet, the first client 211-1 can send the first data packet to the third client 211-2 and the fourth client 211-3 after reaching a preset time interval. The preset time interval is inversely related to the sending frequency. If the sending frequency is higher, the value of the preset time interval is smaller; if the sending frequency is smaller, the value of the preset time interval is larger. This sending frequency can also be referred to as the frame rate. The higher the sending frequency, the higher the frequency at which the client updates the display screen, but the processing load of the client is relatively large.

[0101] For example, if the preset time interval is 3 seconds, then after obtaining the first data packet of the second user, the first client 211-1 will send the first data packet of the first user to the third client 211-2 and the fourth client 211-3 after 3 seconds.

[0102] S307. The third client 211-2 generates the first data packet of the second user according to the operations of the second user.

[0103] Similarly, in the game, the third client 211-2 can also generate the first data packet according to the operations of the second user within a preset duration. Further, the first data packet of the second user carries a data packet identifier, and the specific meaning of the data packet identifier can refer to the content described above and will not be elaborated here.

[0104] It should be noted that the order of S305 and S307 is synchronous.

[0105] S308. The third client 211-2 sends the first data packet of the second user to other clients.

[0106] Similarly, after obtaining the first data packet of the second user, the third client 211-2 can send the first data packet of the second user to the first client 211-1 and the fourth client 211-3 after reaching a preset time interval.

[0107] It should be noted that the order of S306 and S308 can be synchronous.

[0108] S309. The fourth client 211-3 generates the first data packet of the third user according to the operations of the third user.

[0109] Similarly, the fourth client 211-3 can collect the operation data of the third user within a preset duration and generate the first data packet of the third user. Further, the first data packet of the third user carries a data packet identifier, and the specific meaning of the data packet identifier can refer to the content described above and will not be elaborated here.

[0110] S310. The fourth client 211-3 sends the first data packet of the third user to other clients.

[0111] Similarly, after the fourth client 211-3 obtains the first data packet of the third user, it can send the first data packet of the third user to the third client 211-2 and the first client 211-1 after reaching the preset time interval.

[0112] S311. Each client 211 forms a first data frame according to each first data packet.

[0113] The frame-forming method of each client 211 is the same. The following is an example of the method for the first client 211-1 to form the first data frame:

[0114] After the first client 211-1 obtains the first data packet of the first user, the first data packet of the second user, and the first data packet of the third user, it can combine the operation data in each data packet in a preset order to form a data frame, thereby obtaining the first data frame. The preset order can be arbitrary and is not limited in this application. For example, the preset order can be set according to the order in which each user joins the game. For example, the first user joins the game first, the second user joins the game after the first user, and the third user joins the game after the second user. Then, when forming the data frame, it can be arranged in the order of the operation data of the first user, the operation data of the second user, and the operation data of the third user in sequence to form the data frame.

[0115] Furthermore, since the first client 211-1 may receive multiple data packets sent by a certain client, the first client 211-1 can select the data packets of other users with the same data packet identifier as the first data packet of the first user according to the data packet identifiers of each data packet for frame formation, so as to obtain the operation data of all users in the same time period.

[0116] Similarly, the third client 211-2 and the fourth client 211-3 can both obtain the first data frame in the same way. Since each client participating in the game session can obtain the data packets of all clients participating in the game session, the data frames formed by each client according to these data packets are also the same.

[0117] For example, please refer to Figure 5 , which is an example diagram of a data frame. The data frame sequentially includes the operation data I1 in the first data packet of the first user, the operation data I2 in the first data packet of the second user, and the operation data I3 in the first data packet of the third user. Combining I1, I2, and I3 into a data frame, the data frame can be expressed as: (I1 + I2 + I3).

[0118] S312. Each client updates the display screen according to the first data frame.

[0119] All client devices update their display screens in the same way. Here, taking the first target client device 211-1 as an example to update its display screen, the description is as follows:

[0120] After obtaining the first data frame, the first target client device 211-1 can send the first data frame to the rendering module in the first target client device 211-1. The rendering module determines the current states of the game characters corresponding to the respective operation data according to the respective operations in the first data frame, and updates the display screen of the client device according to the current states of the game characters corresponding to the respective operation data. The state of a game character is used to represent the rendering state of the game character in the display screen, such as the position and speed of the game character, etc.

[0121] For example, the initial screen displayed by the first client device 211-1 is specifically as shown in Figure 6 (1) below. In Figure 6 (1) there are two teams. The red team includes the game characters shown by ID2 and ID3, and the blue team includes the game character shown by ID1. At the start of the game, the health bars 601 of all game characters are full. The first user performs the release operation of the third skill 602 on the first client device 211-1, and other users do not perform any operations. The first client device 211-1 receives the operation data corresponding to each user and forms the first data frame. The first client device 211-1 updates the display screen according to the first data frame, and the specific display is as shown in Figure 6 (2) below. Figure 6 (2) shows the skill effect 603 released by the game character shown by ID1, shows that the health in the health bar of the game character shown by ID2 decreases, and shows that the third skill 602 is in a cooling state with a countdown of 10 seconds. In addition, in Figure 6 (1) there is also a display of the overall combat power 604 of the red team and the overall combat power 605 of the blue team. The overall combat power can be understood as the weighted sum of the combat powers of the game characters in the team.

[0122] Since the start times of the game matches on different client devices may not be exactly the same, and there are differences in the accuracy of the timers of each client device, etc., all of which may result in different times for each client device. As the game match continues, the time errors between each client device may accumulate.

[0123] For example, continue to refer to Figure 4, assume that the time of client P1 is faster than that of client P2. The current time of client P1 corresponds to sending the 10th data packet, and the current time of client P2 corresponds to sending the 5th data packet. At this time, when client P1 displays a more detailed screen, it actually lacks the operation data in the 6th to 10th data packets of client P2. Therefore, client P1 cannot form a complete data frame for the 6th to 10th data packets, and thus cannot submit the data frame to the rendering module, resulting in a delay in updating the display screen of the client.

[0124] Therefore, to solve the above problems and keep the synchronization between clients as much as possible, in the embodiments of this application, among multiple clients for multi-person collaboration, there can be a main client. Except for the main client, the remaining clients are regarded as slave clients, or secondary clients. Each slave client can adjust its own data packet sending frequency according to the time error with the main client, so as to keep the time between clients as synchronized as possible. The following takes the third client 211-2 as the main client, and the first client 211-1 and the fourth client 211-3 as slave clients to introduce the process of time synchronization by way of example:

[0125] S313, The first client 211-1 sends a speed measurement probe packet to the third client 211-2.

[0126] The first client 211-1 can send a speed measurement probe packet to the main client at a fixed detection period, which can be set by the client. For example, it can be determined according to the data receiving and sending capabilities of the client, specifically, for example, once per second. The speed measurement probe packet is used to detect the time delay value of sending and receiving data packets between the first client 211-1 and the third client 211-2.

[0127] S314, The third client 211-2 sends a speed measurement response packet to the first client 211-1.

[0128] After receiving the speed measurement probe packet sent by the first client 211-1, the third client 211-2 can feedback a speed measurement response packet to the first client 211-1. This speed measurement response packet can actually be directly the speed measurement probe packet, that is, after receiving the speed measurement probe packet, the third client 211-2 immediately feeds back the speed measurement probe packet to the first client 211-1.

[0129] S315, The first client 211-1 determines the time error between the first client 211-1 and the third client 211-2.

[0130] Since the value of the time error corresponding to different moments may change, the time error refers to the time error determined at that moment. The time error refers to the time difference between the current time of the master client and the current time of the first client 211-1. The first client 211-1 can directly record its own current time, or determine its own current time according to the packet identifier of the sent data packet and the preset time interval for sending data packets. However, the first client 211-1 cannot directly obtain the current time of the third client. The following is an example of how the first client 211-1 determines the time of the third client 211-2:

[0131] For example, the first client 211-1 can request the current time of the third client 211-2 from the third client 211-2, and then determine the time error.

[0132] Or, for example, the first client 211-1 can determine the time delay value between itself and the third client 211-2 according to the time of sending the speed measurement detection packet and the time of receiving the speed measurement response packet. The first client 211-1 can determine the first time error between the first client 211-1 and the third client 211-2 according to the time delay value, the maximum value of the packet identifiers of the data packets sent by the received master client, and the preset time interval. The maximum value of the packet identifiers of the data packets sent by the received master client refers to the maximum value of the packet identifiers of the data packets sent by the master client received by the first client 211-1. The formula for calculating the time error is specifically expressed as follows:

[0133] [Time error] = [Current time of the master client] - [Current time of the secondary client] (1)

[0134] [Current time of the master client] = [Maximum value of the packets received from the master client * Preset time interval] + [Time delay value] / 2 (2)

[0135] Among them, the maximum value of the packets received from the master client * Preset time interval can be understood as the current absolute time of the master client, and the time delay value divided by 2 can be understood as the delay of sending data packets.

[0136] Since the time error between the master client and the first client 211-1 changes during different time periods, the time error determined at the current time can also be called the current time error.

[0137] The time error determined at the current time can also be regarded as the current time error.

[0138] It should be noted that the order of the parts of S315~S316 and the parts of S305~S306 can be arbitrary, and there is no specific limitation.

[0139] S316. The first client 211-1 generates a second data packet according to the operations of the first user.

[0140] As the game progresses, the first client 211-1 can generate a second data packet according to the operations of the first user within the next preset time period. The second data packet includes the operation data of the first user within the next preset time period.

[0141] It should be noted that the second data packet and the first data packet are generated from the operation data of the first user at different time periods. When processing the second data packet, the second data packet can also be regarded as the current data packet. Further, the second data packet can also include a data packet identifier.

[0142] S317. The first client 211-1 adjusts the preset time interval according to the time error.

[0143] If the time error between the main client and the first client 211-1 does not fall within the preset range, then adjust the preset time interval according to the time error to achieve the purpose of adjusting the time error.

[0144] Specifically, if the time error between the main client and the first client 211-1 is greater than the maximum value of the preset range, this situation indicates that the time of the first client 211-1 is much slower than the time of the main client, that is, the time of the first client 211-1 is slower. Therefore, the first client 211-1 can reduce the preset time interval, that is, increase the frequency of sending data packets.

[0145] If the time error of the first client 211-1 is greater than the maximum value of the preset range and less than the first threshold, and the threshold is greater than the maximum value of the preset range, then it means that the first client 211-1 is only slightly slower than the main client. In this case, the value of the preset time interval can be increased to the first value, and the first value is used as the period for sending data packets. If the time error of the first client 211-1 is greater than the maximum value of the preset range and greater than the first threshold, then it means that the first client 211-1 is much slower than the main client. In this case, a one-time adjustment method can be adopted, for example, adjusting the preset time interval to zero and sending the data packet directly without waiting.

[0146] If the time error of the first client 211-1 is less than the minimum value of the preset range, then it means that the time of the first client 211-1 is faster than the time of the main client. Therefore, the preset time interval can be increased, that is, the frequency of sending data packets can be reduced. Therefore, the preset time interval can be increased, and the increased preset time interval is used as the period for sending data packets.

[0147] Specifically, if the time error of the first client 211-1 is less than the minimum value of the preset range and greater than the second threshold, where the second threshold is smaller than the minimum value of the preset range, it means that the time of the first client 211-1 is a little faster than that of the master client. Therefore, it can be slightly increased. For example, the value of the preset time interval is increased to the second value, and data packets are sent at the second value as the period.

[0148] Specifically, if the time error of the first client 211-1 is less than the minimum value of the preset range and less than the second threshold, it means that the time of the first client 211-1 is much faster than that of the master client. Therefore, the time error can be added to the preset time interval to obtain the third value, and after reaching the third value, data packets are sent. This can adjust the time error in place at one time.

[0149] If the time error of the first client 211-1 is within the preset range, it is determined that the preset time interval is not adjusted, that is, the first client 211-1 still sends data packets to other clients at the preset time interval as the period.

[0150] The following Figure 7 is an example introduction in combination with the following example diagram for adjusting time:

[0151] (1) If the time error of the first client 211-1 is within the preset range, Figure 7 taking the preset range as [-a, a] for example, the first client 211-1 does not adjust the preset time interval.

[0152] (2) If the time error of the first client 211-1 is greater than the maximum value within the preset range and less than the first threshold, that is, the time error is in the interval (a, b], it means that the time of the first client 211-1 is slower than that of the master client. Therefore, the first client 211-1 can use 0.8 * the preset time interval as the period for sending data packets until the time error is less than or equal to 0. For example, if the original preset time interval is 1 / 30, then the current preset time interval should be adjusted to 0.8 * 1 / 30.

[0153] (3) If the time error of the first client 211-1 is greater than the maximum value within the preset range and greater than the first threshold, that is, the time error is in the interval (b, +inf), it means that the time of the first client 211-1 is much slower than that of the master client. Therefore, data packets can be sent directly without waiting until the time error is less than or equal to 0. +inf represents infinity.

[0154] (4) If the time error of the first client 211-1 is less than the minimum value within the preset range and greater than the second threshold, that is, the time error is within the interval [-b, -a), it means that the time of the first client 211-1 is faster than the time of the master client. Therefore, the period for sending data packets can be 1.2 * the preset time interval until the time error is greater than or equal to 0.

[0155] (5) If the time error of the first client 211-1 is less than the minimum value within the preset range and less than the second threshold, that is, the time error is within the interval (-inf, b), it means that the time of the first client 211-1 is much faster than the time of the master client. Therefore, the period for sending data packets can be (the preset time interval + the time error) until the time error is greater than or equal to 0. -inf represents infinitely small.

[0156] It should be noted that after adjusting the preset time interval, when sending the next data packet, the data packet is sent at the adjusted preset time interval, and the data packets that have not been generated or sent at this time can be understood as subsequent data packets, that is, the data packets generated after the first data packet.

[0157] It should be noted that the step order of S317 and S316 can be arbitrary.

[0158] S318, the first client 211-1 sends the second data packet to other clients.

[0159] If the first client 211-1 adjusts the preset time interval, then the first client 211-1 adjusts the preset time interval in the manner of S317. After reaching the adjusted preset time interval, the second data packet is sent to the third client 211-2 and the fourth client 211-3.

[0160] If the first client 211-1 does not adjust the preset time interval, then after reaching the preset time interval, the second data packet is sent to the third client 211-2 and the fourth client 211-3.

[0161] S319, the fourth client 211-3 sends a speed measurement probe packet to the third client 211-2.

[0162] S320, the third client 211-2 sends a speed measurement response packet to the fourth client 211-3.

[0163] S321, the fourth client 211-3 determines the time error.

[0164] The fourth client 211-3 obtains the latency value with the main client according to the difference between the time when the speed measurement probe packet is sent and the time when the speed measurement response packet is received, and calculates the time error between the main client and the fourth client 211-3 according to the above formulas (1) and (2). For the content of determining the time error, please refer to the previous content and will not be elaborated here.

[0165] S322. The fourth client 211-3 generates a second data packet of the third user according to the operation of the third user.

[0166] The second data packet of the third user includes the operation data of the third user collected within the next preset duration.

[0167] S323. The fourth client 211-3 adjusts the preset time interval according to the time error.

[0168] For the content of the fourth client 211-3 adjusting the preset time interval, please refer to the content of the first client 211-1 adjusting the preset time interval discussed above and will not be elaborated here.

[0169] It should be noted that the step order of S322 and S323 can be arbitrary and will not be elaborated here.

[0170] S324. The fourth client 211-3 sends the second data packet of the third user to other clients.

[0171] If the fourth client 211-3 adjusts the preset time interval, then the fourth client 211-3 adjusts the preset time interval in the manner of S317. After reaching the adjusted preset time interval, it sends the second data packet to the third client 211-2 and the first client 211-1.

[0172] If the fourth client 211-3 does not adjust the preset time interval, then after reaching the preset time interval, it sends the second data packet to the third client 211-2 and the first client 211-1.

[0173] S325. The third client 211-2 generates a second data packet of the second user according to the operation of the second user.

[0174] The third client 211-2 generates a second data packet of the second user according to the operation of the second user within the next preset duration.

[0175] It should be noted that the step order of S325, S316 and S322 can be synchronous.

[0176] S326. The third client 211-2 sends the second data packet to other clients.

[0177] The third client 211-2 is the main client, so there is no need to adjust its time. It only needs to send data packets at a preset time interval. Therefore, after the third client 211-2 obtains the second data packet, after reaching the preset time interval, it can send the second data packet to the first client 211-1 and the fourth client 211-3.

[0178] As an embodiment, after the first client 211-1 executes S327, it continues to repeat the steps of S312 to S315, so as to obtain the time error between the main client and the first client 211-1 after sending the second data packet. If it is determined that the time error is within the preset range, the first client 211-1 does not adjust the preset time interval and sends subsequent data packets after reaching the preset time interval. Or, if it is determined that the time error is still not within the preset range, the first client 211-1 still sends subsequent data packets according to the adjusted preset time interval. The ways for other clients to adjust the preset time interval are the same and will not be elaborated here.

[0179] S327, each client respectively forms a second data frame according to each second data packet.

[0180] The ways for each client to form a data frame are the same. The following takes the first client 211-1 as an example for introduction:

[0181] After the first client 211-1 receives the second data packets sent by other clients, it can combine the operation data in each second data packet in a preset order to obtain a second data frame. It should be noted that any processed data frame can be regarded as the current data frame.

[0182] S328, each client updates the display screen according to the second data frame.

[0183] Each client can respectively frame to obtain a second data frame. After obtaining the second data frame, it can update the states of each game character according to the operation data in the second data frame, so as to update the display screen.

[0184] During the game process, the process of S305 to S328 will be continuously repeated, so as to realize the data synchronization process among each client during the game process.

[0185] The embodiment of the present application provides a data synchronization device, which is set in the client corresponding to the target application for multi-person cooperation. The clients of each collaborative user in the multi-person cooperation are communicatively connected. Please refer to Figure 8 , the device includes:

[0186] A generation module 801, configured to generate a current data packet of the first client according to the operation data of the first collaborative user in the first client after updating its own display screen according to the previous data frame;

[0187] A transceiver module 802, configured to send the current data packet of the first client to the second clients of each other collaborative user respectively; and receive the current data packets sent by each second client respectively;

[0188] A framing module 803, configured to combine the operations in the current data packet of the first client and the current data packets sent by each second client respectively to obtain a current data frame of the first client;

[0189] An update module 804, configured to update the display screen of the first client according to the current data frame.

[0190] In a possible embodiment, the current data packet of the first collaborative user and the current data packets of each other collaborative user both include a data packet identifier, and the data packet identifier is used to indicate the order of generating the data packet by the client; the framing module 803 is specifically configured to:

[0191] Determine the current data packets of each other collaborative user with the same data packet identifier as that of the current data packet of the first client;

[0192] Form a current data frame with the operation data in the current data packet of the first client and the operation data in the determined current data packets of each other collaborative user.

[0193] In a possible embodiment, if the second clients of each other collaborative user include a main client and the device is arranged in a slave client; the transceiver module 802 is specifically configured to:

[0194] If the current time error is not within a preset range, adjust the preset preset time interval; wherein, the current time error refers to the time difference between the current time of the main client and the current time of the first client;

[0195] After reaching the adjusted preset time interval, send the current data packet of the first client to the second clients of each other collaborative user.

[0196] In a possible embodiment, the transceiver module 802 is specifically configured to:

[0197] If the current time error is greater than the maximum value of the preset range, reduce the preset preset time interval, and after reaching the reduced preset time interval, send the current data packet of the first client to the second clients of each other collaborative user; wherein, the current time error refers to the time difference between the current time of the main client and the current time of the first client;

[0198] If the current time error is less than the minimum value of the preset range, the preset time interval will be increased, and after the increased preset time interval is reached, the current data packet of the first client will be sent to the second clients of each other collaborating user.

[0199] In a possible embodiment, the transceiver module 802 is further configured to:

[0200] If the time error between the main client and the first client is already within the preset range, subsequent data packets will be sent to the second clients of each other collaborating user at a preset time interval;

[0201] Among them, the subsequent data packets are generated according to the operation data of the first collaborating user in the first client after updating their display screens according to the current data frame.

[0202] In a possible embodiment, the device further includes a determination module 805, where:

[0203] The transceiver module 802 is further configured to send a speed measurement detection packet to the main client and receive a speed measurement response packet fed back by the main client;

[0204] The determination module 805 is further configured to determine the current delay value between the first client and the main client according to the time of sending the speed measurement detection packet and the time of receiving the speed measurement response packet;

[0205] According to the current delay value, the maximum value of the data packet identifier of the current data packet sent by the received main client, and the preset time interval, determine the current time error between the main client and the first client.

[0206] In a possible embodiment, the device further includes an establishment module 806, where:

[0207] The generation module 801 is further configured to generate a game request in response to a requested game operation;

[0208] The transceiver module 802 is further configured to receive the communication addresses of the clients of each other collaborating user participating in the current game fed back by the server after sending the game request to the server;

[0209] The establishment module 806 is configured to establish a communication connection between the first client and the second clients of each other collaborating user according to the communication addresses of the clients of each other collaborating user.

[0210] In a possible embodiment, the update module 804 is specifically configured to:

[0211] Determine the current states of the game characters corresponding to each operation data according to each operation data in the current data frame;

[0212] Update the display screen of the first client according to the current state of the game character corresponding to each operation data.

[0213] Figure 8 The device shown can also be used to implement any of the data synchronization methods discussed above, which will not be elaborated here.

[0214] Based on the same inventive concept, an embodiment of the present application provides a computer device 900. Please refer to Figure 9 , which includes a processor 901 and a memory 902.

[0215] The processor 901 can be a central processing unit (CPU) or a digital processing unit, etc. In the embodiments of the present application, the specific connection medium between the above-mentioned memory 902 and the processor 901 is not limited. In the embodiments of the present application Figure 9 , the memory 902 and the processor 901 are connected through a bus 903. The bus 903 is represented by a thick line in Figure 9 . The connection methods between other components are only for illustrative purposes and are not limited thereto. The bus 903 can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, Figure 9 only a thick line is used to represent it in , but it does not mean that there is only one bus or one type of bus.

[0216] The memory 902 can be a volatile memory, such as a random-access memory (RAM); the memory 902 can also be a non-volatile memory, such as a read-only memory, a flash memory, a hard disk drive (HDD) or a solid-state drive (SSD), or the memory 902 is any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory 902 can be a combination of the above memories.

[0217] The processor 901, when calling the computer program stored in the memory 902, executes any of the data synchronization methods discussed above, and can also be used to implement Figure 8 the functions of the device shown.

[0218] Based on the same inventive concept, an embodiment of the present application provides a storage medium that stores computer instructions. When the computer instructions run on a computer, the computer is caused to execute any of the data synchronization methods discussed above.

[0219] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented 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.

[0220] Based on the same inventive concept, an embodiment of the present application provides a computer program product, which includes computer instructions stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above data synchronization method.

[0221] Those of ordinary skill in the art can understand that all or part of the steps to implement the above method embodiments can be completed by hardware related to program instructions. The foregoing program can be stored in a computer-readable storage medium. When the program is executed, it performs the steps including the above method embodiments; and the foregoing storage medium includes: removable storage devices, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disks, or optical discs and other various media that can store program code.

[0222] Alternatively, if the above integrated unit of the present application is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the embodiment of the present application essentially or the part that contributes to the prior art can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the methods described in the embodiments of the present application. And the foregoing storage medium includes: removable storage devices, ROM, RAM, magnetic disks, or optical discs and other various media that can store program code.

[0223] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalent technologies, the present application also intends to include these changes and modifications.

Claims

1. A data synchronization method, characterized in that, in the client corresponding to the target application for multi-person collaboration, the clients of each collaborative user in the multi-person collaboration are communicatively connected, and the method includes: After the first client of the first collaborative user updates its own display screen according to the previous data frame, a current data packet of the first client is generated according to the operation data of the first collaborative user in the first client; Send the current data packet of the first client to the second clients of each other collaborative user respectively; Receive the current data packets sent by each second client respectively; Combine the operations in the current data packet of the first client and the current data packets sent by each second client respectively to obtain the current data frame of the first client; Update the display screen of the first client according to the current data frame, where: If the second clients of each other collaborative user include a main client, the first client is a slave client; the sending the current data packet of the first client to the second clients of each other collaborative user respectively specifically includes: If the current time error is not within the preset range, adjust the preset time interval; wherein, the current time error is the time difference between the current time of the main client and the current time of the first client; After reaching the adjusted preset time interval, send the current data packet of the first client to the second clients of each other collaborative user.

2. The method according to claim 1, characterized in that, The current data packets of the first collaborative user and the current data packets of each other collaborative user both include data packet identifiers, and the data packet identifiers are used to indicate the order of generating data packets by the clients; the combining the operations in the current data packet of the first client and the current data packets sent by each second client respectively to obtain the current data frame of the first client specifically includes: Determine the current data packets of each other collaborative user with the same data packet identifier as the current data packet of the first client; Form a current data frame with the operation data in the current data packet of the first client and the operation data in the determined current data packets of each other collaborative user.

3. The method according to claim 1, characterized in that, The if the current time error is greater than the maximum value of the preset range, then increase the preset time interval, and after reaching the adjusted preset time interval, send the current data packet of the first client to the second clients of each other collaborative user specifically includes: If the current time error is greater than the maximum value of the preset range, then decrease the preset time interval, and after reaching the reduced preset time interval, send the current data packet of the first client to the second clients of each other collaborative user; wherein, the current time error is the time difference between the current time of the main client and the current time of the first client; If the current time error is less than the minimum value of the preset range, the preset time interval will be increased. After the increased preset time interval is reached, the current data packet of the first client will be sent to the second clients of the respective other collaborating users.

4. The method according to claim 1, wherein, after sending the current data packet of the first client to the second clients of the respective other collaborating users, the method further includes: if the time error between the main client and the first client is already within the preset range, subsequent data packets will be sent to the second clients of the respective other collaborating users at intervals of the preset time interval; wherein, the subsequent data packets are generated based on the operation data of the first collaborating user in the first client after updating their own display screens according to the current data frame.

5. The method according to claim 1, 3 or 4, wherein, the method further includes: sending a speed measurement probe packet to the main client and receiving a speed measurement response packet feedback from the main client; determining the current latency value between the first client and the main client based on the time when the speed measurement probe packet is sent and the time when the speed measurement response packet is received; determining the current time error between the main client and the first client based on the current latency value, the maximum value of the data packet identifier of the current data packet sent by the received main client, and the preset time interval.

6. The method according to any one of claims 1 to 4, wherein, the method further includes: generating a game request in response to a requested game operation; after sending the game request to the server, receiving the communication addresses of the clients of the respective other collaborating users participating in the current game feedback from the server; establishing a communication connection between the first client and the second clients of the respective other collaborating users based on the communication addresses of the clients of the respective other collaborating users.

7. The method according to claim 6, wherein, the updating of the display screen of the first client according to the current data frame specifically includes: determining the current states of the game characters corresponding to the respective operation data based on the respective operation data in the current data frame; updating the display screen of the first client based on the current states of the game characters corresponding to the respective operation data.

8. A data synchronization device, wherein, the device is arranged in the client corresponding to the target application for multi-person collaboration, and the clients of the respective collaborating users in the multi-person collaboration are in communication connection with each other. The device includes: a generating module, configured to generate the current data packet of the first client based on the operation data of the first collaborating user in the first client after updating its own display screen according to the previous data frame; a transceiver module, configured to send the current data packet of the first client to the second clients of the respective other collaborating users respectively; and to receive the current data packets sent by the respective second clients respectively; A framing module, configured to combine the operations in the current data packet of the first client and the current data packets respectively sent by each second client, to obtain the current data frame of the first client; An update module, configured to update the display screen of the first client according to the current data frame, wherein: If one of the second clients of the other collaborative users is a master client, the first client is a slave client; the sending the current data packet of the first client to the second clients of each of the other collaborative users specifically includes: If the current time error is not within a preset range, adjust a preset time interval; wherein, the current time error refers to the time difference between the current time of the master client and the current time of the first client; After reaching the adjusted preset time interval, send the current data packet of the first client to the second clients of each of the other collaborative users.

9. A computer device, characterized in that, it includes: at least one processor, and a memory communicatively connected to the at least one processor; wherein, the memory stores instructions executable by the at least one processor, and the at least one processor realizes the method according to any one of claims 1 to 7 by executing the instructions stored in the memory.

10. A storage medium, characterized in that, the storage medium stores computer instructions, and when the computer instructions run on a computer, the computer is caused to execute the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Movement control method for role in game, server, and client

    CN105879391A

  • Method, device, storage medium, processor and terminal for data processing

    CN108310766A