Method, device and equipment for processing service in virtual scene, and storage medium

CN116920425BActive Publication Date: 2026-08-18TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210355746.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-06
Publication Date
2026-08-18
Estimated Expiration
2042-04-06

AI Technical Summary

Technical Problem

[0003]然而,相关技术中,往往是通过在游戏原有业务流程中增加或修改分支逻辑实现模拟真实玩家的行为的功能,对原有业务侵入性强,且不便于扩展

Benefits of technology

[0042]应用本申请实施例,在接收到针对目标服务的创建请求,且检测到玩家角色的数量小于创建目标服务所需的角色数量时,生成角色创建请求并发送至角色服务所属的第二服务器,并根据角色服务返回的非玩家角色的资源数据,完成针对目标服务的创建操作。如此,通过独立的角色服务生成非玩家角色的资源数据,能够提高数据生成效率。基于角色服务和目标服务之间的低耦合性,能够提高角色服务的可扩展性和灵活性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116920425B_ABST
    Figure CN116920425B_ABST
Patent Text Reader

Abstract

The application provides a processing method, device and equipment of a service in a virtual scene and a computer readable storage medium. The method comprises the following steps: in response to a creation request for a target service in a virtual scene sent by a player role, determining the number of player roles corresponding to the target service; when the number of player roles is less than the number of roles required to create the target service, generating a role creation request for creating a non-player role corresponding to the target service; sending the role creation request to a second server to which a role service belongs, and receiving resource data of the non-player role returned by the second server based on the role service; and controlling the non-player role to exist in a virtual scene corresponding to the player role to create the target service. Through the application, the flexibility and scalability of the role service can be enhanced based on the low coupling between the role service and the target service.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, device, computer-readable storage medium, and computer program product for processing services in a virtual scene. Background Technology

[0002] With the development of internet technology, the number of users in the gaming industry is increasing daily, and the variety of games is also growing. Among them, massively multiplayer online games (MMOGs) are a popular genre. The gameplay of MMOs primarily involves multiple players controlling their virtual characters to perform specific activities within a virtual environment. Because these games require multiple players to participate, matchmaking is essential; a certain number of players must be matched before the game can begin. When the number of real players is insufficient, the server typically generates virtual players to play alongside real players, ensuring that real players can complete matchmaking quickly.

[0003] However, in related technologies, the function of simulating the behavior of real players is often achieved by adding or modifying branch logic in the original business process of the game. This is highly intrusive to the original business and not easy to expand. Summary of the Invention

[0004] This application provides a method, apparatus, electronic device, computer-readable storage medium, and computer program product for processing services in a virtual scene, which can enhance the flexibility and scalability of role services based on the low coupling between role services and target services.

[0005] The technical solution of this application embodiment is implemented as follows:

[0006] This application provides a method for processing services in a virtual scene, applied to a first server, including:

[0007] In response to a creation request sent by a player character for a target service in a virtual scene, determine the number of player characters corresponding to the target service;

[0008] When the number of player characters is less than the number of characters required to create the target service, a character creation request is generated. The character creation request is used to create a non-player character corresponding to the target service.

[0009] The character creation request is sent to the second server to which the character service belongs, and the resource data of the non-player character returned by the second server based on the character service is received.

[0010] Based on the resource data of the non-player character, the non-player character is controlled to exist in the virtual scene corresponding to the player character in order to create the target service.

[0011] This application provides a service processing apparatus in a virtual scene, including:

[0012] The receiving module is used to respond to a creation request sent by a player character for a target service in a virtual scene and determine the number of player characters corresponding to the target service;

[0013] The generation module is used to generate a character creation request when the number of player characters is less than the number of characters required to create the target service. The character creation request is used to create a non-player character corresponding to the target service.

[0014] The sending module is used to send the character creation request to the second server to which the character service belongs, and to receive the resource data of the non-player character returned by the second server based on the character service;

[0015] The control module is used to control the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character, so as to create the target service.

[0016] In the above scheme, when the number of player characters is less than the number of characters required to create the target service, the generation module is further used to obtain the type of non-player character corresponding to the target service; and generate the character creation request carrying the type of the non-player character to request the creation of a non-player character of the type.

[0017] In the above scheme, when the number of player characters is less than the number of characters required to create the target service, the generation module is further used to determine the level of the player characters; and when the level of the player characters does not reach the level threshold and the number of player characters is less than the number of characters required to create the target service, a character creation request is generated.

[0018] In the above scheme, the generation module is further configured to generate an invitation prompt message and return the invitation prompt message when the player character's level reaches the level threshold; wherein, the invitation prompt message is used to prompt the player character to invite other player characters to meet the number of characters required to create the target service.

[0019] In the above scheme, when the number of player characters is less than the number of characters required to create the target service, the generation module is also used to obtain the type of the player character; and generate a character creation request for creating a non-player character that matches the type of player character.

[0020] In the above scheme, the processing device for services in the virtual scene further includes a team-up module, which is used to receive a team-up request from the player character for the non-player character and send the team-up request to the character service;

[0021] The team-up request is used to request the non-player character to join the group to which the player character belongs;

[0022] Receive the response result returned by the character service based on the team request, and return the response result to the player character.

[0023] In the above scheme, the team-up module is also used to obtain the number of characters in the group when the team-up prompt information indicates that the non-player character agrees to join the group;

[0024] When the number of roles reaches the number of roles required to create the target service, a prompt message is generated to indicate that the target service has been created successfully.

[0025] Return the generated prompt message.

[0026] In the above scheme, the control module is also used to obtain the termination condition of the target service;

[0027] Based on the termination conditions of the target service, when the target service ends, the non-player character is controlled to exit the virtual scene corresponding to the player character.

[0028] In the above scheme, the control module is also used to detect the player character's interaction behavior with the non-player character, and to obtain the interaction data corresponding to the interaction behavior;

[0029] The interaction data is sent to the character service, and the response data of the non-player character is received from the character service based on the interaction data.

[0030] Based on the response data, the non-player character is controlled to perform the corresponding interactive response.

[0031] This application embodiment also provides a service processing apparatus in a virtual scene, including:

[0032] The request receiving module is used to receive character creation requests for creating non-player characters corresponding to the target service.

[0033] The character creation request is generated by the first server to which the target service belongs, in response to a creation request sent by a player character for the target service in a virtual scene, when the number of player characters corresponding to the target service is less than the number of characters required to create the target service;

[0034] The data generation module is used to generate resource data for the non-player character based on the character creation request.

[0035] The data sending module is used to send the resource data of the non-player character to the first server, so that the first server controls the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character, so as to create the target service.

[0036] This application provides an electronic device, including:

[0037] Memory, used to store executable instructions;

