Virtual scene data processing method and apparatus, and electronic device, storage medium and program product

By creating proxy copies of entity objects in the virtual scene and migrating them in stages, the problem of entity object migration errors in the existing technology is solved, and efficient and accurate virtual scene data processing is achieved.

WO2024212803A1PCT designated stage expired Publication Date: 2024-10-17TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/083899
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-14
Filing Date
2024-03-26
Publication Date
2024-10-17

AI Technical Summary

Technical Problem

When the existing technology implements entity object migration by packaging full data in the seamless world game application, errors are prone to occur and the effectiveness of the migration cannot be guaranteed.

Method used

By creating proxy copies of entity objects in the source space and destination space, and performing behavioral data synchronization and authorization migration during the migration process, it is divided into three stages: proxy creation, authorization migration, and proxy recycling, smoothing the migration process to improve the efficiency of migration. effectiveness.

Benefits of technology

It improves the efficiency of accurate positioning and problem solving of entity object migration, ensures the high timeliness and effectiveness of the migration process, and reduces the risk of system failure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024083899_17102024_PF_FP_ABST
    Figure CN2024083899_17102024_PF_FP_ABST
Patent Text Reader

Abstract

A virtual scene data processing method and apparatus, and an electronic device, a storage medium and a program product. The method comprises: displaying a virtual scene, wherein the virtual scene comprises an entity object; identifying the entity object from the virtual scene, and determining a source space and a destination space for migrating the entity object; performing proxy creation for the entity object in the source space, so as to obtain a first entity duplicate of the entity object; performing proxy creation for the entity object in the destination space, so as to obtain a second entity duplicate of the entity object, wherein behavior data of the second entity duplicate is synchronized to be behavior data of the first entity duplicate; performing granted migration on the first entity duplicate and the second entity duplicate, so as to obtain a first migrated entity duplicate and a second migrated entity duplicate; and performing proxy recovery on the first migrated entity duplicate and the second migrated entity duplicate.
Need to check novelty before this filing date? Find Prior Art

Description

Virtual scene data processing method, device, electronic device, storage medium and program product

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] The embodiments of this application are based on and claim the priority of Chinese patent application with application number 202310442543.8 and application date April 14, 2023. The entire contents of the Chinese patent application are hereby introduced into the embodiments of this application as a reference. Technical Field

[0003] The present application relates to computer technology, and in particular to a virtual scene data processing method, device, electronic device, storage medium and program product. Background Art

[0004] Display technology based on graphics processing hardware has expanded the channels for perceiving the environment and obtaining information, especially the display technology of the virtual world (such as the virtual scenes presented by the metaverse and the virtual scenes presented by game applications). It can realize the diversified movement of virtual objects controlled by users or artificial intelligence according to actual application needs, and has various typical application scenarios. For example, in virtual scenes such as games, it can simulate the interaction process between virtual objects.

[0005] In related technologies, in seamless world-based gaming applications, entity object migration is achieved by sending the full data of the real character (Real) to the server where the ghost character (Ghost) resides, and then switching between the Real and Ghost characters on the server. However, this solution of migrating entity objects by bundling the full data is prone to various errors and cannot guarantee the effectiveness of entity object migration.

[0006] Summary of the Invention

[0007] Embodiments of the present application provide a virtual scene data processing method, device, electronic device, computer-readable storage medium, and computer program product, which can improve the effectiveness of physical object migration.

[0008] The technical solution of the embodiment of the present application is implemented as follows:

[0009] The present invention provides a method for processing virtual scene data, which is applied to an electronic device. The method includes:

[0010] Displaying a virtual scene, wherein the virtual scene includes a physical object;

[0011] identifying the physical object from the virtual scene and determining a source space and a destination space for migrating the physical object;

[0012] Performing proxy creation on the entity object in the source space to obtain a first entity copy of the entity object;

[0013] Performing proxy creation on the entity object in the destination space to obtain a second entity copy of the entity object, wherein behavior data of the second entity copy is synchronized with the behavior data of the first entity copy;

[0014] Performing authorized migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy;

[0015] Perform proxy recycling on the first migration entity replica and the second migration entity replica.

[0016] The present invention provides a virtual scene data processing device, comprising:

[0017] an acquisition module configured to display a virtual scene containing a physical object; identify the physical object from the virtual scene, and determine a source space and a destination space for migrating the physical object;

[0018] a proxy creation module configured to perform proxy creation on the entity object in the source space to obtain a first entity copy of the entity object;

[0019] Performing proxy creation on the entity object in the destination space to obtain a second entity copy of the entity object, wherein behavior data of the second entity copy is synchronized with the behavior data of the first entity copy;

[0020] an authorization migration module configured to perform authorization migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy;

[0021] The proxy recycling module is configured to perform proxy recycling on the first migration entity replica and the second migration entity replica.

[0022] An embodiment of the present application provides an electronic device for migrating a physical object, the electronic device comprising:

[0023] Memory for storing computer programs or computer-executable instructions;

[0024] The processor is used to implement the virtual scene data processing method provided in the embodiment of the present application when executing the computer program or computer executable instructions stored in the memory.

[0025] An embodiment of the present application provides a computer-readable storage medium storing a computer program or computer-executable instructions. When the computer program or computer-executable instructions are executed by a processor, the virtual scene data processing method provided in the embodiment of the present application is implemented.

[0026] An embodiment of the present application provides a computer program product, including a computer program or computer-executable instructions. When the computer program or computer-executable instructions are executed by a processor, the virtual scene data processing method provided in the embodiment of the present application is implemented.

[0027] The embodiments of the present application have the following beneficial effects:

[0028] In the proxy creation phase, the first entity copy and the second entity copy are created; in the authorization migration phase, the first entity copy and the second entity copy are authorized for migration; in the proxy recovery phase, the proxy recovers the first migration entity copy and the second migration entity copy. Through the three phases of proxy creation phase, authorization migration phase and proxy recovery phase, the entity object migration process is smoothed. When problems occur during the entity object migration process, the stage where the problem occurs can be accurately located to quickly solve the problem and improve the effectiveness of entity object migration. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] FIG1 is a schematic diagram of an application mode of a virtual scene data processing method provided by an embodiment of the present application;

[0030] FIG2 is a schematic structural diagram of an electronic device for physical object migration provided by an embodiment of the present application;

[0031] 3A-3H are flowcharts of a method for processing virtual scene data according to an embodiment of the present application;

[0032] FIG4 is a schematic diagram of a virtual world of the metaverse provided in an embodiment of the present application;

[0033] FIG5 is a state flow diagram of entity object migration provided by an embodiment of the present application;

[0034] FIG6 is a schematic diagram of a process of creating an agent event according to an embodiment of the present application;

[0035] 7 is a schematic diagram of a polling process for creating an agent queue according to an embodiment of the present application;

[0036] FIG8 is a schematic diagram of a process flow of an authorization migration event provided in an embodiment of the present application;

[0037] FIG9 is a schematic diagram of a polling process of a migration queue provided in an embodiment of the present application;

[0038] 10 is a timing diagram of authorization migration of an entity object controlled by a client according to an embodiment of the present application;

[0039] FIG11 is a flow chart of an agent recovery method according to an embodiment of the present application;

[0040] FIG12 is a schematic diagram of a polling process of an agent recycling queue provided in an embodiment of the present application. DETAILED DESCRIPTION

[0041] In order to make the purpose, technical solutions and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limiting this application. All other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0042] In the following description, the terms "first\second" are only used to distinguish similar objects and do not represent a specific order for the objects. It can be understood that "first\second" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.

[0043] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this application pertains. The terms used herein are for the purpose of describing the embodiments of this application only and are not intended to limit this application.

[0044] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.

[0045] 1) In response to: used to indicate the conditions or states on which the executed operations depend. When the dependent conditions or states are met, one or more operations executed can be in real time or with a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations executed are executed.

[0046] 2) Client: An application running in a terminal to provide various services, such as a video player client, a game client, etc.

[0047] 3) Virtual scene: also known as a virtual world, a virtual scene displayed (or provided) when an application is running on a terminal. The virtual scene can be a simulation of the real world, a semi-simulation and semi-fictitious virtual environment, or a purely fictitious virtual environment. The virtual scene can be any of a two-dimensional virtual scene, a 2.5-dimensional virtual scene, or a three-dimensional virtual scene. The embodiments of the present application do not limit the dimensions of the virtual scene. For example, the virtual scene may include the sky, land, ocean, etc., and the land may include environmental elements such as deserts and cities. Users can control virtual objects to move in the virtual scene.

[0048] 4) Virtual Objects: These are the images of various people and objects that can interact in a virtual scene, or movable objects within the virtual scene. These movable objects can be virtual people, virtual animals, animated characters, etc., such as people or animals displayed within the virtual scene. A virtual object can be a virtual avatar that represents the user within the virtual scene. A virtual scene can include multiple virtual objects, each with its own unique shape and volume, occupying a portion of the space within the virtual scene.

[0049] 5) Proxy object: A type of object that can inherit some or all of the properties and methods of the source object, and at the same time can add properties and methods that are not in the source object to meet different application needs.

[0050] 6) Entity: A virtual object that exists objectively and can be distinguished from each other in a virtual scene, such as houses, clothes, people, animals, etc.

[0051] 7) Entity Replica: Also known as a distributed entity object, this is a representation of an entity object that exists in different spaces within a virtual world (e.g., the metaverse, a game). For example, Iron Man in the metaverse is an entity object, and Iron Man existing in multiple parallel spaces within the metaverse is an entity replica.

[0052] A physical replica refers to the concept of copying or replicating physical objects in the virtual world. A physical replica is an exact or approximate replica of the original physical object, used for simulation, backup, testing, or other purposes in a virtual environment. Physical replicas are similar or identical to the original physical object to some extent, but they exist independently and do not affect the original physical object's properties or state. In the virtual world, creating physical replicas can help users conduct experiments, simulate operations, communicate with multiple parties, back up data, and improve the flexibility and security of the virtual world. Physical replicas play a vital role in the virtual world, providing users with more ways to handle physical objects and opening up more possibilities for the management, collaboration, and operation of virtual environments.

[0053] 8) Space: refers to a spatial area in a virtual scene (such as the metaverse) application.

[0054] 9) Server Simulated Proxy: A type of replica role. When a replica on a server is a Server Simulated Proxy, its behavior can only be passively synchronized with the behavior of the authoritative replica on another server. A replica in the Server Simulated Proxy role cannot control its own actions.

[0055] 10) Authority: A role type for a replica. When a replica on a server is an authority, it can control its own actions and synchronize its behavior with other replicas.

[0056] 11) Metaverse: Also known as the distributed world, the Metaverse is a digital living space connected and created through technological means, mapping the real world into an interactive virtual world and featuring a new social system. The Metaverse is a new type of internet application and social form that integrates the virtual and the real, resulting from the integration of multiple new technologies. It leverages extended reality technology to provide an immersive experience and digital twin technology to generate a mirror image of the real world. It leverages blockchain technology to build an economic system, closely integrating the virtual and real worlds through social systems, identity systems, and other aspects, while allowing every user to produce and edit content.

[0057] 12) Seamless Big World: A large map with seamless connections. In a narrow sense, a seamless big world refers to a map that is continuous and seamless, without loading, whether it is an endless outdoor scene or a scene that directly enters and exits between the outdoor and indoor scenes. In a broad sense, a seamless big world means that the outdoor scene is seamless, but loading is still required to go from the outdoor scene to the indoor scene. For example, in a game application, in order to create a grand game world for players, which is also a requirement of gameplay, players can explore on a large map. On the game server side, due to the limited map size and user scale supported by a single server, a cluster can be built using multiple game servers. When a user walks from one end of the large map to the other, they need to cross multiple game servers, but the user experience does not perceive any sense of discontinuity when exploring the large map.

[0058] Embodiments of the present application provide a virtual scene data processing method, device, electronic device, computer-readable storage medium, and computer program product, which can improve the effectiveness of physical object migration.

[0059] The virtual scene data processing method provided in the embodiments of the present application can be implemented through entity object migration. Entity object migration at the logical level refers to migrating an entity object from one space to another. Entity object migration at the physical level refers to seamlessly migrating any entity copy on any physical node that has been partitioned by computer resources to another physical node. A physical node refers to an entity object device in a computer network, such as a server, router, switch, or other network device.

[0060] To facilitate easier understanding of the virtual scene data processing method provided in the embodiment of the present application, the application mode of the virtual scene data processing method provided in the embodiment of the present application is first explained. The virtual scene data processing method provided in the embodiment of the present application can be implemented collaboratively by the terminal and the server.

[0061] In one implementation scenario, refer to Figure 1, which is a schematic diagram of the application mode of the virtual scene data processing method provided in an embodiment of the present application, which is applied to the terminal 400 and the server 200-1 and the server 200-2, and the server 200-1 and the server 200-2 communicate with the terminal 400 through the network 300.

[0062] In one example, virtual scene 100 is a game scene. Server 200-1 is the server where the source space in the game application resides, and server 200-2 is the server where the destination space in the game application resides. Players are users of the game application, such as those watching or playing the game. The following describes this process using the above examples.

[0063] The player uses an account (i.e., the current account of the game application) to log in to the game application through the terminal 400. When the entity object 101 in the game application moves from the source space of the virtual scene 100 to the destination space and sets a distance from the regional boundary between the source space and the destination space, a proxy creation event is triggered. On the server 200-1 where the source space is located, the entity object is created by proxy to obtain a first entity copy of the entity object 101. On the server 200-2 where the destination space is located, the entity object is created by proxy to obtain a second entity copy of the entity object 101. The behavior data of the second entity copy is synchronized with the behavior data of the first entity copy, and the first entity copy and the second entity copy correspond to the entity object; when When the entity object 101 in the game application moves to the regional boundary between the source space and the destination space, an authorized migration event is triggered. On the server 200-1 where the source space is located, the first entity copy is authorized to be migrated to obtain the first migrated entity copy. On the server 200-2 where the destination space is located, the second entity copy is authorized to be migrated to obtain the second migrated entity copy. When the entity object 101 in the game application moves to the destination space and is at a set distance from the regional boundary between the source space and the destination space, an agent recovery event is triggered. On the server 200-1 where the source space is located, the agent recovers the first migrated entity copy. On the server 200-2 where the destination space is located, the agent recovers the second migrated entity copy.

[0064] When the game application is loaded, server 200-1 and server 200-2 calculate the scene data required for display through graphics computing hardware (types of graphics processing hardware include central processing unit (CPU) and graphics processing unit (GPU)), and complete the loading, parsing and rendering of display data. The graphics output hardware outputs the rendering data of the virtual scene to terminal 400, and forms a visual perception of the virtual scene in the human-computer interaction interface of terminal 400, for example, presenting two-dimensional video frames on the display screen of a smartphone, or projecting video frames to achieve a three-dimensional display effect on the lenses of augmented reality / virtual reality glasses; in addition, in order to enrich the perception effect, terminal 400 can also use different hardware to form one or more of auditory perception, tactile perception, motion perception and taste perception.

[0065] In another example, virtual scene 100 is a metaverse scene. Server 200-1 is the server where the source space in the metaverse application is located, and server 200-2 is the server where the destination space in the metaverse application is located. The following is an explanation based on the above examples.

[0066] A user using a metaverse application (e.g., a user watching a metaverse video) watches a metaverse video through a terminal 400. When an entity object 101 in a virtual scene 100 presented by the metaverse video enters a portal to a destination space in a source space, a proxy creation event is triggered. On the server 200-1 where the source space is located, a proxy creation is performed on the entity object to obtain a first entity copy of the entity object 101. On the server 200-2 where the destination space is located, a proxy creation is performed on the entity object to obtain a second entity copy of the entity object 101. The behavior data of the second entity copy is synchronized with the behavior data of the first entity copy. The first entity copy is synchronized with the behavior data of the first entity copy. The entity copy and the second entity copy correspond to the entity object; during the transmission of the entity object 101 in the transmission gate, an authorized migration event is triggered, and the first entity copy is authorized to be migrated on the server 200-1 where the source space is located to obtain the first migration entity copy, and the second entity copy is authorized to be migrated on the server 200-2 where the destination space is located to obtain the second migration entity copy; when the entity object 101 has been transmitted to the destination space through the transmission gate, an agent recovery event is triggered, and the agent recovers the first migration entity copy on the server 200-1 where the source space is located, and the agent recovers the second migration entity copy on the server 200-2 where the destination space is located.

[0067] When the Metaverse application is loaded, server 200-1 and server 200-2 calculate the scene data required for display through graphics computing hardware (the types of graphics processing hardware include central processing unit (CPU) and graphics processing unit (GPU)), and complete the loading, parsing and rendering of display data. The graphics output hardware outputs the rendering data of the virtual scene to terminal 400, and forms a visual perception of the virtual scene on the display interface of terminal 400, for example, presenting two-dimensional video frames on the display screen of a smartphone, or projecting video frames to achieve a three-dimensional display effect on the lenses of augmented reality / virtual reality glasses; in addition, in order to enrich the perception effect, terminal 400 can also use different hardware to form one or more of auditory perception, tactile perception, motion perception and taste perception.

[0068] In some embodiments, the terminal 400 can implement the virtual scene data processing method provided in the embodiments of the present application by running a computer program. For example, the computer program can be a native program or software module in the operating system; it can be a native application (APP, APPlication), that is, a program that needs to be installed in the operating system to run, such as a dress-up game APP or a battle game APP; it can also be a small program that can be embedded in any APP, that is, a program that can be run by simply downloading it into a browser environment. In short, the above-mentioned computer program can be any form of application, module or plug-in.

[0069] In some embodiments, the embodiments of the present application can also be implemented with the help of cloud technology. Cloud technology refers to a hosting technology that unifies a series of resources such as hardware, software, and network within a wide area network or local area network to realize data calculation, storage, processing, and sharing.

[0070] For example, the server in Figure 1 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, CDN, and big data and artificial intelligence platforms. Terminal 400 can be various types of user terminals such as laptops, tablet computers, desktop computers, set-top boxes, mobile devices (for example, mobile phones, portable music players, personal digital assistants, dedicated messaging devices, portable gaming devices, and vehicle-mounted devices), smart phones, smart speakers, smart watches, smart TVs, and vehicle-mounted terminals, but is not limited thereto. Terminal 400 and the server can be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiments of the present application.

[0071] In some embodiments, multiple servers may be organized into a blockchain, with the servers being nodes on the blockchain. Information connections may exist between each node in the blockchain, and information may be transmitted between nodes via the aforementioned information connections. Data related to the virtual scene data processing method provided in the embodiments of the present application (e.g., logic for virtual scene data processing) may be stored on the blockchain.

[0072] The structure of the electronic device for virtual scene data processing provided by an embodiment of the present application is described below. Referring to Figure 2, Figure 2 is a structural diagram of an electronic device 500 for virtual scene data processing provided by an embodiment of the present application. The electronic device 500 can be a terminal or a server. The electronic device 500 for virtual scene data processing shown in Figure 2 includes: at least one processor 510, a memory 550, at least one network interface 520 and a user interface 530. The various components in the electronic device 500 are coupled together via a bus system 540. It is understandable that the bus system 540 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 540 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are labeled as bus system 540 in Figure 2.

[0073] The processor 510 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.

[0074] The memory 550 includes a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 550 described in the embodiments of the present application is intended to include any suitable type of memory. The memory 550 may optionally include one or more storage devices physically remote from the processor 510.

[0075] In some embodiments, the memory 550 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplified below.

[0076] Operating system 551, including system programs for processing various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, driver layer, etc., for implementing various basic services and processing hardware-based tasks;

[0077] A network communication module 552 for reaching other electronic devices via one or more (wired or wireless) network interfaces 520 . Exemplary network interfaces 520 include Bluetooth, WiFi, and USB.

[0078] In some embodiments, the virtual scene data processing device provided in the embodiments of the present application can be implemented in software. The virtual scene data processing device provided in the embodiments of the present application can be provided as various software embodiments, including various forms including applications, software, software modules, scripts or codes.

[0079] Figure 2 shows a virtual scene data processing device 555 stored in the memory 550, which can be software in the form of programs and plug-ins, and includes a series of modules, including an acquisition module 5551, an agent creation module 5552, an authorization migration module 5553 and an agent recovery module 5554. These modules are logical, so they can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be explained below.

[0080] As previously mentioned, the virtual scene data processing method provided in the embodiments of the present application can be implemented by various types of electronic devices, such as a terminal, a server, or a combination of the two. Therefore, the execution entities of each step will not be repeated below. Referring to Figure 3A, Figure 3A is a flow chart of the virtual scene data processing method provided in the embodiments of the present application, which will be described in conjunction with the steps shown in Figure 3A.

[0081] Before introducing step 101, the virtual scene data processing method (involving entity object migration) is explained. Under the user's imperceptible experience, the entity object migration at the logical level refers to migrating a physical object from the source space to the destination space, such as transferring a physical object from one space to another space. When a space corresponds to a physical node (a physical object device in a computer network, such as a server, router, switch and other network devices), the physical underlying entity object migration of the embodiment of the present application refers to the seamless migration of any entity copy on any physical node that is divided by computer resources to other physical nodes.

[0082] In the following steps, whenever an entity object appears in the virtual scene, it represents a physical replica of the entity object in at least one space. The virtual scene then creates at least one EntityReplica for this entity object and interprets its behavior based on its spatial location and owner. The attributes of an entity replica include a unique identifier (ID), the local spatial identifier of the entity replica (spatial ID, localspace), the spatial identifier of the owner of the entity replica (ownerspace), the local role (the role of the entity replica in the local space) (localrole), and the owner role (the owner role of the entity replica) (ownerrole). The unique ID and spatial ID of an entity replica are combined to uniquely identify an EntityReplica. That is, the ID of an entity replica includes both the unique ID and the spatial ID. The local spatial identifier of the entity replica is used to identify the space where the entity replica itself resides, and the owner spatial identifier of the entity replica is used to identify the space where the owner of the entity replica resides. Local roles include the authoritative role (which can change its own behavior) and the server remote proxy role (which cannot change its own behavior). Owner roles include the authoritative role.

[0083] In step 101 , a virtual scene is displayed, a physical object is identified from the virtual scene, and a source space and a destination space for migrating the physical object are determined.