[0038] The processor, when executing executable instructions stored in the memory, implements the service processing method in the virtual scene provided in the embodiments of this application.

[0039] This application provides a computer-readable storage medium storing executable instructions for inducing a processor to execute and implement a service processing method in a virtual scene provided in this application.

[0040] This application provides a computer program product, including a computer program or instructions, for inducing a processor to execute and implement the service processing method in the virtual scene provided in this application.

[0041] The embodiments of this application have the following beneficial effects:

[0042] Applying the embodiments of this application, when a creation request for a target service is received, and it is detected that the number of player characters is less than the number of characters required to create the target service, a character creation request is generated and sent to the second server to which the character service belongs. Based on the resource data of non-player characters returned by the character service, the creation operation for the target service is completed. Thus, by generating non-player character resource data through an independent character service, data generation efficiency can be improved. Based on the low coupling between the character service and the target service, the scalability and flexibility of the character service can be improved. Attached Figure Description

[0043] Figure 1 This is a schematic diagram of the architecture of the service processing system 100 in the virtual scene provided in this application embodiment;

[0044] Figure 2A-2B This is a schematic diagram of the structure of an electronic device that implements a service processing method in a virtual scene according to an embodiment of this application;

[0045] Figure 3 This is a flowchart illustrating the service processing method in a virtual scene provided in the embodiments of this application;

[0046] Figure 4 This is a schematic diagram of the process for controlling player character team formation provided in an embodiment of this application;

[0047] Figures 5A-5C This is a visual illustration of a non-player character provided in an embodiment of this application;

[0048] Figure 6 This is a schematic diagram of successful team formation provided in an embodiment of this application;

[0049] Figure 7 This is a schematic diagram of non-player character interaction provided in an embodiment of this application;

[0050] Figure 8 This is a flowchart illustrating the service processing method in a virtual scene provided in the embodiments of this application;

[0051] Figures 9A-9B This is a flowchart of the copy creation method provided by the relevant technology;

[0052] Figure 10 This is a schematic diagram illustrating the service processing method in a virtual scene provided in the embodiments of this application;

[0053] Figure 11 This is an overall view of the robot service provided in the embodiments of this application;

[0054] Figure 12 This is a schematic diagram of the robot service processing flow provided in the embodiments of this application;

[0055] Figure 13 This is a schematic diagram of the architecture of the external robot service provided in the embodiments of this application;

[0056] Figure 14 This is a schematic diagram of the robot display interface provided in an embodiment of this application;

[0057] Figure 15 This is a schematic diagram of the service interaction process in a game copy provided in this application embodiment. Detailed Implementation

[0058] To make the objectives, 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 limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0059] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0060] If the application documents contain similar descriptions such as "first / second", the following explanation shall be added: In the following description, the terms "first / second / third" are used only to distinguish similar objects and do not represent a specific order of objects. It is understood that "first / second / third" may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0061] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0062] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.

[0063] 1) Virtual Scene: A virtual scene is a scene displayed (or provided) by an application when it runs on a terminal. This virtual scene can be a simulation of the real world, a semi-simulated / semi-fictional environment, or a purely fictional environment. The virtual activity scene can be any of the following: two-dimensional, 2.5-dimensional, or three-dimensional; this application does not limit it.

[0064] 2) Virtual objects: These are interactive objects in a virtual environment, such as virtual characters or animals. Virtual objects can be controlled by the user or the server.

[0065] 3) Massive Multiplayer Online Games (MMOGs): These are games where the server can support a large number of players online simultaneously. The game provides users with a virtual world where they can create virtual characters and control them to perform various activities and complete tasks. Multiple users can team up to complete the same task or engage in battles against other teams.

[0066] 4) Robot service: A service that can simulate player input or respond to server notifications on behalf of players.

[0067] 5) Remote Procedure Call Protocol (RPC): RPC is a protocol that allows a program on a remote computer to request services over a network without needing to understand the underlying network technology. RPC assumes the existence of certain transport protocols, such as TCP or UDP, to carry information between communicating programs. In the OSI network communication model, RPC spans the transport and application layers. RPC makes it easier to develop applications, including network-distributed multi-program applications. RPC uses a client / server model. The requesting program is the client, and the service provider is the server.

[0068] 6) GM is an abbreviation for GAME MASTER, meaning game administrator. A GM can be considered a supervisor or virtual police officer for the game. GAME MASTER is usually abbreviated as GM, meaning game administrator, and refers to an online game manager hired by the company to ensure game quality, allow players to enjoy and immerse themselves in the online game; to thoroughly understand all aspects of the game and provide better service to players. The role of a GM is: problem solver, virtual world police, and someone who serves the players.

[0069] The applicant discovered that for massively multiplayer online games (MMORPGs), a certain number of players are often required for the game to begin. When the number of real players is insufficient, virtual players are typically generated on the server to play alongside real players, ensuring that real players can complete matchmaking and start the game as quickly as possible.

[0070] However, related technologies often simulate the behavior of real players by adding or modifying branch logic in the original business process of the game. This is highly intrusive to the existing business and not easy to expand.

[0071] Based on this, embodiments of this application provide a method, apparatus, device, computer-readable storage medium, and computer program product for processing services in a virtual scene. The virtual scene server, in response to a creation request for a target service sent by a player character, determines the number of player characters corresponding to the target service. When the number of player characters is less than the number of characters required to create the target service, a character creation request is generated to create a non-player character corresponding to the target service. The character creation request is sent to a character service, and based on the resource data of the non-player character returned by the character service, the non-player character is controlled to exist in the virtual scene corresponding to the player character, thereby creating the target service. Thus, due to the low coupling between the character service and the target service, the flexibility and scalability of the character service can be improved.

[0072] Based on the above explanation of the nouns and terms used in the embodiments of this application, the service processing system in the virtual scene provided in the embodiments of this application is described below. See also Figure 1 , Figure 1 This is a schematic diagram of the architecture of a service processing system 100 in a virtual scene provided in this application embodiment. To support the processing application of services in a virtual scene, terminals (terminals 400-1 and 400-2 are shown as examples) are connected to a first server 200 and a second server 210 through a network 300. The network 300 can be a wide area network (WAN), a local area network (LAN), or a combination of both. The first server 200 and the second server 210 can belong to a target server cluster, which includes at least one of a single server, multiple servers, a cloud computing platform, and a virtualization center. The server cluster can be used to provide background services for applications supporting a 3D virtual environment.

[0073] The terminal has a client installed and running that supports virtual reality or multiplayer online role-playing games. It is used to present a virtual scene interface including a launch entry for the target service, and in response to the trigger operation of the launch entry, to present a virtual scene interface in which player characters and non-player characters cooperate to perform interactive tasks corresponding to the target service.