[0084] The source space is the starting area for migrating physical objects in the virtual scene, and the destination space is the destination area after the physical objects are migrated in the virtual scene.

[0085] The virtual scene includes physical objects. The embodiments of the present application are not limited to the form of the virtual scene. For example, the virtual scene in the embodiments of the present application can be a combination of virtual and real scenes, or a completely virtual scene. Correspondingly, the embodiments of the present application are not limited to the form of physical objects. For example, the physical object can be a virtual object displayed in a virtual scene, a virtual object obtained by superimposing virtual elements on a physical object in the real world, or a completely virtual virtual object.

[0086] In step 102, a proxy is created for the entity object in the source space to obtain a first entity copy of the entity object.

[0087] For example, after a proxy creation event is triggered, a proxy creation is first performed on the server where the source space is located (referred to as the source space) to obtain the first entity copy of the entity object. The first entity copy is the entity copy local to the source space. Proxy creation in the source space refers to server-local proxy creation in the source space, that is, server-local proxy creation is performed on the entity object in the source space to obtain the first entity copy of the entity object.

[0088] For example, in a gaming application, when an entity object in the game moves from a source space to a destination space in a virtual scene, and moves within a set distance from the boundary between the source and destination spaces, a proxy creation event is triggered. A proxy is created for the entity object on the server where the source space resides, resulting in the first entity copy of the entity object. Proxy creation involves creating a proxy object for the entity object, which then delegates some or all of the entity object's properties or methods.

[0089] Refer to Figure 3B, which is a flow chart of the virtual scene data processing method provided by an embodiment of the present application. The attributes of the first entity copy include a unique identifier, a local space identifier (used to identify the space where the first entity copy itself is located), an owner space identifier (used to identify the space where the owner of the first entity copy is located), and a local role (the role of the first entity copy in the local space); when there is no entity copy corresponding to the entity object in the source space, Figure 3B shows that step 102 in Figure 3A can be implemented through the following steps 1021-step 1022: in step 1021, a first initial entity copy with attributes is generated in the source space; in step 1022, the unique identifier of the first initial entity copy is reset to the identifier of the entity object, the local space identifier is reset to the source space, the owner space identifier is reset to the source space, and the local role is reset to the authoritative role to obtain the first entity copy; wherein, the behavior data of the entity object is synchronized with the behavior data of the entity copy of the authoritative role.

[0090] The first initial entity copy is an initial entity copy corresponding to an entity object (ie, an initialized entity copy), and the attributes of the initial entity copy are empty or set values.

[0091] As an example of step 1022, the source space is space 1. When the attributes of the first entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role, a first entity copy of the authoritative role is generated in space 1. The attribute data of the first entity copy of the authoritative role (localspace 1; ownerspace 1; localroleauthority), that is, the attribute data of the first entity copy of the authoritative role is the data after the attributes of the first entity copy of the authoritative role are assigned. When the attributes of the first entity copy include a unique identifier, a local space identifier, an owner space identifier, a local role, and an owner role, a first entity copy of the authoritative role is generated in space 1. The attribute data of the first entity copy of the authoritative role (localspace 1; ownerspace 1; localroleauthority; ownerroleauthority), that is, the attribute data of the first entity copy of the authoritative role is the data after the attributes of the first entity copy of the authoritative role are assigned.

[0092] In actual application scenarios, during the proxy creation phase, the entity object is still in the source space, and the behavior of the entity object needs to be synchronized with the behavior of the entity copy in the source space. To this end, in order to conform to actual application scenarios, the first entity copy is identified as the authoritative role through attributes such as unique identifier, local space identifier, owner space identifier, and local role. Since the behavior data of the entity object is synchronized with the behavior data of the entity copy of the authoritative role, during the proxy creation phase, the behavior data of the second entity copy can be synchronized with the behavior data of the first entity copy, that is, the behavior of the second entity copy is synchronized with the behavior of the first entity copy, thereby flexibly and quickly controlling the entity object through simple attribute settings.

[0093] In some embodiments, the underlying system maintains entity copies through reference counting, and promotes subsequent processes through the entity copies and the reference counts they carry. The reference count includes the module ID of the running virtual scene and the module's count value for the entity object. Therefore, after step 102, when the source space already has a first entity copy and the reference count value of the module that calls the proxy creation (also known as the proxy creation event) is zero, the reference count value of the module that calls the proxy creation is increased, wherein the reference count represents the progress of the proxy creation, for example, the reference count value of the module that calls the proxy creation is increased from 0 to 1, that is, a reference count is added to the module that calls the proxy creation. When the reference count value of the module that calls the proxy creation is 0, it represents that the proxy creation has not been completed; when the reference count value of the module that calls the proxy creation is 1, it represents that the proxy creation has been completed, and the subsequent processes (such as authorization migration and proxy recycling) can be promoted based on the reference count value of the module that calls the proxy creation.

[0094] The module created by the calling agent can be a scene module (a module for managing virtual scenes and map information), a field of view module (a module for controlling the field of view in a virtual scene), or other modules in the background system for running virtual scenes.

[0095] In step 103 , a proxy is created for the entity object in the destination space to obtain a second entity copy of the entity object, wherein the behavior data of the second entity copy is synchronized with the behavior data of the first entity copy.

[0096] For example, after triggering a proxy creation event, a proxy creation can be performed on the server where the destination space is located (referred to as the destination space) to obtain a second entity copy of the entity object, where the second entity copy is a local entity copy of the destination space. Proxy creation of the destination space refers to server-local proxy creation in the destination space, that is, server-local proxy creation is performed on the entity object in the destination space to obtain a second entity copy. The behavior data of the second entity copy is synchronized with the behavior data of the first entity copy, that is, the behavior of the second entity copy is the same as that of the first entity copy.

[0097] Taking a game application as an example, when an entity object in the game application moves from the source space to the destination space in the virtual scene and sets a distance from the area boundary between the source space and the destination space, a proxy creation event is triggered, and a proxy is created for the entity object on the server where the destination space is located to obtain a second entity copy of the entity object.

[0098] See Figure 3C, which is a flow chart of the virtual scene data processing method provided by an embodiment of the present application. The attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role; when there is no entity copy corresponding to the entity object in the destination space, Figure 3C shows that step 103 in Figure 3A can be implemented through the following steps 1031-step 1032: in step 1031, a second initial entity copy with attributes is generated in the destination space; in step 1032, the unique identifier of the second initial entity copy is reset to the identifier of the entity object, the local space identifier is reset to the destination space, the owner space identifier is reset to the source space, and the local role is reset to the server remote proxy role to obtain the second entity copy; wherein, the behavior data of the entity copy of the server remote proxy role is synchronized with the behavior data of the entity copy of the authoritative role.

[0099] The second initial entity copy is an initial entity copy corresponding to an entity object, and the attributes of the initial entity copy are empty or set values.

[0100] In actual application scenarios, during the proxy creation phase, the entity object is still in the source space, and the behavior of the entity object needs to be synchronized with the behavior of the entity copy in the source space. In this regard, in order to conform to the actual application scenario, the second entity copy is identified as a server remote proxy role through attributes such as unique identifier, local space identifier, owner space identifier, and local role. Since the behavior data of the entity copy of the server remote proxy role is synchronized with the behavior data of the entity copy of the authoritative role. Therefore, during the proxy creation phase, the behavior data of the second entity copy can be synchronized with the behavior data of the first entity copy, that is, the behavior of the second entity copy is synchronized with the behavior of the first entity copy, so that the entity object can be controlled flexibly and quickly through simple property settings.

[0101] As an example of step 1032, the source space is space 1 and the destination space is space 2. When the attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role, a second entity copy of the server remote proxy role is generated in space 2. The attribute data of the second entity copy of the server remote proxy role (localspace 2; ownerspace 1; localrole server remote proxy), that is, the attribute data of the second entity copy of the server remote proxy role is the data after the attributes of the second entity copy of the server remote proxy role are assigned. When the attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, a local role, and an owner role, a second entity copy of the server remote proxy role is generated in space 2. The attribute data of the second entity copy of the server remote proxy role (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authority), that is, the attribute data of the second entity copy of the server remote proxy role is the data after the attributes of the second entity copy of the server remote proxy role are assigned.

[0102] Refer to Figure 3D, which is an optional flow chart of the virtual scene data processing method provided by an embodiment of the present application. Figure 3D shows that after step 102, it also includes steps 106-108. Step 103 can be implemented through step 1031A: in step 106, the entity object is added to the creation proxy queue, and the status of the entity object in the creation proxy queue is set to waiting for creation; in step 107, when the creation proxy queue is polled regularly and it is determined that the number of proxy creations has not reached the creation threshold, and the status of the entity object in the polled creation proxy queue is waiting for creation, the network communication between the source space and the destination space is connected, and the status of the entity object in the polled creation proxy queue is updated to being created, and the number of proxy creations is increased; in step 1031A, the operation of proxy creation of the entity object based on the destination space is performed through network communication; in step 108, when the second entity copy has been created by proxy in the destination space, the status of the entity object in the creation proxy queue is updated to creation completed.

[0103] The proxy creation number is used to indicate the number of times the server remote proxy is created in the destination space.

[0104] The entity object (which can be an entity object identifier) ​​added to the proxy creation queue in step 106 is used to instruct the creation of a corresponding entity copy in the destination space. In other words, if the entity object is added to the proxy creation queue, a corresponding entity copy must be created in the destination space. Step 106 adds the entity object to the proxy creation queue and, by periodically polling the proxy creation queue, smooths out proxy creation events and avoids server overload.

[0105] It should be noted that after the proxy creation event is triggered and the entity copy is created in the source space, the entity object state is set to waiting for creation in step 106 so that the process can be advanced through the entity object state when polling the proxy creation queue later.

[0106] Refer to Figure 3E, which is an optional flow chart of the virtual scene data processing method provided by an embodiment of the present application. Figure 3E shows that before step 104 of Figure 3A, it also includes step 109: in step 109, in the source space, the proxy attributes of the destination space are created for the entity object to obtain the attribute data of the first proxy object; wherein the second entity copy is the first proxy object of the first entity copy, and the attribute data is used to locate the space where the first proxy object of the first entity copy is located.

[0107] As an example of step 109, after the proxy creation event is triggered, the entity object can also be created based on the proxy attributes of the destination space on the server where the source space is located (referred to as the source space) to obtain the attribute data of the first proxy object. The proxy attribute creation based on the destination space refers to the creation of a server local proxy for the attribute data of the proxy object in the source space, that is, the creation of the attribute data of the first proxy object in the source space. The attribute data of the first proxy object is the same as the attribute data of the second entity copy. For example, if the source space is space 1 and the destination space is space 2, when the attribute data of the second entity copy is (localspace 2; ownerspace 1; localrole server remote proxy), the attribute data of the first proxy object (localspace 2; ownerspace1; localrole server remote proxy) is generated in space 1.

[0108] It should be noted that the attribute data of the first proxy object is also the attribute data of the second entity copy, that is, the attribute data of the entity copy of the server remote proxy role. The attribute data of the entity copy of the server remote proxy role will be retained in the source space so that the space of the entity copy of the proxy role of the entity copy of the authoritative role (that is, the server remote proxy role) can be located based on the attribute data of the entity copy of the server remote proxy role.