[0074] The first server 200 is used to respond to a creation request sent by a player character for a target service in a virtual scene, determine the number of player characters corresponding to the target service; when the number of player characters is less than the number of characters required to create the target service, generate a character creation request for creating a non-player character corresponding to the target service; send the character creation request to the second server 210 to which the character service belongs, and receive the resource data of the non-player character returned by the second server 210 based on the character service, and based on the resource data of the non-player character returned by the character service, control the non-player character to exist in the virtual scene corresponding to the player character, so as to create the target service.

[0075] The second server 210 is used to receive a character creation request for creating a non-player character corresponding to the target service; wherein, the character creation request is generated by the first server to which the target service belongs in response to a creation request for the target service in the virtual scene sent by a player character, when the number of player characters corresponding to the target service is less than the number of characters required to create the target service; based on the character creation request, resource data of the non-player character is generated; and the resource data of the non-player character is sent to the first server 200, so that the first server 200 controls the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character, so as to create the target service.

[0076] In practical applications, the first server 200 and the second server 210 can be independent physical servers, or a server cluster or distributed system composed of multiple physical servers. Furthermore, the first server and the second server can be different servers, or integrated into the same target server. They can also be cloud servers providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. The terminals (such as terminals 400-1 and 400-2) can be smartphones, tablets, laptops, desktop computers, smart speakers, smart TVs, smartwatches, etc., but are not limited to these. The terminals (such as terminals 400-1 and 400-2), the first server 200, and the second server 210 can be directly or indirectly connected via wired or wireless communication, which is not limited herein.

[0077] In practical applications, the terminals (including terminals 400-1 and 400-2) have applications that support virtual scenes installed and running. These applications can be any of the following: first-person shooter (FPS) games, third-person shooter games, driving games with steering as the primary action, multiplayer online battle arena (MOBA) games, two-dimensional (2D) games, three-dimensional (3D) games, virtual reality applications, 3D mapping programs, or multiplayer survival games. The application can also be a standalone application, such as a standalone 3D game program.

[0078] Taking a video game scenario as an example, a user can perform operations on the terminal in advance. After detecting the user's operation, the terminal can download the video game's configuration file. This configuration file can include the video game's application, interface display data, or virtual scene data, so that when the user logs into the video game on the terminal, the configuration file can be invoked to render and display the video game interface. The user can also perform touch operations on the terminal. After detecting the touch operation, the terminal can determine the corresponding game data and render and display that game data. This game data can include virtual scene data and behavioral data of virtual objects within the virtual scene.

[0079] In practical applications, the terminals (including terminals 400-1 and 400-2) receive a trigger operation to enter the virtual scene based on the view interface, and send a request to the first server 200 to obtain the scene data of the virtual scene. The first server 200 receives the request and, in response, returns the scene data of the virtual scene to the terminal. The terminal receives the scene data of the virtual scene, renders the screen of the virtual scene based on the scene data, and displays the corresponding virtual scene interface. The player sends a creation request for the target service to the first server through the trigger operation of the entry point to start the target service presented in the virtual scene interface. The first server receives the creation request for the target service in the virtual scene and determines the number of player characters corresponding to the target service. When the number of player characters is less than the number of characters required to create the target service, a character creation request is generated to create the non-player characters corresponding to the target service. The character creation request is sent to the second server to which the character service belongs, and the second server receives the resource data of the non-player characters returned by the character service, and controls the non-player characters to exist in the virtual scene corresponding to the player characters in order to create the target service.

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

[0081] Cloud technology is a general term encompassing network technology, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model. It can form resource pools, allowing for on-demand use with flexibility and convenience. Cloud computing technology will become a crucial support. The backend services of cloud computing systems require substantial computing and storage resources.

[0082] See Figure 2A-2B , Figure 2A-2B This is a schematic diagram of the structure of an electronic device that implements a service processing method in a virtual scene according to an embodiment of this application. In practical applications, the electronic device 500 can be implemented as follows: Figure 1 The server or terminal in the application describes an electronic device that implements the service processing method in the virtual scene of the embodiments of this application. Figure 2A-2B The illustrated electronic device 500 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 understood that the bus system 540 is used to implement communication between these components. In addition to a data bus, the bus system 540 also includes a power bus, a control bus, and a status signal bus. However, for clarity, all buses are labeled as bus system 540 in Figure 2.

[0083] 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. The general-purpose processor can be a microprocessor or any conventional processor, etc.

[0084] User interface 530 includes one or more output devices 531 that enable the presentation of media content, including one or more speakers and / or one or more visual displays. User interface 530 also includes one or more input devices 532, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.

[0085] The memory 550 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state storage, hard disk drives, optical disk drives, etc. The memory 550 may optionally include one or more storage devices physically located away from the processor 510.

[0086] The memory 550 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), and the volatile memory may be random access memory (RAM). The memory 550 described in this application embodiment is intended to include any suitable type of memory.

[0087] In some embodiments, memory 550 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, as illustrated below.

[0088] Operating system 551 includes system programs for handling various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, driver layer, etc., for implementing various basic business functions and handling hardware-based tasks;

[0089] The network communication module 552 is used to reach other computing devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 including: Bluetooth, WiFi, and Universal Serial Bus (USB), etc.

[0090] Presentation module 553 is configured to enable the presentation of information (e.g., a user interface for operating peripheral devices and displaying content and information) via one or more output devices 531 (e.g., a display screen, a speaker, etc.) associated with user interface 530;

[0091] The input processing module 554 is used to detect and translate one or more user inputs or interactions from one or more input devices 532.

[0092] In some embodiments, the service processing apparatus in the virtual scene provided in this application can be implemented in software. Figure 2A This illustration shows a schematic diagram of the structure of an electronic device provided in an embodiment of this application as a first server for providing virtual scene data. The processing device 555 for serving the virtual scene, stored in memory 550, can be software in the form of programs and plugins, and includes the following software modules: a receiving module 5551, a generating module 5552, a sending module 5553, and a control module 5554. These modules are logically connected and can therefore be arbitrarily combined or further divided according to their implemented functions. The functions of each module will be described below.

[0093] In some embodiments, such as Figure 2B As shown, Figure 2B The diagram illustrates the structure of the second server to which the electronic device provided in this application belongs for role services. The software modules stored in the processing device 555 of the virtual scene service in the memory 550 may include: a request receiving module 5555, a data generation module 5556, and a data sending module 5557. These modules are logically linked and can therefore be arbitrarily combined or further divided according to their implemented functions. The functions of each module will be described below.

[0094] In other embodiments, the processing device for services in the virtual scene provided in this application can be implemented in hardware. As an example, the processing device for services in the virtual scene provided in this application can be a processor in the form of a hardware decoding processor, which is programmed to execute the processing method for services in the virtual scene provided in this application. For example, the processor in the form of a hardware decoding processor can be one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), or other electronic components.

[0095] Based on the above description of the service processing system and electronic device in the virtual scene provided in the embodiments of this application, the service processing method in the virtual scene provided in the embodiments of this application is described below. In some embodiments, the service processing method in the virtual scene provided in the embodiments of this application can be implemented by a server or a terminal alone, or by a server and a terminal working together. In some embodiments, the terminal or server can implement the service processing method in the virtual scene provided in the embodiments of this 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), that is, a program that needs to be installed in the operating system to run, such as a client that supports virtual scenes, such as a game APP; it can also be a mini-program, that is, a program that only needs to be downloaded to the browser environment to run; or it can be a mini-program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module or plugin.

[0096] The following uses a server implementation as an example to illustrate the service processing method in the virtual scenario provided in this application embodiment. Here, the server refers to the first server to which the target service belongs. Unless otherwise specified below, the server is the first server. See [link to relevant documentation]. Figure 3 , Figure 3 This is a flowchart illustrating a service processing method in a virtual scene provided in this application embodiment. The service processing method in a virtual scene provided in this application embodiment includes:

[0097] In step 101, the server responds to the creation request sent by the player character for the target service in the virtual scene and determines the number of player characters corresponding to the target service.

[0098] In practice, the server can generate virtual scenarios and receive creation requests for a target service sent by players through terminals with applications that support virtual scenarios. The server parses the creation request, determines information related to the target service, and matches the information in the creation request with the configuration information of the target service read by the server to determine whether the creation conditions for the target service are met. The configuration information for the target service may include the number of group members required to start the target service, the level of the group members, and the type of the group members. These group members can include real players and virtual players. Real players correspond to player characters in the game, and virtual players correspond to non-player characters provided by the game. The level of group members generally refers to the level of real players.

[0099] For example, taking a multiplayer online game (MMORPG) as an example, game A has instances where players can obtain high-level items by opening them, thereby improving their combat power. In this case, services related to instances can be designated as target services. The server (the main game server) can determine the opening conditions for the corresponding instance service by reading the instance configuration information. The instance configuration information may include the number of group members required to open the instance, the levels of the group members, etc. Suppose player U opens instance D, which requires 6 players. After inviting 4 real players, player U cannot invite any more real players within the preset time. The server then determines that instance D is still short 2 group members. To enable player U to open the instance as quickly as possible, the server can assign 2 virtual players to instance D. To distinguish these virtual players from player characters, their in-game roles can be called non-player characters.

[0100] In step 102, when the number of player characters is less than the number of characters required to create the target service, a character creation request is generated. The character creation request is used to create non-player characters corresponding to the target service.

[0101] In practice, when the server providing the virtual scene receives a creation request for a target service sent by a player character through the virtual scene client, it can determine whether the creation conditions for the target service are met based on the configuration information for that service. These conditions may include the current number of player characters reaching the required number for creating the target service. In other words, if the current number of player characters does not reach the required number, the server can generate a character creation request for a non-player character corresponding to the target service in order to satisfy the creation conditions.

[0102] Continuing the previous example, the target service can be viewed as a dungeon run completed by a player character in collaboration with other player characters or non-player characters. Before a player character enters a dungeon, the game server determines whether entry is permitted based on dungeon configuration information. If the entry conditions are not met (level restrictions, combat power restrictions, number of party members, etc.), the game server generates a character creation request. This request is then used by a character service (bot service) specifically designed to control non-player characters to create a non-player character.

[0103] The above method responds to the creation conditions of the target service being met. Based on the determined number of characters to be created, the server generates a character creation request and forwards it to the character service. At this time, the character creation process is completed by the character service on the second server. It is not necessary to modify the original business logic of the target service in the (game) server. It is only necessary to generate a character creation request and send it to the second server to which the character service belongs. In this way, the amount of computation of the game server can be greatly reduced and the consumption of game server computing resources can be reduced.

[0104] In some embodiments, the server may also generate a character creation request in the following form: when the number of player characters is less than the number of characters required to create the target service, the server obtains the type of non-player character corresponding to the target service and generates a character creation request carrying the type of non-player character to request the creation of a non-player character of the corresponding type.

[0105] In practice, the character creation request generated by the server can carry the type of non-player character, instructing the character service to create a non-player character matching the corresponding type. The server can determine the type of non-player character required by the target service based on the configuration information.

[0106] The aforementioned character creation request, which includes non-player character types, not only takes into account the number of characters required by the target service but also includes the types of non-player characters, thus improving the accuracy of the generated non-player characters.

[0107] In some embodiments, the server may also generate a character creation request in the following forms: when the number of player characters is less than the number of characters required to create the target service, the server determines the level of the player characters; when the level of the player characters does not reach the level threshold and the number of player characters is less than the number of characters required to create the target service, a character creation request is generated.

[0108] In practice, when creating a target service, in order to improve the gaming experience for players of different levels, different creation conditions can be set for players of different levels. For example, for player characters whose level has not reached the level threshold, the server can be requested to allocate a non-player character. Similarly, for player characters whose level has reached the level threshold, the target number of other real player characters need to be invited before the target service can be started.

[0109] Continuing the previous example, let's set up game A with player levels ranging from 1 to 6. For game instance D, the following configuration information exists: For players at levels 1-3, instance D requires 3 characters, and completing the instance rewards virtual items of levels A to C; for players at levels 4-5, instance D requires 4 characters, and completing the instance rewards virtual items of levels D to F; for players at level 5, instance D requires 3 characters, and completing the instance rewards virtual items of level G. When a player's level is below 4, they can request the server to allocate a target number of non-player characters. That is, after the server receives a creation request for instance D from a player at level 3, it determines that one more non-player character is needed for instance D, and a character creation request with a total of 1 non-player character is then created.

[0110] The character creation request generated based on the player's character level is more targeted than a character creation request generated solely based on the number of characters required by the target service.

[0111] In other embodiments, the server may invite other player characters in the following manner: when a player character's level reaches a level threshold, an invitation prompt message is generated and returned, wherein the invitation prompt message is used to prompt the player character to invite other player characters to meet the number of characters required to create the target service.

[0112] In practice, when a player character's level reaches a certain threshold, in order to improve the human-computer interaction experience, the server refuses to generate a character creation request for the target service. Instead, it generates an invitation message, prompting the player character to request other player characters first. In other words, the server needs to request the target number of real players in order to meet the number of characters required to create the target service.

[0113] Continuing with the previous example, assuming player character U is level 5 and reaches the level threshold of level 4, after the server receives player character U's request to create game instance D, it generates an invitation message "Please ask 2 other players to open this instance" and displays the invitation message on the game interface of player character U's terminal.