[0109] In some embodiments, the attribute data includes a unique identifier, a local space identifier, an owner space identifier, and a local role. Step 109 can be implemented by generating initial attribute data in the source space; resetting the unique identifier included in the initial attribute data to the identifier of the entity object, resetting the local space identifier to the destination space, resetting the owner space identifier to the source space, and resetting the local role to the server remote proxy role, thereby obtaining attribute data for the first proxy object. The initial attribute data is either empty or a set value.

[0110] In step 104, authorization migration is performed on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy.

[0111] The first migrated entity replica is the first entity replica after authorized migration, and the second migrated entity replica is the second entity replica after authorized migration. Authorized migration refers to the migration or exchange of behavioral control rights for the first entity replica and the second entity replica. When an entity replica has behavioral control rights, the behavior data of that entity replica is synchronized with the behavior data of other entity replicas, meaning that the behavior of other entity replicas is the same as that of the entity replica.

[0112] Taking a game application as an example, when an entity object in the game application moves to the area boundary between the source space and the destination space, an authorized migration event is triggered. On the server where the source space is located, the first entity copy is authorized to be migrated to obtain the first migrated entity copy. On the server where the destination space is located, the second entity copy is authorized to be migrated to obtain the second migrated entity copy.

[0113] See Figure 3F, which is an optional flow chart of the virtual scene data processing method provided by an embodiment of the present application. The attributes of the first entity copy and the attributes of the second entity copy both include the owner space identifier and the local role; Figure 3F shows that step 104 of Figure 3A can be implemented through steps 1041-1042: in step 1041, the owner space identifier of the first entity copy is modified to the destination space, and the local role is modified to the server remote agent role to obtain the first migration entity copy; in step 1042, the owner space identifier of the second entity copy is modified to the destination space, and the local role is modified to the authoritative role to obtain the second migration entity copy.

[0114] As an example of step 1041, the relevant attributes of the entity copy whose local space identifier is the source space (i.e., the first entity copy) are modified: the entity object owner space identifier is modified to the destination space ID, and the local role is modified to the server remote proxy role. For example, the source space is space 1, and the destination space is space 2. The source space in the proxy creation phase retains two entity copy data, namely, the entity copy data of the authoritative role (attribute data: (localspace 1; ownerspace 1; localrole authoritative; ownerrole authoritative)) and the entity copy data of the server remote proxy role (attribute data: (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authoritative)). After migration, the relevant attributes of the entity copy whose local space identifier is the source space are modified to obtain the entity copy of (localspace 1; ownerspace 2; localrole server remote proxy; ownerrole authoritative).

[0115] As an example of step 1042, the relevant attributes of the entity copy with the local space identifier as the destination space (i.e., the second entity copy) are modified: the entity object owner space identifier is modified to the destination space ID, and the local role is modified to the authoritative role. For example, the source space is space 1, the destination space is space 2, and the destination space in the proxy creation phase generates entity copy data for the server remote proxy role, the entity copy of the server remote proxy role (attribute data: (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authoritative)). After migration, the relevant attributes of the entity copy with the local space identifier as the destination space are modified to obtain an entity copy of (localspace 2; ownerspace 2; localrole authoritative role; ownerrole authoritative).

[0116] In some embodiments, before step 104, when the entity object meets the queue processing conditions, the entity object is added to the migration queue; when the migration queue is polled regularly and it is determined that the number of migrations has not reached the migration threshold, and the latest destination space of the entity object is the same as the destination space, step 104 will be executed; wherein, the queue processing conditions include that the entity object is an entity object that is not controlled by the client, and the entity object has not been processed by the migration queue. The entity object added to the migration queue (which can be an entity object identifier) ​​is used to indicate the authorization to migrate the first entity copy and the second entity copy. The entity object is added to the migration queue, and the migration queue is polled regularly to smooth the authorization migration event and avoid the problem of server pressure surge. By redirecting the destination space (that is, judging whether the latest destination space of the entity object is the same as the destination space), the accuracy of the destination space is guaranteed, thereby improving the accuracy of the entity object migration. The number of migrations is used to indicate the number of authorized migrations in the destination space.

[0117] It should be noted that physical objects in a virtual scene can be of various types, including client-controlled physical objects (i.e., physical objects in the virtual scene that the user can independently control, such as the hero the user currently controls) and non-client-controlled physical objects (i.e., physical objects in the virtual scene that the user cannot independently control, such as non-player characters (NPCs)). Client-controlled physical objects are a subset of physical objects, and the authorization migration method for client-controlled physical objects is based on the authorization migration capability of the physical objects.

[0118] Refer to Figure 3G, which is an optional flow chart of the virtual scene data processing method provided by an embodiment of the present application. Figure 3G shows that before step 105 of Figure 3A, it also includes step 110: in step 110, in the destination space, the proxy attributes of the source space are created for the second migration entity copy to obtain the attribute data of the second proxy object; wherein the first migration entity copy is the second proxy object of the second migration entity copy, and the attribute data is used to locate the space where the second proxy object of the second migration entity copy is located.

[0119] It should be noted that the second proxy object of the second migration entity copy created in the destination space can quickly locate the space of the entity copy of the proxy role (i.e., the server remote proxy role) of the entity copy of the authoritative role (i.e., the first migration entity copy) based on the attribute data of the second proxy object of the second migration entity copy, so as to find the space where the entity copy of the server remote proxy role is located.

[0120] As an example of step 110, after triggering the authorized migration event, the proxy attributes of the second migration entity copy can also be created based on the source space on the server where the destination space is located (referred to as the destination space) to obtain the attribute data of the second proxy object. The proxy attribute creation based on the source space refers to the creation of a server local proxy for the attribute data of the proxy object in the destination space, that is, the creation of the attribute data of the second proxy object in the destination space. The attribute data of the second proxy object is the same as the attribute data of the first migration entity copy. For example, the source space is space 1 and the destination space is space 2. When the attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role, and the attribute data of the second entity copy is (localspace 1; ownerspace 2; localrole server remote proxy), the attribute data of the second proxy object (localspace 1; ownerspace 2; localrole server remote proxy) is generated in space 2.

[0121] In some embodiments, the attribute data includes a unique identifier, a local space identifier, an owner space identifier, and a local role. Step 110 can be implemented by generating initial attribute data in the destination space; resetting the unique identifier included in the initial attribute data to the entity object's identifier, resetting the local space identifier to the source space, resetting the owner space identifier to the destination space, and resetting the local role to the server remote proxy role, thereby obtaining attribute data for the second proxy object. The initial attribute data is either empty or a set value.

[0122] In some embodiments, when the entity object is an entity object operated by a client, before step 104, a network connection is created between the gateway and the server where the destination space is located through the gateway; after step 104, a start migration message is sent to the client that controls the entity through the gateway, the start migration message carries the connection relationship of the network connection, and the start migration message is used to instruct the client to switch the proxy authorization connection to the network connection; the switch message sent by the client is received through the gateway, and the switch message indicates that the client has switched the proxy authorization connection to the network connection; the authorization migration success message is sent to the server where the destination space is located through the gateway, and the authorization migration success message is used to indicate the server where the destination space is located, and bind the entity object controlled by the client to the network connection to connect the network communication between the client, the gateway, and the server where the destination space is located. Therefore, by introducing the gateway, the switching operation of the entity object controlled by the client in different spaces is hidden behind, so that the user is unaware of the authorization migration.

[0123] In step 105, proxy recycling is performed on the first migrating entity replica and the second migrating entity replica.

[0124] In the computer field, proxy recycling is the recycling and release of proxy entity copies. This usually occurs when the entity copy is no longer needed in order to free up resources or reduce memory consumption.

[0125] For example, after a proxy recycle event is triggered, the proxy recycles the first and second migration entity copies to restore them to their initial state. For example, in a gaming application, when an entity object in the gaming application moves to a destination space and is within a set distance from the boundary between the source and destination spaces, a proxy recycle event is triggered. On the server where the source space is located, the proxy recycles the first migration entity copy, and on the server where the destination space is located, the proxy recycles the second migration entity copy.

[0126] Referring to FIG3H , FIG3H is an optional flow chart of a virtual scene data processing method provided by an embodiment of the present application. FIG3H shows that before step 105, steps 111-113 are also included: in step 111, when the source space already has a first migration entity copy and the reference count value of the module calling the proxy recycling is non-zero, the reference count value of the module calling the proxy recycling (proxy recycling event) is reduced; in step 112, when the reference count value of the module calling the proxy recycling is reduced to zero, the state of the entity object is set to waiting for recycling, and the entity object is added to the proxy recycling queue; in step 113, when the proxy recycling queue is regularly polled and it is determined that the number of proxy recycling does not reach the recycling threshold, and the state of the polled entity object is waiting for recycling, the network communication between the source space and the destination space is disconnected, the state of the polled entity object is set to recycling, and the proxy recycling number is increased. Wherein, the proxy recycling number is used to indicate the number of times the proxy recycling is performed.

[0127] The entity object (which can be an entity object identifier) ​​added to the proxy reclaim queue in step 112 is used to instruct the proxy to reclaim the entity replica. That is, if the entity object is added to the proxy reclaim queue, the created entity replica must be reclaimed in both the target space and the source space. Adding the entity object to the proxy reclaim queue in step 112 smooths out proxy reclaim events by periodically polling the proxy reclaim queue, thus avoiding server pressure surges.

[0128] It should be noted that when the proxy recycling event is triggered, the entity object state is reset to waiting for recycling in step 106, so that when the proxy recycling queue is polled later, the process is advanced through the entity object state.

[0129] In some embodiments, the underlying system maintains entity copies through reference counting, and advances subsequent processes through the entity copies and the reference counts they carry. The reference count includes the module ID and the module's count value for the entity object. Therefore, after step 102, when the source space already has a first migration entity copy and the reference count value of the module recycled by the calling agent is non-zero, the reference count value of the module recycled by the calling agent will be reduced, for example, the reference count value of the module recycled by the calling agent will be reduced from 1 to 0, that is, the reference count of the module recycled by the calling agent will be deducted.

[0130] The following describes an exemplary application of the embodiments of the present application in a practical application scenario.

[0131] The embodiments of the present application can be applied to related applications such as metaverse applications and open world games, for example, projects and product applications including virtual worlds, large-scale virtual simulation systems, virtual games, etc., and can provide high-quality and stable entity object data migration functions for related applications, improve the computing parallelism and carrying capacity of the server system, and enhance the user experience of the client.

[0132] As shown in the virtual world 401 of the metaverse in Figure 4, the embodiment of the present application can determine the unique identifier of the physical objects (virtual objects) such as characters, figures 402, buildings, etc. in the virtual world 401 in the metaverse, and distribute the physical object data so that the virtual world is not limited by the bottleneck problem brought by the computing resources of a single computer. Through the unlimited expansion capacity of computer resources, the space for describing the virtual world can be expanded, and then the expanded virtual world space can carry a large number of physical copies and interact in the virtual world.

[0133] At the same time, in the application scenario of the virtual world of this metaverse, the embodiment of the present application can migrate a physical object from the source space to the destination space without the user's feeling, for example, a physical object is transferred from one space to another space. When a space corresponds to a physical node (a physical object device in a computer network, such as a server, router, switch and other network devices), the physical underlying physical object migration of the embodiment of the present application refers to the seamless migration of any physical copy of any physical node that is divided by the computer resources to other physical nodes. At the same time, fault detection is performed on hardware failures, network fluctuations and other problems that may occur during the migration process to restore the operating state, fully improving the timeliness and robustness of large-scale distributed systems such as the virtual world of the metaverse.

[0134] In related technologies, in seamless world-based gaming applications, entity object migration is achieved by sending the full data of the real character (Real) to the server where the ghost character (Ghost) resides, and then switching between the Real and Ghost characters on the server. However, this solution of migrating entity objects by bundling the full data is prone to various errors and cannot guarantee the effectiveness of entity object migration.

[0135] In order to solve the above problems, the embodiment of the present application provides a virtual scene data processing method, so that it can support the control requirements of entity copies from the technical bottom layer; the entity object migration is divided into multiple stages, which smoothes the entire migration process; when problems occur in the migration process, compared with the related technologies that cannot locate the problems in a timely and accurate manner, the embodiment of the present application can locate the problems in a timely manner to achieve high timeliness of migration. When problems occur in the migration process, the embodiment of the present application can correct the problems in a timely manner by rolling back or advancing nodes to achieve the effectiveness of migration; distributed entity object data (i.e., entity copies) are recorded at the bottom layer of the system, and then when problems occur at various stages of entity object migration, the system operation status can be effectively judged through the entity object data to avoid chaos.

[0136] Before describing the virtual scene data processing method provided by the application embodiment, the modeling scheme of the physical copy is first introduced.

[0137] For a distributed, seamless, and large-scale metaverse application, space and time appear continuous and sustainable to players. However, due to the bottleneck of computing resources on a single computer, a distributed, seamless, and large-scale metaverse solution is introduced. The ultimate goal is to describe space through the unlimited expansion capabilities of computer resources and to describe time through the unlimited expansion capabilities of storage resources.

[0138] At the same time, due to the bottleneck of stand-alone games, in order to describe the continuity of space, servers are introduced to manage the boundaries of space and the overlapping areas under the jurisdiction of the servers. The purpose is to achieve spatial continuity and seamless player experience.

[0139] To achieve the above objectives, the present embodiment describes the existence and control rights of entity copies in multiple spaces in the Metaverse application to model entity copies. The modeling description and constraints are as follows:

[0140] 1. The same entity object can have entity copies in multiple spaces, and each space has one and only one entity copy corresponding to the entity object;

[0141] 2. The physical copy has the ability to be operated by its owner;

[0142] 3. There is a special entity copy in the metaverse, which has the ability to operate the behaviors of other entity copies in multiple spaces.

[0143] The entity replica described above represents a mapping set of an entity object in the metaverse. Whenever an entity object appears in the metaverse, it has at least one entity replica in one space. The metaverse then creates at least one EntityReplica for this entity object and interprets its behavior based on its spatial location and owner. Table 1 lists the properties of entity replicas.

[0144] Table 1 Entity copy modeling table

[0145] The entity object migration process of the embodiment of the present application is described below with reference to the state machine.

[0146] In metaverse applications, to provide users with a better experience and prevent them from experiencing the data migration process within the metaverse, a technical solution with relatively high timeliness and effectiveness is required to achieve entity object migration. This embodiment of the present application addresses this need by dividing the overall entity object migration into three phases (i.e., the proxy creation phase, the authorization migration phase, and the proxy recovery phase), and by organizing the corresponding status table during the entity object migration process. The entity object migration status table is shown in Table 2.

[0147] Table 2 Entity object migration status table

[0148] As shown in the table above, the embodiment of the present application systematically divides the entity object migration process into three stages (agent creation, authorization migration, and agent recovery). Each stage corresponds to a start and end state, so that each stage can run independently. When a problem occurs in the system, the status of the entity object migration can be located in time to determine whether to roll back or advance, thereby greatly improving the technical reliability of the entity object data migration process.

[0149] It should be noted that, in the embodiment of the present application, the status of each stage can be defined by entity replicas. The following example illustrates how to locate the status of entity object migration to determine whether to roll back or advance.

[0150] The initial state contains no data, and any problems in any space in the system are not related to the entity object migration itself. After the proxy is created, the source and destination spaces have the data of the entity copy.

[0151] Regarding rollback, there are the following situations: when the source space has an abnormal downtime problem, the role will be offline (lost), that is, the entity copy of the source space will be lost, and the entity copy of the destination space will also be offline. After the source space is restored (that is, the server where the source space is located is restarted), the entity copies of the source space and the destination space are cleared, and the entity object is rolled back to the initial state; when the destination space has an abnormal downtime problem, the entity copy of the destination space is offline (lost), and the source space is notified to delete the entity copy of the corresponding destination space, thereby rolling back to the state before the entity object initiated proxy creation for the destination space (that is, the initial state); during the authorization migration process, when the role switching of the source space is completed and the destination space has an abnormal downtime problem during authorization migration, the local role of the entity copy of the source space is the server remote proxy role. When the set timeout time is reached or the destination space is notified of a problem, it will roll back to the state before the entity copy of the source space was migrated, that is, the state of the entity before the authorization migration.

[0152] Regarding advancement, there are the following situations: in the initial state, the entity copy is empty, and it can be advanced to the proxy creation state; after the proxy creation state is completed, the source space, the source space and the destination space have the data of the entity copy, and it can be advanced to the authorized migration state; after the authorized migration state is completed, the source space, the source space and the destination space have the data of the entity copy, and it can be advanced to the proxy recovery state; after the proxy recovery state is completed, the data of the entity copy of the source space and the destination space are recovered, and it returns to the initial state.

[0153] As shown in Figure 5, under normal circumstances, entity object migration cycles through states 1->2->3->4, with strong dependencies between state nodes. However, in special cases, as shown in Figure 5, the proxy creation state can jump directly to the proxy recovery state. For example, during the roaming phase (without a task), a user can return from the proxy creation state to the initial state via the proxy recovery node. After performing a role switch through the authorized migration node, if another role switch is performed, the authorized migration node must be converted again, meaning that the authorized migration node performs a state change within the node.

[0154] It should be noted that the three stages shown in Figure 5 (agent creation, authorization migration, and agent recycling) can all be triggered by modules in the virtual scene. For example, when a user-controlled entity object roams in a metaverse application, the trigger of the scene module (a module used to manage virtual scenes and map information) combined with the entity copy can trigger events corresponding to any stage of entity object migration. For example, the metaverse has two spatial regions (such as the source space and the destination space), and there is a region boundary between the two spatial regions. Trigger 1 is set at the set distance from the region boundary in the source space, trigger 2 is set at the region boundary, and trigger 3 is set at the set distance from the region boundary in the destination space. In the process of the entity object roaming from the source space to the destination space in the metaverse application, it first reaches the set distance from the region boundary in the source space (indicating that it is about to reach the destination space), triggering trigger 1, which triggers the proxy creation event to create an entity copy of the server remote proxy role in the destination space, and then when the entity object roams to the region boundary, trigger 2 is triggered, which triggers the entity object migration event to switch the role of the entity copy in the destination space and the source space, and finally the entity object roams to the set distance from the region boundary in the destination space (indicating that it is far away from the source space), triggering trigger 3, which triggers the proxy recycling event to recycle the entity copies of the destination space and the source space.

[0155] The following describes the three stages of proxy creation, authorization migration, and proxy recycling shown in FIG5 .

[0156] 1) Proxy creation in entity object migration

[0157] See Figure 6, which is a flow chart of the agent creation event provided in an embodiment of the present application. The steps shown in Figure 6 are explained below. The agent creation event can support the initiation of multiple modules of the metaverse, such as the field of view module (a module for controlling the field of view in the virtual scene) and the scene module.

[0158] Step 201 : Determine whether the entity copy corresponding to the entity object already exists. If the entity copy corresponding to the entity object does not exist, execute step 202 ; if the entity copy corresponding to the entity object already exists, execute step 205 .

[0159] Step 202: Create an entity copy in the source space.

[0160] It should be noted that when an entity object is always in the source space, it has no connection with other spaces and no entity copy will be generated in the source space. Therefore, when the proxy creation event is triggered, an entity copy needs to be created in the source space.

[0161] For example, obtain the unique ID, source space ID, and destination space ID of the entity copy, create an entity copy of the authoritative role in the source space, the ID of the entity copy of the authoritative role is (unique ID of the entity copy + source space ID), the local space identifier is the source space ID, the owner space identifier is the source space ID, the local role is the authoritative role, and the owner role is the authoritative role.

[0162] In some embodiments, the attribute data of the entity copy of the server remote proxy role is retained in the source space so that the space of the entity copy of the proxy role (i.e., the server remote proxy role) of the entity copy of the authoritative role can be located based on the attribute data of the entity copy of the server remote proxy role.

[0163] For example, the source space is space 1 and the destination space is space 2. The source space can retain the attribute data of two entity copies, namely, the attribute data of the entity copy of the authoritative role (localspace 1; ownerspace 1; localrole authoritative; ownerrole authoritative) and the attribute data of the entity copy of the server remote proxy role (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authoritative).

[0164] Step 203: Add a reference count to the module that calls the proxy creation event.

[0165] It should be noted that the underlying system maintains entity copies through reference counting and uses the entity copies and the reference counts they carry to advance subsequent processes. The reference count includes the module ID and the module's count value for the entity object, as shown in Table 3.

[0166] Table 3 Reference count

[0167] For example, after creating an entity copy in the source space, a reference count is added to the module that calls the proxy creation event, and the count value of the reference count is reset to 1.

[0168] Step 204: Add the entity object to the creation agent queue.

[0169] It should be noted that after creating an entity copy in the source space and adding a reference count to the module that calls the proxy creation event, the entity object is added to the creation proxy queue. Subsequently, it is necessary to periodically poll the creation proxy queue to pop out the pending proxy objects in the creation proxy queue (that is, the entity objects in the creation proxy queue are used to indicate the creation of an entity copy in the destination space). By periodically polling the creation proxy queue, the proxy creation event is smoothed out to avoid the problem of a surge in server pressure.

[0170] It should be noted that after the proxy creation event is triggered and the entity copy is created in the source space, the entity object state is set to waiting for creation, and then the entity object is added to the creation proxy queue so that the process can be advanced through the entity object state when the creation proxy queue is polled later.

[0171] See Figure 7, which is a schematic diagram of the polling process for creating a proxy queue provided in an embodiment of the present application, and is explained in conjunction with the steps shown in Figure 7.

[0172] In step 11, determine whether the number of proxy creations in the current frame of the virtual scene reaches the creation threshold. When the number of proxy creations in the current frame does not reach the creation threshold, execute step 12; when the number of proxy creations in the current frame reaches the creation threshold, end the process.

[0173] The frame is used to indicate a time period, such as 15 milliseconds currently. The proxy creation number is used to indicate the number of times a server remote proxy is created in the destination space.

[0174] In step 12, a proxy queue is created and the element to be created is popped out.

[0175] Among them, each time polling occurs, when the number of proxy creations in the current frame does not reach the creation threshold, the elements to be created (i.e., the identifiers of the entity objects in the creation proxy queue, used to indicate the creation of entity copies in the destination space) will be popped out from the creation proxy queue one by one.