[0114] In some embodiments, the server may also generate a character creation request in the following form: when the number of player characters is less than the number of characters required to create the target service, the server obtains the type of the player character and generates a character creation request for creating a non-player character that matches the type of player character.

[0115] In practice, the server can also determine non-player characters that match the type of player character based on the player character type, and then generate a character creation request for the non-player character that matches the type of player character.

[0116] Continuing with the previous example, in game instance D, non-player characters carrying offensive items are configured for player characters who are on the attacking side; and non-player characters carrying defensive items are configured for player characters who are on the defending side.

[0117] In step 103, the character creation request is sent to the second server to which the character service belongs, and the resource data of the non-player character returned by the second server based on the character service is received.

[0118] In practice, the server hosting the target service sends the generated character creation request to the second server to which the character service belongs. This allows the character service on the second server to return resource data for the target number of non-player characters based on the character creation request. It should be noted that the second server and the (game) server can be independent servers or integrated into the same target server. The character service is an external, independent service connected to the target service via a gateway.

[0119] The aforementioned external, independent role service generates non-player characters that can simulate the behavior of real players, possessing strong scalability and requiring very little modification to the original business logic of the target service.

[0120] In step 104, based on the resource data of the non-player character, the non-player character is controlled to exist in the virtual scene corresponding to the player character in order to create the target service.

[0121] It should be noted that non-player characters are used to collaborate with player characters in performing interactive tasks corresponding to the target service.

[0122] In practice, after receiving resource data of non-player characters returned by the second server through the gateway device based on the role service, the server can control the non-player characters to exist in the virtual scene corresponding to the player character, for the purpose of creating the target service. To reduce the number of communications with the role service, the server can receive resource data of all non-player characters corresponding to the target service by forwarding a role creation request once, and temporarily store it in the client cache. Thus, when the server receives a selection operation from the player character in the virtual scene interface for at least one target non-player character, it renders the non-player character based on the resource data of the non-player character and controls the rendered non-player character to appear in the virtual scene interface where the player character is located.

[0123] Continuing with the previous example, for game instance D, after the server forwards a character creation request, it receives 10 non-player characters with different virtual items returned by the character service. In response to the level 2 player character U's selection operation of at least two of these 10 non-player characters, the player character U can start the instance game with the selected target non-player character. For another instance of game instance D opened by another level 2 player character, the player character U can select at least two other non-player characters to start the game instance.

[0124] In some embodiments, see Figure 4 , Figure 4 This is a schematic diagram of the process for controlling player character team formation provided in an embodiment of this application, based on... Figure 3 After step 104, steps 201-205 can be executed to implement the process of a player character inviting a non-player character to form a team.

[0125] Step 201: The server receives a party request from a player character for a non-player character and sends the party request to the character service.

[0126] The team request is used to request a non-player character to join the group to which the player character belongs.

[0127] In practice, when the server controls a target number of non-player characters to exist in the virtual scene where the player characters are located, in response to the player characters' requests to form a party with the target non-player characters, the party request can be forwarded to the character service.

[0128] For example, Figures 5A-5C This is a visual illustration of a non-player character provided in an embodiment of this application. See also... Figure 5AIn the diagram, the server controls non-player characters 11, 12, and 13 to exist in a silent state (i.e., the gray lines shown in the diagram) in the virtual scene where the player character shown is located. At this time, the player can move the player character to the target non-player character and send a team invitation to the non-player character. When the server detects that the distance between the player character and non-player character 11 is less than the distance threshold, it displays "I want to team up with you, is that okay?" in the virtual scene interface. The server forwards the received team request to the character service.

[0129] Step 202: Receive the response result returned by the character service based on the team request, and return the response result to the player character.

[0130] In actual implementation, the server receives a response from the role service regarding the team request. The response includes one of the following: an agreement message or a rejection message.

[0131] Step 203: When the response indicates that a non-player character agrees to join the group, obtain the number of characters in the group.

[0132] In practice, when a non-player character controlled by the role service agrees to join a team, the number of characters for the target service increases. The server can obtain the number of characters in the current group for the target service. If the number of characters does not reach the number of characters required to create the target service, it can continue to generate prompts to encourage player characters to invite other non-player characters to join a team until the number of characters in the current group reaches the number of characters required to create the target service.

[0133] For example, see Figure 5B In the image, after the player character shown as number 1 successfully invites non-player character number 11 to join the party, the player character controls non-player character number 11 to switch from a silent state to an active state (from...). Figure 5A The gray lines in the text have been changed to Figure 5B (The black line in the image indicates that the server has detected that the number of members in the current group has not yet reached the number of characters needed to create the instance. At this point, the control prompt message "One more member is needed to start the game" will appear in the virtual scene interface corresponding to the player character. The player character can then continue to send party invitations to non-player characters 12 and 13 within the virtual scene.)

[0134] The method described above, which invites non-player characters to join the player character's group by sending a team request, can improve the human-computer interaction experience of the player character and make the non-player character's behavior more realistic in simulating the player's behavior.

[0135] Step 204: When the number of roles reaches the number required to create the target service, generate a message indicating that the target service has been successfully created.

[0136] In actual implementation, when the server detects that the number of members in the current group has reached the number of characters required to create the target service, it can generate a message indicating that the target service has been successfully created, to notify the player that the target service has been successfully created.

[0137] For example, see Figure 5C In the image, player character number 1 successfully invited non-player characters 11 and 12 to join the group and started the instance.

[0138] Step 205: Return the generated prompt message to the player character.

[0139] In practice, the server returns the generated prompt information to the player character and controls how the prompt information is displayed in the virtual scene interface corresponding to the player character.

[0140] For example, see Figure 6 , Figure 6 This is a schematic diagram of successful team formation provided in an embodiment of this application. The diagram shows... Figure 5C Non-player characters #11 and #12 have both successfully joined the group.

[0141] In some embodiments, the server can control the exit of non-player characters by: obtaining the termination conditions of the target service; determining the termination of the target service based on the termination conditions, and controlling the non-player characters to exit the virtual scene corresponding to the player character.

[0142] In practice, the termination conditions for the target service may include at least one of the following: the player character's health attribute value falls below a preset threshold, or the termination time for the target service is reached. When the termination conditions for the target service are met, the server determines that the target service for the current player character has ended and controls non-player characters to exit the corresponding virtual scene.

[0143] In some embodiments, see Figure 7 , Figure 7 This is a schematic diagram of non-player character interaction provided in the embodiments of this application, combined with Figure 7 The steps shown are explained.

[0144] Step 301: The server detects the player character's interaction behavior with non-player characters and obtains the interaction data corresponding to the interaction behavior.

[0145] In actual implementation, the server detects player characters' interactions with non-player characters in the virtual scene and obtains the corresponding interaction data.