[0176] In step 13, it is determined whether the entity object state is waiting for creation. If the entity object state is waiting for creation, step 14 is executed; if the entity object state is not waiting for creation, the process ends.

[0177] In step 14, it is determined whether the entity object pointer is null. When the entity object pointer is not null, step 15 is executed; when the entity object pointer is null, the process ends.

[0178] The entity object pointer points to the entity copy of the entity object. When the entity object pointer is empty, it indicates that the entity copy does not exist in the destination space.

[0179] It should be noted that whether to perform proxy creation on the entity copy (ie, create an entity copy of the server remote proxy role in the destination space) is determined through the state, entity object pointer, etc.

[0180] In step 15, the connection dependency for entity object synchronization is set.

[0181] Setting the connection dependency of the entity object synchronization refers to letting the synchronization module allow the entity object to perform network communication from the source space to the destination space.

[0182] In step 16, the entity object state is set to creating.

[0183] In step 17, the number of proxy creations for the current frame is increased.

[0184] Among them, after increasing the number of proxy creations in the current frame, proxy creation is initiated through the module for data synchronization (data communication). When data synchronization begins, the entity object status is updated to remote creation. When the entity copy of the destination space is created, it is considered that the proxy creation event of the module that calls the proxy creation event is completed, and the entity object status is set to creation completed. An entity copy of the server remote proxy role is generated in the destination space. The ID of the entity copy of the server remote proxy role is (unique ID of the entity copy + destination space ID), the local space identifier is the destination space ID, the owner space identifier is the source space ID, the local role is the server remote proxy role, and the owner role is the authoritative role.

[0185] Step 205 , determine whether the reference count of the module that calls the proxy creation event meets the conditions. If the conditions are met, execute step 206 ; if the conditions are not met, exit the process.

[0186] For example, when the reference count value of the module that calls the proxy creation event is 0, it means that the reference count of the module that calls the proxy creation event meets the condition.

[0187] Step 206: Add a reference count to the module that calls the proxy creation event.

[0188] Step 207: Broadcast Agent creates a success event.

[0189] Wherein, if the agent creation success event is broadcast, it is considered that the agent creation event of the module that calls the agent creation event is completed.

[0190] In summary, after completing the proxy creation event, the source space retains the entity copy data of the authoritative role and the server remote proxy role, that is, the ID of the entity copy data of the authoritative role is (entity object unique ID + source space ID), the entity object local space identifier is the source space ID, the entity object owner space identifier is the source space ID, the local role is the authoritative role, and the owner role is the authoritative role; the ID of the entity copy data of the server remote proxy role is (entity object unique ID + destination space ID), the entity object local space identifier is the destination space ID, the entity object owner space identifier is the source space ID, the local role is the server remote proxy role, and the owner role is the authoritative role. The destination space retains the entity copy data of the server remote proxy role, and its ID is (entity object unique ID + destination space ID), the entity object local space identifier is the destination space ID, the entity object owner space identifier is the source space ID, the local role is the server remote proxy role, and the owner role is the authoritative role.

[0191] 2) Authorization migration in entity object migration

[0192] It should be noted that entity objects in metaverse applications can be of various types, including client-controlled entity objects (e.g., heroes currently controlled by the user) and non-client-controlled entity objects (e.g., non-player characters (NPCs)). Client-controlled entity objects are a subset of entity objects, and the authorization migration method for client-controlled entity objects is based on the authorization migration capability of entity objects.

[0193] Refer to Figure 8, which is a schematic flow chart of the authorization migration event provided in an embodiment of the present application. The steps shown in Figure 8 are explained below.

[0194] Step 301: Determine whether the entity copy and reference count corresponding to the entity object meet the conditions. If both conditions are met, execute step 302; if not, end the process.

[0195] It should be noted that when an authorized migration event is triggered, if the entity replica corresponding to the entity object to be authorized for migration is an authoritative role and an entity replica exists in the destination space, then the entity replica corresponding to the entity object meets the conditions. If the reference count value of the scene module that triggered the authorized migration event is 1, then the reference count condition is met.

[0196] Step 302 : Determine whether the entity object requires queue processing. If queue processing is required, execute step 303 ; if queue processing is not required, execute step 304 .

[0197] It should be noted that client-controlled entity objects already have a queue method due to the connection creation preparation phase. Therefore, if the entity object is client-controlled, no queue processing is required. If the entity object has been ejected from the migration queue, then the entity object also does not require queue processing. If the entity object is not client-controlled and has not been queued, then the entity object does require queue processing.

[0198] Step 303: Add the entity object to the migration queue.

[0199] When an entity object requires queue processing, the entity object (ie, entity object information, such as an identifier of the entity object) is directly added to the migration queue so that the migration queue can be polled subsequently.

[0200] Refer to Figure 9, which is a schematic diagram of the polling process of the migration queue provided in an embodiment of the present application, and is explained in conjunction with the steps shown in Figure 9.

[0201] In step 21, it is determined whether the number of transitions in the current frame reaches a transition threshold. If it does not reach the transition threshold, step 22 is executed; if it reaches the transition threshold, the process ends.

[0202] The frame is used to indicate a time period, such as 15 milliseconds currently, and the migration number is used to indicate the number of authorized migrations in the destination space.

[0203] In step 22, the migration queue pops out the elements to be migrated.

[0204] During each polling, when the migration number of the current frame does not reach the migration threshold, the elements to be migrated (i.e., the identifiers of the entity objects in the migration queue, used to indicate the authorized migration entity copies) will be popped out from the migration queue in sequence.

[0205] In step 23, the physical object is redirected to the destination space.

[0206] Redirecting the destination space indicates rechecking the destination space. For example, the latest destination space ID of the entity object queried by the scene module is obtained. If the latest destination space ID is zero, migration is not required and the destination space needs to be redirected, and the redirected destination space needs to be reset to the source space ID. If the latest destination space ID is the same as the source space ID of the entity object, migration is not required and the destination space needs to be redirected, and the redirected destination space needs to be reset to the source space ID. If the latest destination space ID is different from the destination space ID set before enqueuing, the destination space needs to be redirected and reset to the latest destination space ID.

[0207] In step 24, the entity object is migrated.

[0208] It is worth noting that the role switch occurs in the migration process. At this time, the local role of the entity copy identified as the source space is changed from the authoritative role to the server remote proxy role, and the entity copy of the source space temporarily loses its ability to act.

[0209] The migration process is as follows: modify the relevant attributes of the entity copy whose local space identifier is the source space: modify the entity object owner space identifier to the destination space ID, and modify the local role to the server remote proxy role; modify the relevant attributes of the entity copy whose local space identifier is the destination space: modify the entity object owner space identifier to the destination space ID, and modify the local role to the authoritative role. Delete the entity copy whose local space identifier is the destination space in the source space. Generate the entity copy data of the server remote proxy role in the destination space, whose ID is (entity object unique ID + source space ID), the entity object local space identifier is the source space ID, the entity object owner space identifier is the destination space ID, the local role is the server remote proxy role, and the owner role is the authoritative role.

[0210] For example, the source space is space 1 and the destination space is space 2. The source space in the proxy creation phase retains two entity copy data, namely, the entity copy data of the authoritative role (attribute data: (localspace 1; ownerspace 1; localrole authority; ownerrole authority)) and the entity copy data of the server remote proxy role (attribute data: (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authority)); the entity copy data of the server remote proxy role is generated in the destination space, the entity copy of the server remote proxy role (attribute data: (localspace 2; ownerspace 1; localrole server remote proxy; ownerrole authority)).

[0211] After the migration process, the entity copy with the local space identifier as the source space modifies its attributes, resulting in a copy with the local space identifier as (localspace 1; ownerspace 2; localrole server remote proxy; ownerrole authority). The entity copy with the local space identifier as the destination space modifies its attributes, resulting in a copy with the local space identifier as (localspace 2; ownerspace 2; localrole authority role; ownerrole authority). The entity copy with the local space identifier as the destination space is deleted from the source space.

[0212] Step 304: Redirect the entity object to the destination space.

[0213] Redirecting the destination space indicates rechecking the destination space. For example, the latest destination space ID of the entity object queried by the scene module is obtained. If the latest destination space ID is zero, migration is not required and the destination space needs to be redirected, and the redirected destination space needs to be reset to the source space ID. If the latest destination space ID is the same as the source space ID of the entity object, migration is not required and the destination space needs to be redirected, and the redirected destination space needs to be reset to the source space ID. If the latest destination space ID is different from the destination space ID set before enqueuing, the destination space needs to be redirected and reset to the latest destination space ID.

[0214] Step 305: Migrate the entity object.

[0215] Among them, role switching occurs in the migration processing step. At this time, the local role of the entity copy identified as the source space is changed from the authoritative role to the server remote agent role, and the entity copy of the source space temporarily loses its ability to act.

[0216] In summary, after the authorization migration event is completed, the source space only retains the entity copy data of the server remote proxy role, whose ID is (entity object unique ID + source space ID), the entity object local space identifier is the source space ID, the entity object owner space identifier is the destination space ID, the local role is the server remote proxy role, and the owner role is the authoritative role. The destination space contains entity copy data of the authoritative role and the server remote proxy role, that is, the ID of the entity copy data of the authoritative role is (entity object unique ID + destination space ID), the entity object local space identifier is the destination space ID, the entity object owner space identifier is the destination space ID, the local role is the authoritative role, and the owner role is the authoritative role; the ID of the entity copy data of the server remote proxy role is (entity object unique ID + source space ID), the entity object local space identifier is the source space ID, the entity object owner space identifier is the destination space ID, the local role is the server remote proxy role, and the owner role is the authoritative role.

[0217] In some embodiments, when the entity object requiring authorization migration is a client-controlled entity object, a gateway is introduced to smooth the overall entity object migration process and obscure the user experience. This gateway hides the switching of client-controlled entity objects between different spaces. By hiding the connection switching process, the lag caused by network data transmission when switching entity objects is avoided, and the user experience issues caused by network anomalies are reduced, significantly shortening the time required for authorization migration of client-controlled entity objects.

[0218] Referring to Figure 10, Figure 10 is a timing diagram of the authorization migration of an entity object provided by a client manipulation of an embodiment of the present application, and the steps shown in Figure 10 are described.

[0219] Step 401: The server where the source space is located triggers an authorization migration event.

[0220] Step 402: When the server where the source space is located determines that the entity object is a client-operated entity object, it enters the authorization migration preparation stage.

[0221] Step 403: The server where the source space is located sends a connection creation request to the gateway.

[0222] The connection creation request carries the destination space ID.

[0223] Step 404: The gateway establishes a connection with the server where the destination space is located.

[0224] Step 405: The server where the destination space is located returns a connection creation completion message to the gateway.

[0225] The connection creation completion message is used to indicate that a connection has been established between the gateway and the server where the destination space is located.

[0226] Step 406: The gateway returns a connection creation completion message to the server where the source space is located.

[0227] Step 407: The server where the source space is located starts the entity authorization migration process.

[0228] The server where the source space is located can package data such as the entity object's unique ID, the entity object's attribute data set, and the entity object's private data set.

[0229] Step 408: The server where the source space is located sends a migration message.

[0230] The migration message is used to instruct the server where the destination space is located to authorize the migration.

[0231] Step 409: The server where the destination space is located performs authorized migration.

[0232] Step 410: The server where the destination space is located sends a migration status completion message.