[0146] For example, in game instance D, player character U and non-player character R cooperate to obtain target virtual item F. The server obtains corresponding interaction data for the non-player character (e.g., the non-player character assists the player character in overcoming obstacles in the game scene).

[0147] Step 302: Send the interaction data to the character service and receive the response data of the non-player character returned by the character service based on the interaction data.

[0148] In practice, the server sends the corresponding interaction data to the role service, which then determines the response data for the non-player character based on the received interaction data and returns the response data to the value server. The server then renders the non-player character based on the received response data.

[0149] Continuing from the previous example, the server receives response data from the role service for a non-player character R. This data could be used to control the non-player character to crouch down in front of the player character to help the player character overcome obstacles.

[0150] Step 303: Based on the response data, control the non-player character to execute the corresponding interactive response.

[0151] In practice, the server controls non-player characters to perform interactive behaviors corresponding to the response data in the virtual scene where the player characters are located.

[0152] Continuing from the previous example, the server controls a non-player character R to perform an interactive action of crouching down in front of the player character U in the game scene where the player character U is located.

[0153] In some embodiments, the service processing method in the virtual scene provided in this application embodiment can also be illustrated using the implementation of a second server to which the role service belongs as an example. See also Figure 8 , Figure 8 This is a flowchart illustrating a service processing method in a virtual scene provided in this application embodiment. The service processing method in a virtual scene provided in this application embodiment is applied to a second server to which the role service belongs.

[0154] Step 401: The second server receives a character creation request for creating a non-player character corresponding to the target service.

[0155] Among them, the character creation request is generated by the server to which the target service belongs in response to the creation request sent by the player character for the target service in the virtual scene, and determines the number of player characters corresponding to the target service. It is generated when the number of player characters is less than the number of characters required to create the target service.

[0156] In practice, the second server (the server to which the character service belongs) can receive a character creation request forwarded by the server to which the target service belongs when the conditions for creating a non-player character are met.

[0157] Step 402: Based on the character creation request, generate resource data for non-player characters;

[0158] In practice, the character server creates the target number of non-player characters based on the received character creation requests.

[0159] Step 403: Send the resource data of the non-player character to the server so that the server can control the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character in order to create the target service.

[0160] In practice, the character server sends the resource data of non-player characters to the target service's (game) server via a gateway, so that the (game) server can execute... Figure 3 Step 104, as shown, involves controlling the non-player character to exist in the virtual scene corresponding to the player character based on the non-player character's resource data, in order to create the target service.

[0161] By applying the embodiments of this application, when the number of player characters is less than the number of characters required to create the target service, the server to which the target service belongs will forward character creation requests for non-player characters to an external, independent character service for processing. This effectively reduces the resource consumption of the server to which the target service belongs and improves the server's processing efficiency. In addition, by using an external, independent character service to control non-player characters to simulate the behavior of real players, it has the advantages of strong scalability and very low intrusion into the original business logic.

[0162] The following will describe an exemplary application of the embodiments of this application in a real-world application scenario.

[0163] In practical applications, in role-playing games, players can obtain advanced items by opening game dungeons, thereby improving their combat power. Figures 9A-9B This is a flowchart of the copy creation method provided by the relevant technology; see [link / reference]. Figure 9AThe dungeon creation process is as follows: The role-playing game server executes step 501, receiving a dungeon creation request sent by a player character through the game client; then, the server executes step 502, determining if the number of participants (the number of real players) is sufficient. If the number is sufficient, the server executes step 503, the dungeon is successfully created, and the dungeon is started; if the number is insufficient, the server executes step 504, returning a dungeon creation failure response. To ensure dungeon creation can still occur even when the number of players is insufficient, the server can execute... Figure 9B Step 505 in the process involves creating a bot, which uses built-in business logic to enable the instance to open. Here, the bot is a server-hosted object that can simulate real player behavior, and is the non-player character mentioned above. However, the method of creating bots directly adds or modifies branch logic in the relevant source code of the original game business process to simulate real player behavior. This involves modifications to the source code, making it highly intrusive to the original business, extremely complex, and difficult to extend.

[0164] Based on this, embodiments of this application provide a method for processing services in a virtual scene. This method simulates a real player in a role-playing game through an external service. The robot-related services created using this method are independent of existing services and can implement robot-related functions without modifying existing business logic. Therefore, it has minimal intrusion into existing business logic and can be easily extended.

[0165] Next, the processing method of services in the virtual scene provided in the embodiments of this application will be described. See Figure 10 , Figure 10 This is a schematic diagram illustrating the service processing method in a virtual scene provided in the embodiments of this application, combined with... Figure 10 The steps shown are explained.

[0166] Step 601: The game server receives a request from the player to create a copy via the game client.

[0167] Step 602: The game server determines whether the number of players in the current instance has reached the required number of players for the current game instance.

[0168] If the number of players in the current instance does not reach the required number of players for the current game instance, proceed to step 603.

[0169] Step 603: The game server generates a character creation request for creating a robot and sends the request to the external robot service.

[0170] In practice, bot services can simulate player input or respond to server notifications on behalf of players. See [link to relevant documentation]. Figure 11 , Figure 11 This is an overall view of the robot service provided in the embodiments of this application. The figure shows the application scenarios of the robot service, which can be stress testing (simulating a large number of online players), integration testing (combination of multiple modules or single module with multiple test cases), logic testing (business logic requiring multiple people), and gameplay logic (offline hosting, online hosting, partner battles, etc.).

[0171] Step 604: The external robot service determines whether the current replica needs to be supplemented with robots based on the received robot creation request, and obtains the determination result.

[0172] Step 605: When the judgment result indicates that the current game instance needs to be replenished with robots, the external robot service creates resource data for the target number of robots and sends the robot resource data to the game server.

[0173] In actual implementation, see Figure 12 , Figure 12 This is a schematic diagram of the robot service processing flow provided in this application embodiment. The creation function, shown as number 1, involves the robot service receiving a creation request for a simulated robot, parsing the request, and creating the target number of robots after confirming that the currently opened game instance does indeed require additional robots. The team-up function, shown as number 2, involves the robot service creating robots and then forming a team with the current player to play in the same instance. After teaming up, players can enter the instance and perform corresponding interactive actions (such as combat) within it.

[0174] In practical applications, the bot service reads the corresponding processing scripts and completes them through built-in logic; in games, the bot simulates players to complete corresponding processes (such as forming a team, entering a dungeon, and engaging in combat). Different types of AI can also be introduced into the bot service to drive its actions. Furthermore, the bot's behavior can be enriched by combining it with the game's existing automation logic; for example, logic such as movement and combat is already provided by the original service, so the bot service can be omitted. See also Figure 13 , Figure 13This is a schematic diagram of the architecture of the external robot service provided in this application embodiment. In the diagram, the robot service RobotSvr communicates with other game services through the Gateway. Other services may include RoleSvr (built-in character service) providing registration and login functions, SocialSvr (social service) providing functions such as team formation and joining a team, and the combat service (CellSvr) providing services such as skill selection, target selection, movement, and skill release through strategies. It should be noted that low-frequency behaviors are completed through the robot service, while high-frequency behaviors can still be completed by the game server, which can effectively reduce the network packet volume of the game server.