[0233] The migration status completion message is used to indicate that the server where the destination space is located has completed the authorized migration.

[0234] Step 411: The server where the source space is located sends a migration start message to the gateway.

[0235] The start migration message carries the destination space ID, which is used to instruct the gateway to connect the network communication between the control terminal, the gateway, and the destination space.

[0236] Step 412: The gateway records the space information of the authorized migration switch and sends a migration start message to the client.

[0237] The space information of the authorized migration switching is the destination space ID and the corresponding connection relationship to which the entity object is authorized to migrate.

[0238] Step 413: The client locally switches the proxy authorization connection.

[0239] For example, the client switches the proxy authorization connection to the network connection that is communicated with the destination space and is notified by the gateway.

[0240] Step 414: The gateway sends a message indicating that the client has successfully authorized the migration to the server where the destination space is located.

[0241] The client authorization migration success message is used to indicate that the client authorization migration is successful.

[0242] Step 415: The server where the destination space is located resets the binding relationship.

[0243] For example, on the server where the destination space is located, the connection relationship between the entity object controlled by the client and the destination space and gateway is reset and bound, so as to open up the network communication between the control end, gateway, and destination space to continue to control the entity in the destination space.

[0244] 3) Proxy Recycling in Entity Object Migration

[0245] See Figure 11, which is a flow chart of the agent recycling method provided in an embodiment of the present application, and is explained in conjunction with the steps shown in Figure 11. The agent recycling event can support the initiation of multiple modules of the metaverse, such as the field of view module (a module for controlling the field of view in the virtual scene) and the scene module.

[0246] Step 501: Determine whether the entity copy corresponding to the entity object already exists. If the entity copy corresponding to the entity object already exists, execute step 502; if the entity copy corresponding to the entity object does not exist, end the process.

[0247] Step 502: Determine whether the reference count meets the conditions. If the conditions are met, execute step 503; if the conditions are not met, end the process.

[0248] It should be noted that, after the proxy recycling event is triggered, when the reference count value corresponding to the module that triggered the proxy recycling event is 1, it means that the reference count meets the conditions.

[0249] Step 503: deduct the reference count.

[0250] It should be noted that the underlying system maintains entity copies through reference counting and uses the entity copies and the reference counts they carry to advance subsequent processes. When a proxy reclaim event is triggered, the entity copies need to be reclaimed, and of course the reference counts need to be deducted.

[0251] Step 504 , determine whether the reference count value is zero. When the reference count value is zero, execute step 505 ; when the reference count value is not zero, execute step 507 .

[0252] It should be noted that when the reference count value is zero, it means that the remote entity copy needs to be actually recovered.

[0253] Step 505: Set the entity object state of the entity copy to waiting for recycling.

[0254] Step 506: Add the entity object to the proxy recycling queue.

[0255] It should be noted that after the entity object is added to the proxy recycling queue, it waits for the proxy recycling queue to be polled and processed.

[0256] Refer to Figure 12, which is a schematic diagram of the polling process of the proxy recycling queue provided in an embodiment of the present application, and is explained in conjunction with the steps shown in Figure 12.

[0257] In step 31, it is determined whether the number of proxy recycling in the current frame reaches the recycling threshold. When the number of proxy recycling in the current frame does not reach the recycling threshold, step 32 is executed; when the number of proxy recycling in the current frame reaches the creation threshold, the process ends.

[0258] The frame is used to indicate a time period, such as 15 milliseconds currently. The proxy recycling number is used to indicate the number of times the proxy is recycled.

[0259] In step 32, the proxy recycling queue pops the element to be recycled.

[0260] Among them, each time polling occurs, when the number of proxy recycling in the current frame does not reach the recycling threshold, the elements to be recycled (i.e., the identifiers of the entity objects in the proxy recycling queue, used to indicate the recycling of entity copies) will be popped out from the proxy recycling queue in sequence.

[0261] In step 33, it is determined whether the entity object state is waiting for recycling. When the entity object state is not waiting for recycling, step 24 is executed; when the entity object state is waiting for recycling, the process ends.

[0262] In step 34, it is determined whether the entity object pointer is null. When the entity object pointer is not null, step 35 is executed; when the entity object pointer is null, the process ends.

[0263] Among them, the entity object pointer points to the entity copy of the entity object. When the entity object pointer is empty, it means that the entity copy does not exist in the source space.

[0264] It should be noted that whether to perform proxy recycling on the entity copy is determined through the state, entity object pointer, etc.

[0265] In step 35, the connection dependency of the entity object synchronization is removed.

[0266] Here, removing the connection dependency of the entity object synchronization means that the synchronization module does not allow the entity object to perform network communication from the source space to the destination space.

[0267] In step 36, the entity object state is set to being recycled.

[0268] In step 37, the proxy recycling number of the current frame is increased.

[0269] In step 38, the physical copy is recycled.

[0270] For example, the synchronization module initiates a proxy recycling operation to delete the entity copy data in the source space and the destination space, that is, to delete the entity copy data of the server remote proxy role, whose ID is (entity object unique ID + source space ID), the entity object local space identifier is the source space ID, the entity object owner space identifier is the destination space ID, the local role is the server remote proxy role, and the owner role is the authoritative role; delete the entity copy data of the authoritative role, whose ID is (entity object unique ID + destination space ID), the entity object local space identifier is the destination space ID, the entity object owner space identifier is the destination space ID, the local role is the authoritative role, and the owner role is the authoritative role.

[0271] Step 507: Broadcast the recovery success event.

[0272] Among them, if the broadcast recovery success event is broadcast, it is considered that the proxy recovery event of the module that calls the proxy recovery event is completed and returns to the initial state.

[0273] In summary, the virtual scene data processing method provided in the embodiment of the present application supports the control requirements of entity copies; divides the entity object migration into three stages, smoothes the overall migration process, improves the fault tolerance of entity object data migration, and reduces the risk of entity object migration failure; provides complete entity copy data at the bottom layer of the system, and for various abnormal problems that arise in the entity object migration, data judgment can be performed to locate and correct the problems and avoid chaotic behavior.

[0274] So far, the virtual scene data processing method provided by the embodiment of the present application has been described in combination with the exemplary application and implementation of the electronic device provided by the embodiment of the present application. The following will continue to describe the cooperation of various modules in the virtual scene data processing device 555 provided by the embodiment of the present application to implement the entity object migration solution.

[0275] An acquisition module 5551 is configured to display a virtual scene containing an entity object; identify the entity object from the virtual scene, and determine a source space and a destination space for migrating the entity object; a proxy creation module 5552 is configured to perform proxy creation on the entity object in the source space to obtain a first entity copy of the entity object; perform proxy creation on the entity object in the destination space to obtain a second entity copy of the entity object, wherein the behavior data of the second entity copy is synchronized with the behavior data of the first entity copy; an authorization migration module 5553 is configured to perform authorized migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy; a proxy recovery module 5554 is configured to perform proxy recovery on the first migrated entity copy and the second migrated entity copy.

[0276] In some embodiments, the attributes of the first entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role; the proxy creation module 5552 is also configured to generate a first initial entity copy with the attributes in the source space; reset the unique identifier of the first initial entity copy to the identifier of the entity object, reset the local space identifier to the source space, reset the owner space identifier to the source space, and reset the local role to the authoritative role to obtain the first entity copy; wherein the behavior data of the entity object is synchronized with the behavior data of the entity copy of the authoritative role.

[0277] In some embodiments, before the authorized migration of the first entity copy and the second entity copy, the proxy creation module 5552 is also configured to increase the reference count value of the module called by the proxy creation when the first entity copy already exists in the source space and the reference count value of the module called by the proxy creation is zero, wherein the reference count is used to represent the progress of the proxy creation.

[0278] In some embodiments, the attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role; the proxy creation module 5552 is also configured to generate a second initial entity copy with the attributes in the destination space; reset the unique identifier of the second initial entity copy to the identifier of the entity object, reset the local space identifier to the destination space, reset the owner space identifier to the source space, and reset the local role to the server remote proxy role to obtain the second entity copy.

[0279] In some embodiments, the proxy creation module 5552 is also configured to add the entity object to a creation proxy queue, and set the status of the entity object in the creation proxy queue to waiting for creation; when the creation proxy queue is polled regularly and it is determined that the number of proxy creations has not reached the creation threshold, and the status of the entity object in the polled creation proxy queue is waiting for creation, the network communication between the source space and the destination space is connected, and the status of the entity object in the polled creation proxy queue is updated to creating, wherein the network communication is used to perform a proxy creation operation on the entity object based on the destination space, and increase the number of proxy creations; when the second entity copy has been created by proxy in the destination space, the status of the entity object in the creation proxy queue is updated to creation completed.

[0280] In some embodiments, before the authorized migration of the first entity copy and the second entity copy is performed to obtain the first migrated entity copy and the second migrated entity copy, the proxy creation module 5552 is also configured to create proxy attributes of the destination space for the entity object in the source space to obtain attribute data of the first proxy object; wherein the second entity copy is the first proxy object of the first entity copy, and the attribute data is used to locate the space where the first proxy object of the first entity copy is located.

[0281] In some embodiments, the attribute data includes a unique identifier, a local space identifier, an owner space identifier, and a local role; the proxy creation module 5552 is also configured to generate initial attribute data in the source space; reset the unique identifier included in the initial attribute data to the identifier of the entity object, reset the local space identifier to the destination space, reset the owner space identifier to the source space, and reset the local role to the server remote proxy role to obtain the attribute data of the first proxy object.

[0282] In some embodiments, the attributes of the first entity copy and the attributes of the second entity copy both include an owner space identifier and a local role; the authorized migration module 5553 is also configured to modify the owner space identifier of the first entity copy to the destination space, and modify the local role to the server remote agent role to obtain the first migrated entity copy; modify the owner space identifier of the second entity copy to the destination space, and modify the local role to the authoritative role to obtain the second migrated entity copy.

[0283] In some embodiments, before the authorized migration of the first entity copy and the second entity copy is performed to obtain the first migrated entity copy and the second migrated entity copy, the authorized migration module 5553 is also configured to add the entity object to the migration queue when the entity object meets the queue processing conditions, wherein the queue processing conditions include that the entity object is an entity object not controlled by the client and has not been processed by the migration queue; when the migration queue is polled regularly to determine that the number of migrations has not reached the migration threshold and the latest destination space of the entity object is the same as the destination space, the first entity copy and the second entity copy are authorized to be migrated to obtain the first migrated entity copy and the second migrated entity copy.

[0284] In some embodiments, before performing proxy recycling processing on the migrated first entity copy and the migrated second entity copy, the authorization migration module 5553 is further configured to create proxy attributes of the source space for the second migrated entity copy in the destination space to obtain attribute data of the second proxy object;

[0285] The first migrating entity copy is a second proxy object of the second migrating entity copy, and the attribute data is used to locate a space where the second proxy object of the second migrating entity copy is located.