[0175] Step 606: Based on the resource data returned by the robot service, the game server opens the current game instance and controls the robot to appear in the player's client's game interface.

[0176] For example, see Figure 14 , Figure 14 This is a schematic diagram of the robot display interface provided in the embodiment of this application. In the figure, the robot interface is presented through the game interface of the game client. Number 1 shows the player character controlled by the player, and number 2 shows the robot character created by the external robot service, which is used to cooperate with the player character to perform interactive tasks in the game instance.

[0177] In actual implementation, see Figure 15 , Figure 15 This is a schematic diagram of the service interaction process in a game instance provided in this application embodiment. The role-playing game server executes step 701, receiving a creation request for the instance sent by a player character through the game client. Next, the server executes step 702, determining if the number of participants (the number of real players) in the current instance is sufficient. If the number is sufficient, the server executes step 503, the instance is successfully created, and the instance is started. If the number of participants is insufficient, the server executes step 704, generating a bot creation request and sending it to an external bot service through a gateway. Upon receiving the corresponding bot creation request, the external bot service executes step 705, determining if the current game instance needs additional bots. If so, it executes step 706, creates a bot, and returns the corresponding data resources of the bot to the role-playing game server. When the role-playing game server determines that the number of participants for the game instance is sufficient, it executes step 703, starting the instance.

[0178] The external robot service provided in this application is not only applicable to role-playing game scenarios, but can also be used for game integration testing. Through fixed test cases, it can automatically test certain processes. Additionally, it can be used for stress testing; by creating multiple robots, it facilitates stress testing between the front-end and back-end. Actual testing using the external robot service shows a significant improvement in development efficiency when implementing the same processes in relevant application scenarios.

[0179] By applying the embodiments of this application, the behavior of real players can be simulated through an external, independent robot service, which has the advantages of strong scalability and very low invasiveness to the original business logic.

[0180] It is understood that in the embodiments of this application, data such as user information are involved. When the embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0181] The following description continues to illustrate the exemplary structure of the virtual scene service processing device 555 provided in the embodiments of this application as a software module. In some embodiments, as shown in FIG2, the software module stored in the virtual scene service processing device 555 in the memory 550 may include:

[0182] The receiving module 5551 is used to respond to a creation request sent by a player character for a target service in a virtual scene and determine the number of player characters corresponding to the target service;

[0183] The generation module 5552 is used to generate a character creation request when the number of player characters is less than the number of characters required to create the target service. The character creation request is used to create a non-player character corresponding to the target service.

[0184] The sending module 5553 is used to send the character creation request to the second server to which the character service belongs, and to receive the resource data of the non-player character returned by the second server based on the character service;

[0185] The control module 5554 is used to control the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character, so as to create the target service.

[0186] In some embodiments, when the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to obtain the type of non-player character corresponding to the target service; and generate a character creation request carrying the type of the non-player character to request the creation of a non-player character of the type.

[0187] In some embodiments, when the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to determine the level of the player characters; and when the level of the player characters does not reach the level threshold and the number of player characters is less than the number of characters required to create the target service, a character creation request is generated.

[0188] In some embodiments, the generation module is further configured to generate an invitation prompt message and return the invitation prompt message when the player character's level reaches the level threshold; wherein the invitation prompt message is used to prompt the player character to invite other player characters to meet the number of characters required to create the target service.

[0189] In some embodiments, when the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to obtain the type of the player characters; and generate a character creation request for creating a non-player character that is compatible with the type of the player character.

[0190] In some embodiments, the processing device for services in the virtual scene further includes a team-up module, which is used to receive a team-up request from the player character for the non-player character and send the team-up request to the character service; wherein the team-up request is used to request the non-player character to join the group to which the player character belongs; receive a response result returned by the character service based on the team-up request, and return the response result to the player character.

[0191] In some embodiments, the team-up module is further configured to: obtain the number of characters in the group when the team-up prompt information indicates that the non-player character agrees to join the group; generate a prompt information to indicate that the target service has been successfully created when the number of characters reaches the required number of characters to create the target service; and return the generated prompt information.

[0192] In some embodiments, the control module is further configured to obtain the termination condition of the target service; based on the termination condition of the target service, determine when the target service ends, and control the non-player character to exit the virtual scene corresponding to the player character.

[0193] In some embodiments, the control module is further configured to detect the player character's interaction behavior with the non-player character, and obtain the interaction data corresponding to the interaction behavior; send the interaction data to the character service, and receive the response data of the non-player character returned by the character service based on the interaction data; and control the non-player character to execute the corresponding interaction response based on the response data.

[0194] In some embodiments, such as Figure 2B As shown, Figure 2B The diagram shown is a structural schematic of the second server to which the role service provided in this application belongs. The software modules in the processing device 555 storing the service in the virtual scene of the memory 550 may include:

[0195] The request receiving module 5555 is used to receive a character creation request for creating a non-player character corresponding to a target service; wherein, the character creation request is generated by the first server to which the target service belongs in response to a creation request for the target service in a virtual scene sent by a player character, when the number of player characters corresponding to the target service is less than the number of characters required to create the target service;

[0196] The data generation module 5556 is used to generate resource data for the non-player character based on the character creation request.

[0197] The data sending module 5557 is used to send the resource data of the non-player character to the first server, so that the first server controls the non-player character to exist in the virtual scene corresponding to the player character based on the resource data of the non-player character, so as to create the target service.

[0198] This application provides a computer program product or computer program that includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the service processing method in the virtual scene described in this application embodiment.

[0199] This application provides a computer-readable storage medium storing executable instructions. When these executable instructions are executed by a processor, they cause the processor to perform a processing method for a service in a virtual scene provided in this application. For example... Figure 3 The method for handling services in the virtual scenario is shown.

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

[0201] In some embodiments, executable instructions may take 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 standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

[0202] As an example, executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple collaborating files (e.g., a file that stores one or more modules, subroutines, or code sections).

[0203] As an example, executable instructions can be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.

[0204] In summary, by using the server to which the target service belongs in this application embodiment, when the number of player characters is less than the number of characters required to create the target service, the character creation requests for non-player characters are forwarded to an external, independent character service for processing, which can effectively reduce the resource consumption of the server to which the target service belongs. Furthermore, by using an external, independent character service to control the behavior of non-player characters to simulate real players, the simulated behavior of non-player characters can be made more realistic; using an external implementation method gives the business logic of the character service strong scalability and very low intrusion into the original business logic.

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