[0286] In some embodiments, when the entity object is an entity object operated by a client, the authorization migration is performed on the first entity copy and the second entity copy, and before obtaining the first migration entity copy and the second migration entity copy, the authorization migration module 5553 is also configured to create a network connection between the gateway and the server where the destination space is located through the gateway; after the authorization migration is performed on the first entity copy and the second entity copy, the method further includes: sending a start migration message to the client that controls the entity object through the gateway, the start migration message carries the connection relationship of the network connection, and the start migration message is used to instruct the client to switch the proxy authorization connection to the network connection; receiving the switching message sent by the client through the gateway, the switching message indicates that the client has switched the proxy authorization connection to the network connection; sending an authorization migration success message to the server where the destination space is located through the gateway, the authorization migration success message is used to indicate the server where the destination space is located, binding the entity object controlled by the client to the network connection to connect the network communication between the client, the gateway, and the server where the destination space is located.

[0287] In some embodiments, before performing proxy recycling processing on the first entity copy after migration and the second entity copy after migration, the proxy recycling module 5554 is also configured to reduce the reference count value of the module calling proxy recycling when the first migration entity copy already exists in the source space and the reference count value of the module running the virtual scene is non-zero; when the reference count value of the module is reduced to zero, the state of the entity object is set to waiting for recycling, and the entity object is added to the proxy recycling queue; when the proxy recycling queue is regularly polled and it is determined that the number of proxy recyclings does not reach the recycling threshold, and the state of the polled entity object is waiting for recycling, the network communication between the source space and the destination space is disconnected, and the state of the polled entity object is set to being recycled; after setting the state of the polled entity object to being recycled, the proxy recycling number is increased, and proxy recycling operations are performed on the first migration entity copy and the second migration entity copy.

[0288] An embodiment of the present application provides a computer program product, which includes a computer program or computer-executable instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer program or computer-executable instructions from the computer-readable storage medium and executes the computer program or computer-executable instructions, causing the electronic device to perform the virtual scene data processing method described in the embodiment of the present application.

[0289] An embodiment of the present application provides a computer-readable storage medium storing computer-executable instructions, which stores computer-executable instructions or computer programs. When the computer-executable instructions or computer programs are executed by a processor, the processor will execute the virtual scene data processing method provided by an embodiment of the present application, for example, the virtual scene data processing method shown in Figure 3A.

[0290] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface storage, optical disk, or CD-ROM; or various devices including one or any combination of the above memories.

[0291] In some embodiments, computer-executable instructions may be in the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

[0292] As an example, computer-executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinating files (e.g., files storing one or more modules, subroutines, or code portions).

[0293] By way of example, computer-executable instructions may be deployed to be executed on one electronic device, or on multiple electronic devices located at one site, or on multiple electronic devices distributed across multiple sites and interconnected by a communication network.

[0294] It is understandable that in the embodiments of the present application, when user information and other related data are involved, when the embodiments of the present application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0295] The above description is merely an embodiment of the present application and is not intended to limit the scope of protection of the present application. Any modifications, equivalent replacements, and improvements made within the spirit and scope of the present application are included in the scope of protection of the present application.

Claims

1. A virtual scene data processing method, applied to an electronic device, the method comprising: Displaying a virtual scene, wherein the virtual scene includes a physical object; identifying the physical object from the virtual scene and determining a source space and a destination space for migrating the physical object; Performing proxy creation on the entity object in the source space to obtain a first entity copy of the entity object; Performing proxy creation on the entity object in the destination space to obtain a second entity copy of the entity object, wherein the behavior data of the second entity copy is synchronized with the behavior data of the first entity copy; Performing authorized migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy; Perform proxy recycling on the first migration entity copy and the second migration entity copy.

2. The method according to claim 1, wherein: The attributes of the first entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role; The step of creating the entity object by proxy in the source space to obtain a first entity copy of the entity object includes: generating a first initial entity copy having the attributes in the source space; Reset the unique identifier of the first initial entity copy to the identifier of the entity object, reset the local space identifier to the source space, reset the owner space identifier to the source space, and reset the local role to the authoritative role, so as to obtain the first entity copy; The behavior data of the entity object is synchronized with the behavior data of the entity copy of the authoritative role.

3. The method according to claim 1 or 2, wherein: Before creating the entity object by proxy in the source space to obtain the first entity copy of the entity object, the method further includes: When the first entity copy already exists in the source space and the count value of the reference count of the module created by the calling agent is zero, the count value of the reference count of the module created by the calling agent is increased, wherein the reference count is used to characterize the progress of the agent creation.

4. The method according to claim 1, wherein: The attributes of the second entity copy include a unique identifier, a local space identifier, an owner space identifier, and a local role; The step of creating the entity object by proxy in the destination space to obtain a second entity copy of the entity object includes: generating a second initial entity copy having the attributes in the destination space; The unique identifier of the second initial entity copy is reset to the identifier of the entity object, the local space identifier is reset to the destination space, the owner space identifier is reset to the source space, and the local role is reset to the server remote proxy role to obtain the second entity copy.

5. The method according to claim 1 or 4, wherein: After the entity object is created by proxy in the source space to obtain a first entity copy of the entity object, the method further includes: Adding the entity object to a creation proxy queue, and setting the state of the entity object in the creation proxy queue to wait for creation; When it is determined that the number of proxy creations has not reached the creation threshold when the creation proxy queue is periodically polled, and the state of the entity objects in the creation proxy queue polled is waiting for creation, the network communication between the source space and the destination space is connected, and the state of the entity objects in the creation proxy queue polled is updated to being created, wherein the network communication is used to perform an operation of performing proxy creation on the entity objects based on the destination space, and increase the number of proxy creations; When the second entity copy has been created by proxy in the destination space, the status of the entity object in the creation proxy queue is updated to creation completion.

6. The method according to claim 1, wherein: Before performing authorized migration on the first entity copy and the second entity copy to obtain the first migrated entity copy and the second migrated entity copy, the method further includes: In the source space, creating proxy attributes of the destination space for the entity object to obtain attribute data of the first proxy object; The second entity copy is the first proxy object of the first entity copy, and the attribute data is used to locate the space where the first proxy object of the first entity copy is located.

7. The method according to claim 6, wherein: The attribute data includes a unique identifier, a local space identifier, an owner space identifier, and a local role; The creating of the proxy attributes of the destination space for the entity object in the source space to obtain the attribute data of the first proxy object includes: generating initial attribute data in the source space; The unique identifier included in the initial attribute data is reset to the identifier of the entity object, the local space identifier is reset to the destination space, the owner space identifier is reset to the source space, and the local role is reset to the server remote proxy role to obtain the attribute data of the first proxy object.

8. The method according to claim 1, wherein: The attributes of the first entity copy and the attributes of the second entity copy both include an owner space identifier and a local role; The step of performing authorized migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy includes: Modifying the owner space identifier of the first entity copy to the destination space, and modifying the local role to the server remote agent role, so as to obtain the first migration entity copy; The owner space identifier of the second entity copy is modified to the destination space, and the local role is modified to the authoritative role, so as to obtain the second migrated entity copy.

9. The method according to claim 1 or 8, wherein: Before performing authorized migration on the first entity copy and the second entity copy to obtain the first migrated entity copy and the second migrated entity copy, the method further includes: When the entity object meets the queue processing condition, adding the entity object to the migration queue, wherein the queue processing condition includes that the entity object is an entity object not controlled by the client and the entity object has not been processed by the migration queue; The step of performing authorized migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy includes: When it is determined during periodic polling of the migration queue that the number of migrations has not reached the migration threshold and the latest destination space of the entity object is the same as the destination space, the first entity copy and the second entity copy are authorized to migrate to obtain a first migrated entity copy and a second migrated entity copy.

10. The method according to claim 1 or 8, wherein: Before performing proxy recycling on the first migration entity replica and the second migration entity replica, the method further includes: In the destination space, creating the proxy attributes of the source space for the second migration entity copy to obtain attribute data of the second proxy object; The first migrating entity copy is a second proxy object of the second migrating entity copy, and the attribute data is used to locate a space where the second proxy object of the second migrating entity copy is located.

11. The method according to claim 1 or 8, wherein: When the entity object is an entity object operated by a client, before performing authorized migration on the first entity copy and the second entity copy to obtain the first migrated entity copy and the second migrated entity copy, the method further includes: Creating a network connection between the gateway and the server where the destination space is located through the gateway; After the first entity copy and the second entity copy are authorized for migration to obtain the first migration entity copy and the second migration entity copy, the method further includes: Sending a start migration message to a client controlling the entity object through the gateway, the start migration message carrying the connection relationship of the network connection, the start migration message being used to instruct the client to switch the proxy authorization connection to the network connection; receiving, through the gateway, a switching message sent by the client, wherein the switching message indicates that the client has switched the proxy authorization connection to the network connection; An authorization migration success message is sent to the server where the destination space is located through the gateway, and the authorization migration success message is used to indicate the server where the destination space is located, and bind the entity object controlled by the client to the network connection to connect the network communication between the client, the gateway, and the server where the destination space is located.

12. The method according to claim 1, wherein: Before performing proxy recycling on the first migration entity replica and the second migration entity replica, the method further includes: When the first migration entity copy already exists in the source space and the count value of the reference count of the module running the virtual scene is non-zero, the count value of the reference count of the module recycled by the calling agent is reduced; When the count value of the reference count of the module is reduced to zero, the state of the entity object is set to wait for recycling, and the entity object is added to the proxy recycling queue; When it is determined that the number of proxy recycling does not reach the recycling threshold when the proxy recycling queue is polled regularly, and the state of the polled entity object is waiting for recycling, disconnecting the network communication between the source space and the destination space, and setting the state of the polled entity object to recycling; After setting the state of the polled entity object to being recycled, the proxy recycling number is increased, and a proxy recycling operation is performed on the first migration entity replica and the second migration entity replica.

13. A virtual scene data processing device, the device comprising: An acquisition module configured to display a virtual scene, wherein the virtual scene includes a physical object; identifying the physical object from the virtual scene and determining a source space and a destination space for migrating the physical object; A proxy creation module, configured to perform proxy creation on the entity object in the source space to obtain a first entity copy of the entity object; Performing proxy creation on the entity object in the destination space to obtain a second entity copy of the entity object, wherein the behavior data of the second entity copy is synchronized with the behavior data of the first entity copy; An authorization migration module, configured to perform authorization migration on the first entity copy and the second entity copy to obtain a first migrated entity copy and a second migrated entity copy; The proxy recycling module is configured to perform proxy recycling on the first migration entity replica and the second migration entity replica.

14. An electronic device, comprising: Memory for storing computer programs or computer executable instructions; The processor is used to implement the virtual scene data processing method described in any one of claims 1 to 12 when executing the computer program or computer executable instructions stored in the memory.

15. A computer-readable storage medium storing a computer program or a computer-executable instruction, wherein the computer program or the computer-executable instruction, when executed by a processor, implements the virtual scene data processing method according to any one of claims 1 to 12.

16. A computer program product, comprising a computer program or a computer executable instruction, wherein the computer program or the computer executable instruction, when executed by a processor, implements the virtual scene data processing method according to any one of claims 1 to 12.

Citation Information

Patent Citations

  • Seamless Live Migration of Virtual Machines across Optical Networks

    US20070180436A1

  • Method, Apparatus, and System for Migrating Virtual Network Function Instance

    US20170238171A1

  • Travel of virtual characters

    US20220305385A1

  • Game instance display method and apparatus, and storage medium

    WO2022062146A1

  • Game copy display method and device, computer program and medium

    WO2022062147A1