Claims

1. A method for processing services in a virtual scene, characterized in that, Applied to a first server, the method includes: In response to a creation request sent by a player character for a target service in a virtual scene, determine the number of player characters corresponding to the target service; When the number of player characters is less than the number of characters required to create the target service, a character creation request is generated. The character creation request is used to create a non-player character corresponding to the target service. The character creation request is sent to the second server to which the character service belongs. The character service is an external, independent service that is connected to the target service through a gateway and receives the resource data of the non-player character returned by the second server based on the character service. Based on the resource data of the non-player character, the non-player character is controlled to exist in a silent state in the virtual scene corresponding to the player character in order to create the target service; The system receives a party request from the player character for the non-player character and sends the party request to the character service; wherein the party request is used to request the non-player character to join the group to which the player character belongs; the system receives a response result returned by the character service based on the party request and returns the response result to the player character; When the response indicates that the non-player character agrees to join the group, the non-player character is controlled to switch from a silent state to an active state, and the number of characters in the group is obtained; when the number of characters reaches the number of characters required to create the target service, a prompt message is generated to indicate that the target service has been created successfully; the generated prompt message is returned to the player character. The low-frequency behaviors of the non-player characters are completed through the character service, while the high-frequency behaviors of the non-player characters are completed by the first server.

2. The method as described in claim 1, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the method further includes: Obtain the type of the non-player character corresponding to the target service; The generation of the character creation request includes: Generate a character creation request carrying the type of the non-player character to request the creation of a non-player character of that type.

3. The method as described in claim 1, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the method further includes: Determine the level of the player character; The generation of the character creation request includes: A character creation request is generated when the level of the player character has not reached the level threshold and the number of player characters is less than the number of characters required to create the target service.

4. The method as described in claim 3, characterized in that, The method further includes: When the player character's level reaches the level threshold, an invitation message is generated and returned. The invitation prompt message is used to prompt the player character to invite other player characters to meet the required number of characters to create the target service.

5. The method as described in claim 1, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the method further includes: Obtain the type of the player character; The generation of the character creation request includes: Generates a character creation request to create a non-player character that matches the type of the player character.

6. The method as described in claim 1, characterized in that, After controlling the non-player character to exist in the virtual scene corresponding to the player character, the method further includes: Obtain the termination condition of the target service; Based on the termination conditions of the target service, when the target service ends, the non-player character is controlled to exit the virtual scene corresponding to the player character.

7. A method for processing services in a virtual scene, characterized in that, Applied to a second server, the method includes: Received a character creation request for creating a non-player character corresponding to the target service; The character creation request is generated by the first server to which the target service belongs in response to a creation request sent by a player character for the target service in a virtual scene, when the number of player characters corresponding to the target service is less than the number of characters required to create the target service; Based on the character creation request, generate the resource data for the non-player character; The system sends resource data of the non-player character to the first server, enabling the first server to control the non-player character to exist in a silent state within the virtual scene corresponding to the player character, thereby creating the target service. It receives a team-up request from the player character for the non-player character and sends the request to the character service. The team-up request is used to request the non-player character to join the group to which the player character belongs. The character service is an external, independent service connected to the target service via a gateway. The system receives a response from the character service based on the team-up request and returns the response to the player character. When the response indicates that the non-player character agrees to join the group, the system controls the non-player character to switch from a silent state to an active state and obtains the number of characters in the group. When the number of characters reaches the required number for creating the target service, a prompt message indicating successful creation of the target service is generated. The generated prompt message is returned to the player character. Low-frequency behaviors of the non-player character are handled by the character service, while high-frequency behaviors are handled by the first server.

8. A service processing apparatus in a virtual scene, characterized in that, The device includes: The receiving module is used to respond to a creation request sent by a player character for a target service in a virtual scene and determine the number of player characters corresponding to the target service; The generation module is used to generate a character creation request when the number of player characters is less than the number of characters required to create the target service. The character creation request is used to create a non-player character corresponding to the target service. The sending module is used to send the character creation request to the second server to which the character service belongs. The character service is an external, independent service that is connected to the target service through a gateway and receives the resource data of the non-player character returned by the second server based on the character service. A control module is configured to, based on the resource data of the non-player character, control the non-player character to exist in a silent state within the virtual scene corresponding to the player character, in order to create the target service; receive a team-up request from the player character for the non-player character, and send the team-up request to the character service; wherein the team-up request is used to request the non-player character to join the group to which the player character belongs; receive a response result returned by the character service based on the team-up request, and return the response result to the player character; when the response result indicates that the non-player character agrees to join the group, control the non-player character to switch from a silent state to an active state, and obtain the number of characters in the group; when the number of characters reaches the number of characters required to create the target service, generate a prompt message to indicate that the target service has been created successfully; and return the generated prompt message to the player character; wherein, the low-frequency behavior of the non-player character is completed through the character service, and the high-frequency behavior of the non-player character is completed by the first server.

9. The apparatus as claimed in claim 8, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to: Obtain the type of the non-player character corresponding to the target service; Generate a character creation request carrying the type of the non-player character to request the creation of a non-player character of that type.

10. The apparatus as claimed in claim 8, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to: Determine the level of the player character; A character creation request is generated when the level of the player character has not reached the level threshold and the number of player characters is less than the number of characters required to create the target service.

11. The apparatus as claimed in claim 10, characterized in that, The generation module is also used for: When the player character's level reaches the level threshold, an invitation message is generated and returned. The invitation prompt message is used to prompt the player character to invite other player characters to meet the required number of characters to create the target service.

12. The apparatus as claimed in claim 8, characterized in that, When the number of player characters is less than the number of characters required to create the target service, the generation module is further configured to: Obtain the type of the player character; Generates a character creation request to create a non-player character that matches the type of the player character.

13. The apparatus as claimed in claim 8, characterized in that, The control module is also used for: Obtain the termination condition of the target service; Based on the termination conditions of the target service, when the target service ends, the non-player character is controlled to exit the virtual scene corresponding to the player character.

14. An electronic device, characterized in that, The electronic device includes: Memory, used to store executable instructions; A processor, when executing executable instructions stored in the memory, implements the processing method for services in a virtual scene as described in any one of claims 1 to 7.

15. A computer-readable storage medium storing executable instructions, characterized in that, When the executable instructions are executed by the processor, they implement the service processing method in the virtual scene as described in any one of claims 1 to 7.

16. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by the processor, they implement the service processing method in the virtual scene as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Game device, game control method, and game control program

    JP2013123488A

  • Multiplayer online game system using distributedservers and management method thereof

    KR1020040016364A