Non-player character processing method and device, electronic equipment and storage medium

By responding to player character movement operations in virtual scenes and using hot loading technology, the inefficiency of deploying non-player characters in virtual scenes is solved, efficient non-player character deployment is achieved, and monster-making process is simplified.

CN119215413APending Publication Date: 2024-12-31TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310792535.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-29
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

The current technology is inefficient in deploying non-player characters in virtual scenes, mainly because it is necessary to manually drag the monster to the specified coordinate point in editing mode, and restart the server and client after saving the data to see the monster effect, resulting in relatively efficient Low.

Method used

By displaying a virtual scene in the human-computer interactive interface, responding to the player character movement operation, selecting a location and displaying non-player characters at that location, using hot loading technology to send coordinate information to the server, so that the client and server can be rebooted without restarting. Efficient deployment of non-player characters in virtual scenes.

Benefits of technology

This realizes the method of efficiently deploying non-player characters in virtual scenes, improves deployment efficiency, avoids the necessity of restarting clients and servers, and simplifies the monster-making process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119215413A_ABST
    Figure CN119215413A_ABST
Patent Text Reader

Abstract

The invention provides a non-player character processing method and device, electronic equipment and a storage medium. The method comprises the steps that a virtual scene is displayed in a human-computer interaction interface, and the virtual scene comprises a first player character; and in response to an operation of controlling the first player character to move in the virtual scene, selecting at least one position in the virtual scene, and displaying at least one non-player character at each position. Through the method and the device, the efficiency of deploying the non-player character in the virtual scene can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of Internet technology, and in particular to a method, device, electronic device and storage medium for processing non-player characters. Background Art

[0002] Human-computer interaction technology in virtual scenes based on graphics processing hardware can realize diversified interactions between player characters controlled by users, or between player characters controlled by users and non-player characters controlled by artificial intelligence, according to actual application needs, and has wide practical value. For example, in virtual scenes such as games, it can simulate the real battle process between different player characters, or between player characters and non-player characters.

[0003] It can be seen that non-player characters (such as monsters) are an important part of the game. However, there is no effective solution in the relevant technology for how to quickly deploy non-player characters in a virtual scene. Summary of the invention

[0004] The embodiments of the present application provide a method, device, electronic device, computer-readable storage medium, and computer program product for processing non-player characters, which can improve the efficiency of deploying non-player characters in a virtual scene.

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

[0006] The present application embodiment provides a method for processing a non-player character, including:

[0007] Displaying a virtual scene in a human-computer interaction interface, wherein the virtual scene includes a first player character;

[0008] In response to an operation of controlling the first player character to move in the virtual scene, at least one position is selected in the virtual scene, and at least one non-player character is displayed at each of the positions.

[0009] The embodiment of the present application provides a processing device for a non-player character, including:

[0010] A display module, used for displaying a virtual scene in a human-computer interaction interface, wherein the virtual scene includes a first player character;

[0011] a selection module, configured to select at least one position in the virtual scene in response to an operation of controlling the first player character to move in the virtual scene;

[0012] The display module is further used to display at least one non-player character at each of the positions.

[0013] An embodiment of the present application provides an electronic device, including:

[0014] A memory for storing executable instructions;

[0015] The processor is used to implement the non-player character processing method provided in the embodiment of the present application when executing the executable instructions stored in the memory.

[0016] The embodiment of the present application provides a computer-readable storage medium storing computer-executable instructions for implementing the non-player character processing method provided in the embodiment of the present application when executed by a processor.

[0017] An embodiment of the present application provides a computer program product, including a computer program or computer executable instructions, which are used to implement the non-player character processing method provided in the embodiment of the present application when executed by a processor.

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

[0019] By controlling the way in which the first player character moves in the virtual scene, selecting a position in the virtual scene, and displaying the non-player character at each selected position, the non-player character can be efficiently and orderly deployed in the virtual scene, thereby improving the efficiency of deploying the non-player character in the virtual scene. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] Figure 1 is a schematic diagram of the architecture of a non-player character processing system 100 provided in an embodiment of the present application;

[0021] Figure 2 is a schematic diagram of the structure of an electronic device 500 provided in an embodiment of the present application;

[0022] Figure 3 is a flowchart of a method for processing non-player characters provided in an embodiment of the present application;

[0023] FIG. 4A to FIG. 4D It is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application;

[0024] Figure 5A and Figure 5B is a flowchart of a method for processing non-player characters provided in an embodiment of the present application;

[0025] Fig. 6A and Figure 6B It is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application;

[0026] Figure 7 It is a schematic diagram of the principle of the method for processing non-player characters provided in an embodiment of the present application;

[0027] Figure 8 It is a schematic diagram of configuration data provided in an embodiment of the present application. DETAILED DESCRIPTION

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

[0029] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it can be 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.

[0030] It is understandable that in the embodiments of the present application, when user information and other related data (such as data of player characters controlled by players) 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 need to comply with relevant laws, regulations and standards of relevant countries and regions.

[0031] In the following description, the terms "first\second\..." are merely used to distinguish similar objects and do not represent a specific ordering of 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.

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

[0033] 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.

[0034] 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 may be in real time or have a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations executed may be executed.

[0035] 2) Virtual scene: It is the scene displayed (or provided) when the application is running on the terminal device. The scene can be a simulation environment of the real world, a semi-simulation and semi-fictitious virtual environment, or a purely fictitious virtual environment. The virtual scene can be any one of a two-dimensional virtual scene, a 2.5-dimensional virtual scene, or a three-dimensional virtual scene. The embodiment of the present application does not limit the dimension of the virtual scene. For example, the virtual scene may include the sky, land, ocean, etc. The land may include environmental elements such as deserts and cities, and the player can control the player character to move in the virtual scene.

[0036] 3) Player-Controlled Character (PCC): refers to the character controlled by the player in the game. The player character can be a virtual image used to represent the player in the virtual scene, such as a virtual person, virtual animal, cartoon character, etc. The player character has its own shape and volume in the virtual scene and occupies a part of the space in the virtual scene.

[0037] 4) Non-Player Character (NPC): refers to a character in the game that is not controlled by the player. NPCs are generally controlled by computer artificial intelligence and have their own behavior patterns. They can be divided into plot NPCs, combat NPCs, and service NPCs. Sometimes there are NPCs with multiple functions. Among them, plot NPCs and service NPCs are usually not attackable targets, or they are attackable targets but do not actively attack. In addition, some NPCs will drop props, which can provide players with some game information or trigger plots.

[0038] 5) Hot Swap: It mainly generates bytecodes from compiled source code. After recompilation, the new bytecodes of the updated file can be directly reloaded into the memory without stopping the server. The ultimate goal is to achieve automatic service loading without restarting the server.

[0039] Taking the game scene as an example, for non-player characters (such as monsters) in the game scene, most of the solutions provided by related technologies are based on the monster placement editor. It is necessary to manually drag the monster to the specified coordinate point in the editing mode, save the data and restart the server and client before the monster placement plan can be seen, resulting in low monster placement efficiency.

[0040] In view of this, the embodiments of the present application provide a method, device, electronic device, computer-readable storage medium and computer program product for processing non-player characters, which can improve the efficiency of deploying non-player characters in virtual scenes. The electronic device provided by the embodiments of the present application is described below. The electronic device provided by the embodiments of the present application can be implemented as a terminal device, or implemented by a terminal device and a server in collaboration. The following is an example of a method for processing non-player characters provided by the embodiments of the present application being implemented by a terminal device and a server in collaboration.

[0041] For example, see Figure 1 , Figure 1 1 is a schematic diagram of the architecture of a non-player character processing system 100 provided in an embodiment of the present application, for realizing applications that support improving the efficiency of deploying non-player characters in a virtual scene, such as Figure 1 As shown, the processing system 100 of the non-player character includes: a server 200, a network 300 and a terminal device 400, wherein the network 300 can be a local area network or a wide area network, or a combination of the two, the terminal device 400 is a terminal device associated with the player, and a client 410 runs on the terminal device 400. The client 410 can be various types of clients, such as strategy game clients, shooting game clients, virtual reality clients, role-playing game clients, etc.

[0042] In some embodiments, a virtual scene may be displayed in the human-computer interaction interface of the client 410, wherein the virtual scene includes a first player character, such as player character A controlled by the current player (e.g., player 1). Then, the client 410 may respond to the operation of player 1 controlling the movement of the first player character in the virtual scene, and determine at least one position on the movement trajectory of the first player character, or at least one position around the movement trajectory of the first player character, as at least one position selected in the virtual scene. Subsequently, the client 410 may encapsulate the at least one position selected in the virtual scene into a configuration file, and send the configuration file to the server 200 through the network 300, so that the server 200 hot loads the configuration file (i.e., loads the configuration file carrying coordinate information by hot loading), so that the client 410 can display at least one non-player character at each position. In this way, efficient deployment of non-player characters in the virtual scene can be achieved without restarting the client and the server, thereby greatly improving the efficiency of deploying non-player characters in the virtual scene.

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

[0044] Cloud technology is a general term for network technology, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model. It can form a resource pool that can be used on demand and is flexible and convenient. Cloud computing technology will become an important support. The background services of the technical network system require a large amount of computing and storage resources.

[0045] For example, Figure 1 The server 200 in the embodiment can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content distribution networks (CDN, Content Delivery Network), and big data and artificial intelligence platforms. The terminal device 400 can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a car terminal, a virtual reality (VR, Virtual Reality) device, etc., but is not limited to this. The terminal device 400 and the server 200 can be directly or indirectly connected by wired or wireless communication, which is not limited in the embodiments of the present application.

[0046] In some embodiments, the terminal device can also implement the processing method of the non-player character provided in the embodiment of the present application by running various computer executable instructions or computer programs. For example, the computer executable instructions can be commands, machine instructions or software instructions at the microprogram level. The computer program can be a native program or software module in the operating system; it can be a local (Native) application (APP, APPlication), that is, a program that needs to be installed in the operating system to run, such as a strategy game APP or a browser; it can also be a small program, that is, a program that only needs to be downloaded to the browser environment to run. In short, the above-mentioned computer executable instructions can be instructions in any form, and the above-mentioned computer program can be an application, module or plug-in in any form.

[0047] The structure of the electronic device provided in the embodiment of the present application is further described below. Taking the electronic device as a terminal device as an example, see Figure 2 , Figure 2 is a schematic diagram of the structure of an electronic device 500 provided in an embodiment of the present application, Figure 2The electronic device 500 shown 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 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, the bus system 540 is not described in detail. Figure 2 Various buses are labeled as bus system 540 .

[0048] 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.

[0049] The user interface 530 includes one or more output devices 531 that enable presentation of media content, including one or more speakers and / or one or more visual display screens. The 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.

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

[0051] The memory 550 includes a volatile memory or a non-volatile memory, and may also 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.

[0052] 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 exemplarily described below.

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

[0054] A network communication module 552, for reaching other computing devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 include: Bluetooth, Wireless Compatibility Certification (WiFi), and Universal Serial Bus (USB);

[0055] a presentation module 553 for enabling presentation of information via one or more output devices 531 (e.g., display screen, speaker, etc.) associated with the user interface 530 (e.g., a user interface for operating peripherals and displaying content and information);

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

[0057] In some embodiments, the device provided in the embodiments of the present application can be implemented in software. Figure 2 The processing device 555 of the non-player character stored in the memory 550 is shown, which can be software in the form of a program and a plug-in, etc., including the following software modules: a display module 5551, a selection module 5552, a division module 5553, a control module 5554, a switching module 5555, a determination module 5556, a packaging module 5557 and a sending module 5558. These modules are logical, and therefore can be arbitrarily combined or further divided according to the functions implemented. It should be pointed out that in Figure 2 For the sake of convenience, all the above modules are shown at once, but it should not be considered that the processing device 555 of the non-player character excludes the implementation that can only include the display module 5551 and the selection module 5552. The functions of each module will be explained below.

[0058] The method for processing non-player characters provided in the embodiment of the present application will be specifically described below in conjunction with the exemplary application and implementation of the terminal device provided in the embodiment of the present application.

[0059] See also Figure 3 , Figure 3 is a flowchart of a method for processing non-player characters provided in an embodiment of the present application, which will be combined with Figure 3 The steps shown are explained.

[0060] It should be noted that Figure 3The method shown can be executed by various forms of computer programs running on the terminal device, and is not limited to the client. For example, it can also be the operating system, software module, script, and applet mentioned above. Therefore, the example of the client in the following should not be regarded as a limitation on the embodiments of the present application. In addition, for the convenience of expression, the terminal device and the client running on the terminal device are not specifically distinguished in the following.

[0061] In step 101, a virtual scene is displayed in a human-computer interaction interface.

[0062] Here, the virtual scene may include a first player character, for example, the first player character may be a game character A controlled by player 1 .

[0063] In some embodiments, taking the first player character as game character A controlled by player 1 as an example, player 1 can log in to a client (e.g., a multiplayer online role-playing game client) running on a terminal device through a pre-registered account (e.g., account 1), and the virtual scene can be displayed from a first-person perspective in the human-computer interaction interface of the client, for example, player 1 plays the game character A in the game from his own perspective; of course, the virtual scene can also be displayed from a third-person perspective, for example, player 1 can chase the game character A in the game to run the game; the virtual scene can also be displayed from a bird's-eye view, wherein the above-mentioned different perspectives can be switched at will.

[0064] It should be noted that, in addition to the game character A controlled by player 1, the virtual scene may also include player characters controlled by other players (e.g., game character B controlled by player 2 and game character C controlled by player 3, etc.) or non-player characters controlled by robot programs (e.g., monsters in the game, etc.). In addition, there may be multiple teams in the virtual scene, and the first player character may be assigned to any one of the multiple teams. The teams may be in hostile or cooperative relationships, and the teams in the virtual scene may include one or all of the above relationships.

[0065] Taking the first-person perspective display of a virtual scene as an example, the virtual scene displayed in the human-computer interaction interface may include: determining the field of view area of ​​the first player character (e.g., game character A controlled by player 1) according to the viewing position and field of view angle in the complete virtual scene, and presenting a portion of the virtual scene in the field of view area in the complete virtual scene, that is, the displayed virtual scene may be a portion of the virtual scene relative to the panoramic virtual scene. Because the first-person perspective is the most impactful viewing perspective for players, it can achieve immersive perception of players during the operation process.

[0066] Taking the display of a virtual scene from a bird's eye view as an example, the virtual scene displayed in the human-computer interaction interface may include: in response to a zoom operation on a panoramic virtual scene, a portion of the virtual scene corresponding to the zoom operation is presented in the human-computer interaction interface, that is, the displayed virtual scene may be a portion of the virtual scene relative to the panoramic virtual scene. In this way, the operability of the player in the operation process can be improved, thereby improving the efficiency of human-computer interaction.

[0067] In step 102, in response to an operation of controlling a first player character to move in a virtual scene, at least one position is selected in the virtual scene.

[0068] In some embodiments, step 102 may be implemented in the following manner: in response to the operation of controlling the first player character to move in the virtual scene, at least one position is determined in a geometric area centered on the first player character after the movement (i.e., the position where the first player character is located when the movement stops) as at least one position selected in the virtual scene. In other words, at least one position may be automatically determined in the geometric area centered on the first player character after the movement, for example, at least one position may be randomly selected from the geometric area as at least one position selected in the virtual scene.

[0069] It should be noted that the size of the above-mentioned geometric area can be fixed or dynamically adjusted by the player, that is, the player can set the size of the geometric area. For example, when the player wants the distance between the non-player character and the first player character to be closer, the player can set the size of the geometric area to be smaller. The embodiment of the present application does not make specific limitations on this.

[0070] For example, taking the first player character as game character A controlled by player 1, player 1 can control game character A to move in the virtual scene. For example, when player 1 expects to deploy a non-player character (such as a monster) near point B in the virtual scene, player 1 can control game character A to move to point B, and determine at least one position in a circular area with point B (i.e., the position where game character A stops moving) as the center and a radius of R. For example, at least one position can be randomly determined from the circular area as at least one position selected in the virtual scene, and then at least one non-player character can be displayed at each position. In this way, the player only needs to control the game character to move in the virtual scene to generate non-player characters (such as virtual stars) near the position of the moved game character (i.e., the position expected by the player), thereby improving the efficiency of deploying non-player characters in the virtual scene.

[0071] For example, see Figure 4A , Figure 4A is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Figure 4AAs shown, a first player character 402 (e.g., a game character A controlled by player 1) is displayed in a virtual scene 401, wherein the first player character 402 is located at point A in the virtual scene 401. When player 1 desires to deploy a non-player character near point B in the virtual scene, player 1 can control the first player character 402 to move from point A to point B. When it is detected that the first player character 402 arrives at point B in the virtual scene, at least one position can be determined in a circular area 403 with point B (i.e., the position of the first player character 402 after the movement) as the center and a radius of R, as at least one position selected in the virtual scene 401, and at least one non-player character (e.g., a virtual star) can be displayed at each position. For example, three positions can be randomly determined in the circular area 403, and a non-player character 404 can be displayed at each position.

[0072] It should be noted that the above-mentioned geometric area can be not only a circular area, but also an elliptical area, a square area, a diamond area, etc., and the embodiments of the present application do not make specific limitations on this.

[0073] In other embodiments, the above step 102 may also be implemented in the following manner: in response to an operation of controlling the first player character to move in the virtual scene, at least one position on the movement trajectory of the first player character is determined as at least one position selected in the virtual scene.

[0074] For example, taking the first player character as game character A controlled by player 1, when it is detected that player 1 controls game character A to move in the virtual scene, the position of game character A in the virtual scene can be obtained at fixed time intervals (for example, 0.5 seconds), and then the multiple positions obtained can be connected in chronological order from early to late to obtain the movement trajectory of game character A. Subsequently, at least one position on the movement trajectory of game character A can be determined as at least one position selected in the virtual scene. For example, a position can be selected on the movement trajectory of game character A at fixed lengths as the selected position in the virtual scene.

[0075] In some embodiments, following the above example, determining at least one position on the movement trajectory of the first player character as at least one position selected in the virtual scene can be achieved in the following manner: dividing the movement trajectory of the first player character into multiple trajectory segments; and determining at least one position determined based on the multiple trajectory segments as at least one position selected in the virtual scene.

[0076] For example, the above-mentioned division of the movement trajectory of the first player character into multiple trajectory segments can be achieved in the following way: the movement trajectory of the first player character is divided into multiple trajectory segments according to a fixed length (for example, 0.5 meters). For example, assuming that the total length of the movement trajectory of the first player character is 2 meters, the movement trajectory of the first player character can be evenly divided into 4 trajectory segments according to the length of 0.5 meters, assuming that they are trajectory segments 1 to trajectory segments 4, wherein the length of each trajectory segment is 0.5 meters.

[0077] For example, the above-mentioned division of the movement trajectory of the first player character into multiple trajectory segments can also be achieved in the following manner: the movement trajectory of the first player character is divided into multiple trajectory segments according to a fixed duration (for example, 2 seconds). For example, assuming that the total duration of the movement of the first player character in the virtual scene is 10 seconds, the movement trajectory of the first player character can be divided into 5 trajectory segments according to a duration of 2 seconds, assuming that they are trajectory segments 1 to 5. It should be noted that in this case, if the first player character moves at a variable speed in the virtual scene, the lengths of different trajectory segments may be different. For example, assuming that the movement speed of the first player character in the second half is greater than that in the first half, the length of trajectory segment 5 may be greater than that of trajectory segment 1.

[0078] For example, when the virtual scene includes multiple different types of areas, the above-mentioned division of the movement trajectory of the first player character into multiple trajectory segments can also be achieved in the following way: according to the number of areas passed by the first player character during the movement, the movement trajectory of the first player character is divided into multiple trajectory segments with the same number. For example, assuming that the player controls the first player character to move in the virtual scene, the character passes through 3 different areas in the virtual scene. For example, assuming that the player controls the first player character from area A (such as a grass area) through area B (such as a lake area) in the virtual scene and finally arrives at area C (such as a forest area), the movement trajectory of the first player character can be divided into 3 trajectory segments, which are assumed to be trajectory segments 1 to 3, wherein trajectory segment 1 corresponds to area A, for example The starting point of track segment 1 may be the position of the first player character in area A before the movement, and the end point of track segment 1 may be the junction of area A and area B; track segment 2 corresponds to area B, for example, the starting point of track segment 2 may be the junction of area A and area B (that is, the end point of track segment 1 may be used as the starting point of track segment 2), and the end point of track segment 2 may be the junction of area B and area C; track segment 3 corresponds to area C, for example, the starting point of track segment 3 may be the junction of area B and area C (that is, the end point of track segment 2 may be used as the starting point of track segment 3), and the end point of track segment 3 may be the position where the first player character stops moving in area C, so that different non-player characters may be deployed in different areas in the future to further improve the player's gaming experience.

[0079] For example, the above-mentioned determination of at least one position determined based on multiple trajectory segments as at least one position selected in the virtual scene can be achieved in the following manner: for each trajectory segment, at least one position on the trajectory segment is determined as at least one position selected in the virtual scene. That is to say, after the movement trajectory of the first player character is divided into multiple trajectory segments, at least one position can be selected from each trajectory segment as the position selected in the virtual scene. For example, taking trajectory segment 1 as an example, the starting point, midpoint, or end point of trajectory segment 1 can be used as the position selected in the virtual scene. In this way, multiple non-player characters can be evenly deployed on the movement trajectory of the first player character.

[0080] For example, the above-mentioned determination of at least one position determined based on multiple track segments as at least one position selected in the virtual scene can also be achieved in the following manner: at least one target track segment is determined from the multiple track segments, and at least one position on the at least one target track segment is determined as at least one position selected in the virtual scene. That is to say, after the movement trajectory of the first player character is divided into multiple track segments, some track segments can be selected from the multiple track segments, and at least one position on the selected part of the track segments can be selected as the position selected in the virtual scene. In this way, non-player characters can be deployed on the movement trajectory of the first player character in a targeted manner, thereby improving the player's gaming experience.

[0081] For example, the above-mentioned determination of at least one target trajectory segment from multiple trajectory segments can be achieved in the following manner: at least one trajectory segment whose length is greater than a length threshold (e.g., 2 meters) among the multiple trajectory segments is determined as at least one target trajectory segment. For example, taking the multiple trajectory segments as 4 trajectory segments, namely, trajectory segment 1 to trajectory segment 4, wherein the length of trajectory segment 1 is 1.9 meters, the length of trajectory segment 2 is 2.1 meters, the length of trajectory segment 3 is 2.3 meters, and the length of trajectory segment 4 is 1.8 meters, then trajectory segment 2 and trajectory segment 3 can be used as target trajectory segments, that is, at least one position can be selected from these two trajectory segments later as the selected position in the virtual scene.

[0082] For example, the above-mentioned determination of at least one target trajectory segment from multiple trajectory segments can also be achieved in the following manner: at least one selected trajectory segment from the multiple trajectory segments is determined as at least one target trajectory segment. For example, taking the multiple trajectory segments as 4 trajectory segments, namely trajectory segment 1 and trajectory segment 4, assuming that the player selects trajectory segment 3 from the 4 trajectory segments, for example, a click operation of the player on the trajectory identifier corresponding to trajectory segment 3 is received, then trajectory segment 3 can be used as the target trajectory segment, that is, at least one position can be selected from trajectory segment 3 later as the selected position in the virtual scene.

[0083] For example, the above-mentioned determination of at least one target trajectory segment from multiple trajectory segments can also be achieved in the following manner: at least one trajectory segment that passes through a set area (such as a grass area) among the multiple trajectory segments is determined as at least one target trajectory segment. For example, taking the multiple trajectory segments as 4 trajectory segments as an example, assuming that they are trajectory segments 1 to 4, wherein trajectory segment 1 corresponds to a desert area, trajectory segment 2 corresponds to a grass area, trajectory segment 3 corresponds to a lake area, and trajectory segment 4 corresponds to a forest area, and assuming that a non-player character (such as a butterfly) currently needs to be deployed in the grass area, then trajectory segment 2 can be used as the target trajectory segment, that is, at least one position can be selected from trajectory segment 2 later as the selected position in the virtual scene.

[0084] In other embodiments, the above step 102 may be implemented in the following manner: in response to the operation of controlling the first player character to move in the virtual scene, at least one position around the movement track of the first player character is determined as at least one position selected in the virtual scene. That is, when the position on the movement track of the first player character is not suitable for deploying the non-player character, the non-player character may also be deployed around the movement track of the first player character.

[0085] For example, see Figure 4B , Figure 4B is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Figure 4B As shown, a first player character 402 (e.g., game character A controlled by player 1) is displayed in a virtual scene 401. When it is detected that the player controls the first player character 402 to move in the virtual scene 401, at least one position can be selected around the movement trajectory 405 of the first player character 402 as the selected position in the virtual scene 401, and at least one non-player character is displayed at each position. For example, four positions can be selected alternately on both sides of the movement trajectory 405, and a non-player character 404 (e.g., a virtual star) is displayed at each position.

[0086] It should be noted that in addition to selecting a position on the movement trajectory of the first player character alone, or selecting a position around the movement trajectory of the first player character alone, the embodiment of the present application can also select a position on the movement trajectory of the first player character and around the movement trajectory at the same time. The embodiment of the present application does not make any specific limitations on this.

[0087] In some embodiments, the above-mentioned determination of at least one position around the movement trajectory of the first player character as at least one position selected in the virtual scene can be achieved in the following way: at least one position in the virtual scene that is closest to the movement trajectory of the first player character and satisfies the display conditions is determined as at least one position selected in the virtual scene, wherein the display conditions include at least one of the following: display geographical conditions and display rule conditions.

[0088] It should be noted that the above-mentioned display geographical conditions refer to the geographical conditions that can be displayed by non-player characters in the virtual scene. For example, taking the non-player character as monster A, assuming that monster A can only appear in the grass area in the virtual scene, when selecting a position in the virtual scene, only a position can be selected from the grass area. In other words, for monster A, the position in the virtual scene that is closest to the movement trajectory of the first player character and in the grass area can be used as the position selected in the virtual scene.

[0089] In addition, it should be noted that the above-mentioned display rule conditions refer to the rule conditions set by the game developer for non-player characters. For example, taking the non-player character as monster B, assuming that the rule conditions set by the game developer for monster B are that it can only appear in a specific area in the virtual scene, then for monster B, the position in the virtual scene that is closest to the movement trajectory of the first player character and in the specific area can be used as the selected position in the virtual scene.

[0090] For example, the above-mentioned determination of at least one position in the virtual scene that is closest to the moving track of the first player character and meets the display conditions as at least one position selected in the virtual scene can be achieved in the following manner: the moving track of the first player character is divided into multiple track segments, and at least one target track segment is determined from the multiple track segments; for each target track segment, at least one position in the virtual scene that is closest to the target track segment and meets the display conditions is determined as at least one position selected in the virtual scene. For example, taking the target track segment as track segment 1 among multiple track segments as an example, at least one position in the virtual scene that is closest to track segment 1 and meets the display conditions can be determined as at least one position selected in the virtual scene. In this way, by dividing the moving track of the first player character, non-player characters can be deployed in the virtual scene in a targeted manner, thereby improving the player's gaming experience.

[0091] In other embodiments, at least one position may be selected in the virtual scene in the following manner: in response to an operation of updating the field of view of the first player character, at least one position within the updated field of view of the first player character is determined as at least one position selected in the virtual scene.

[0092] For example, taking the first player character as game character A controlled by player 1, player 1 can adjust the orientation of game character A in the virtual scene by shaking the virtual joystick displayed in the virtual scene to update the field of view of player character A in the virtual scene. For example, whenever it is detected that the similarity between the image in the field of view of player character A before the update and the image in the field of view after the update is less than a similarity threshold (e.g., 80%), at least one position can be selected in the field of view of game character A after the update, that is, multiple positions can be selected in the virtual scene by controlling the field of view of game character A to change continuously. That is, in the process of controlling the field of view of game character A to change continuously, at least one position can be selected from multiple updated field of view respectively as the selected position in the virtual scene.

[0093] For example, taking the first player character as game character A controlled by player 1, player 1 can adjust the orientation of game character A in the virtual scene by shaking the joystick, thereby updating the field of view of game character A in the virtual scene. For example, assuming that player 1 updates the field of view of game character A from the original field of view 1 to field of view 2 (i.e., the field of view expected by player 1) by shaking the joystick, at least one position can be selected in field of view 2 as at least one position selected in the virtual scene. In other words, the embodiment of the present application can also select a position from the field of view when the update is stopped as the position selected in the virtual scene. In this way, the player can deploy the non-player character at the desired position in the virtual scene by simply updating the field of view of the first player character, thereby improving the player's gaming experience.

[0094] In some embodiments, following the above example, the above-mentioned determination of at least one position within the updated field of view of the first player character as at least one position selected in the virtual scene can be achieved in the following manner: at least one position within the updated field of view of the first player character and in a direction corresponding to the current orientation of the first player character is determined as at least one position selected in the virtual scene.

[0095] For example, see Figure 4C , Figure 4C is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Figure 4CAs shown, a first player character 402 (e.g., game character A controlled by player 1) and a virtual joystick 406 are displayed in a virtual scene 401. The player can update the field of view of the first player character 402 by shaking the virtual joystick 406. When the player updates the field of view of the first player character 402 to a desired field of view, at least one position can be selected within the updated field of view of the first player character 402 and in a direction corresponding to the current orientation of the first player character 402 as the position selected in the virtual scene 401. For example, four positions can be selected in a direction corresponding to the current orientation of the first player character 402, and a non-player character 404 (e.g., a virtual heart) can be displayed at each position. In this way, the player only needs to control and adjust the field of view of the first player character to deploy the non-player characters at desired positions in the virtual scene, thereby improving the player's gaming experience.

[0096] In some embodiments, at least one position may also be selected in the virtual scene in the following manner: in response to an operation of controlling the first player character to launch at least one virtual missile in the virtual scene, at least one landing point corresponding to the at least one virtual missile in the virtual scene is determined as the at least one position selected in the virtual scene.

[0097] For example, taking the first player character as game character A controlled by player 1, when game character A is equipped with a virtual launching prop, player 1 can control game character A to use the virtual launching prop to launch virtual projectiles in different directions in the virtual scene. Subsequently, the landing points of these virtual projectiles in the virtual scene can be used as the selected positions in the virtual scene. In this way, the position can be remotely selected in the virtual scene, which enhances the player's gaming experience.

[0098] It should be noted that the position selection operation can also be an operation of controlling the first player character to throw a virtual throwing object in the virtual scene. In this case, the above-mentioned step 102 can also be implemented in the following manner: in response to the operation of controlling the first player character to throw at least one virtual throwing object in the virtual scene, at least one landing point corresponding to the at least one virtual throwing object in the virtual scene is used as at least one position selected in the virtual scene.

[0099] For example, see Figure 4D , Figure 4D is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Figure 4DAs shown, a first player character 402 (e.g., game character A controlled by player 1) and a throwing control 407 are displayed in a virtual scene 401. When a click operation on the throwing control 407 is received from the player, the first player character 402 can be controlled to throw a virtual throwing object 408 in the virtual scene 401. Subsequently, the landing point of the virtual throwing object 408 in the virtual scene 401 can be used as the selected position in the virtual scene 401, and a non-player character 404 (e.g., a bird) is displayed at the position. In this way, the player can remotely select a position by throwing the virtual throwing object, thereby improving the player's gaming experience.

[0100] In some embodiments, see Figure 5A , Figure 5A is a flow chart of a method for processing non-player characters provided in an embodiment of the present application, such as Figure 5A As shown, in the execution Figure 3 Before step 102 shown, you can also perform Figure 5A Step 104A or step 104B shown in FIG. Figure 5A The steps shown are explained.

[0101] In step 104A, in response to the first player character completing a set task in the virtual scene, the first player character is controlled to enter a specified state.

[0102] Here, the designated state (or monster spawning state) is a state in which a non-player character is displayed at a position selected based on the first player character.

[0103] In some embodiments, taking the first player character as game character A controlled by player 1 as an example, when game character A is in the default state, when player 1 controls game character A to move in the virtual scene, non-player characters will not be generated on the moving track of game character A. After player 1 controls game character A to complete the set task in the virtual scene, game character A can be controlled to enter a specified state. At this time, when player 1 controls game character A to move in the virtual scene, non-player characters will be generated on the moving track of game character A. In other words, only when the first player character enters the specified state will non-player characters be displayed at the position selected by the first player character, thereby avoiding the generation of non-player characters when the player controls the first player character to perform other tasks, thereby causing interference to the player.

[0104] In step 104B, in response to the second player character releasing a set skill on the first player character, the first player character is controlled to enter a specified state.

[0105] In some embodiments, taking the example that the first player character is game character A controlled by player 1 and the second player character is game character B controlled by player 2, when game character A is in the default state, when player 1 controls game character A to move in the virtual scene, no non-player characters will be generated on the moving track of game character A. When player 2 controls game character B to release the set task for game character A, game character A can be controlled to enter the monster spawning state. At this time, when player 1 controls game character A to move in the virtual scene, non-player characters will be generated on the moving track of game character A. In other words, the monster spawning state of game character A can be given by other game characters, so that the interaction between different game characters can be strengthened and the game experience of players can be improved.

[0106] In other embodiments, see Figure 5B , Figure 5B is a flow chart of a method for processing non-player characters provided in an embodiment of the present application, such as Figure 5B As shown, after executing Figure 3 After step 102 shown, you can also perform Figure 5B Steps 105 and 106 shown will be combined Figure 5B The steps shown are explained.

[0107] In step 105, a corresponding location mark is displayed at each location.

[0108] In some embodiments, in response to a position selection operation based on the first player character, after at least one position is selected in the virtual scene, a corresponding position identifier (such as an aperture) can also be displayed at each position. That is to say, after selecting a position in the virtual scene, the selected position can also be displayed in a visual manner to facilitate subsequent processing by the user.

[0109] In step 106, in response to a triggering operation on any location marker, the triggered location marker is cancelled from being displayed, and the location corresponding to the triggered location marker is switched from a selected state to an unselected state.

[0110] In some embodiments, taking at least one position as 4 positions as an example, namely position 1 to position 4, a corresponding position identifier is displayed at each position, for example, position identifier 1 is displayed at position 1, position identifier 2 is displayed at position 2, position identifier 3 is displayed at position 3, and position identifier 4 is displayed at position 4. If the player is not satisfied with position 2 among the 4 positions, the player can click on position identifier 2. For example, when a click operation on position identifier 2 by the player is received, position identifier 2 can be cancelled and position 2 can be switched from a selected state to an unselected state, that is, a non-player character will not be displayed at position 2 subsequently. In this way, the selected position in the virtual scene is displayed in a visual manner, which facilitates the player's subsequent processing and improves the player's gaming experience.

[0111] In step 103, at least one non-player character is displayed at each location.

[0112] In some embodiments, the parameters of non-player characters (such as number, type, interaction attributes, etc.) can be uniformly set for all positions. Figure 3 Before step 103 shown, at least one of the following processes may also be performed: in response to a type setting operation, the set type is used as the type of the non-player character displayed at each position; in response to a quantity setting operation, the set quantity is used as the number of non-player characters displayed at each position; in response to an interaction attribute setting operation, the set interaction attributes are used as the interaction attributes of the non-player characters displayed at each position (including the health, attack power, personality, etc. of the non-player characters).

[0113] For example, taking at least one position as 4 positions, namely position 1 to position 4, the parameters of the non-player characters can be uniformly set for these 4 positions, that is, the parameters of the non-player characters displayed in these 4 positions are the same. For example, assuming that the type set by the player is type A, the type of non-player characters displayed in these 4 positions is all type A; assuming that the number set by the player is 10, the number of non-player characters displayed in these 4 positions is all 10; assuming that the interactive attribute set by the player is irritable (for example, actively attacking the game character approaching), the interactive attributes of the non-player characters displayed in these 4 positions are all irritable. In this way, by uniformly setting the parameters of the non-player characters for all selected positions, the player's operation steps can be saved and the player's gaming experience can be improved.

[0114] In other embodiments, the parameters of the non-player character can be set separately for each position. Figure 3Prior to step 103 shown, at least one of the following processes may also be performed for each position: in response to a type setting operation, the set type is used as the type of the non-player character displayed at the position; in response to a quantity setting operation, the set quantity is used as the number of non-player characters displayed at the position; in response to an interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at the position.

[0115] For example, taking at least one position as 4 positions, namely position 1 to position 4, the player can set the parameters of the non-player characters for each position separately. For example, for position 1, the player sets the number to 5, then 5 non-player characters can be displayed in position 1; for position 2, the player sets the number to 4, then 4 non-player characters can be displayed in position 2; for position 3, the player sets the number to 6, then 6 non-player characters can be displayed in position 3; for position 4, the player sets the number to 2, then 2 non-player characters can be displayed in position 4. In other words, the player can set the number, type, interaction attributes and other parameters of the non-player characters displayed in each position separately. In this way, it can meet the player's more fine-grained setting requirements and enhance the player's gaming experience.

[0116] It should be noted that the parameters of the non-player character may include, in addition to type, quantity, and interactive attributes, direction, relationship with the first player character, display duration, etc., which are not specifically limited in this embodiment of the present application.

[0117] In some embodiments, when at least one location belongs to a different area, the parameters of the non-player character can be uniformly set for the locations in the same area. Figure 3 Before step 103 shown, at least one of the following processes may be performed for each area: in response to a type setting operation, the set type is used as the type of the non-player character displayed at the location belonging to the area; in response to a quantity setting operation, the set quantity is used as the number of non-player characters displayed at the location belonging to the area; in response to an interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at the location belonging to the area.

[0118] For example, take at least one position as 5 positions, namely position 1 to position 5, where position 1 and position 2 belong to area A in the virtual scene (i.e., position 1 and position 2 are positions selected from area A), and position 3 to position 5 belong to area B in the virtual scene (i.e., position 3 to position 5 are positions selected from area B). When the player sets the parameters of the non-player character for position 1, the set parameters can be copied to position 2, i.e., the parameters of the non-player character displayed at position 2 are the same as those at position 1; similarly, when the player sets the parameters of the non-player character for position 3, the set parameters can be copied to position 4 and position 5, i.e., the parameters of the non-player character displayed at position 4 and position 5 are the same as those at position 3. In other words, the player can uniformly set the parameters of the non-player character for multiple positions in the same area, which simplifies the operation steps and improves the player's gaming experience.

[0119] It should be noted that after at least one non-player character is displayed at each position, the player can also control the first player character to interact with the non-player character. For example, the player can control the first player character to attack the non-player character. When the non-player character is defeated by the first player character, the first player character can obtain a corresponding amount of virtual resources (such as virtual gold coins). Alternatively, when the non-player character is defeated by the first player character, the non-player character can become a subsidiary character of the first player character. For example, when the player controls the first player character to fight with other player characters, the non-player character can assist the first player character in fighting. This embodiment of the present application does not specifically limit this.

[0120] In some embodiments, the above step 103 can be implemented in the following manner: encapsulating at least one coordinate corresponding to at least one position into a configuration file; sending the configuration file to the server so that the server hot-loads the configuration file to display at least one non-player character at each position. That is, after selecting a position in the virtual scene, the coordinates corresponding to the position can be exported to the configuration file, and the configuration file can be sent to the server so that the server loads the configuration file by hot-loading. In this way, through the hot-loading technology, the client can display at least one non-player character at each position without restarting the client and the server, which greatly improves the efficiency of deploying non-player characters in the virtual scene.

[0121] For example, the above-mentioned encapsulation of at least one coordinate corresponding to at least one position into the configuration file can be achieved in the following manner: obtaining at least one coordinate corresponding to at least one position; sending at least one coordinate to the chat box of the virtual scene; processing at least one coordinate in the chat box into configuration data, and sending the configuration data to the log file; copying the coordinate information obtained by searching based on keywords (such as the name of the first player character) in the log file to the configuration file, so that the configuration file carrying the coordinate information can be sent to the server later, so that the server can load the configuration file by hot loading. For example, the server can compile the configuration file and load the compiled new bytecode into the memory, so that the client can display at least one non-player character at each position in the running mode, which greatly improves the efficiency of deploying non-player characters in the virtual scene.

[0122] The method for processing non-player characters provided in the embodiment of the present application controls the movement of the first player character in the virtual scene to select a position in the virtual scene, then imports the coordinate information of the selected position into a configuration file, and then sends the configuration file to the server so that the server hot-loads the configuration file. In this way, the non-player characters can be displayed at each selected position (i.e., the position expected by the player) without restarting the server and the client. In other words, the technical solution provided in the embodiment of the present application can efficiently deploy non-player characters at the positions expected by the players in the virtual scene, thereby improving the efficiency of deploying non-player characters in the virtual scene.

[0123] The following is an explanation of an exemplary application of the embodiments of the present application in a practical application scenario.

[0124] An embodiment of the present application provides a method for processing non-player characters. In the game running mode, by adding a specified state (such as a monster spawning state) to the game character controlled by the player (i.e., the player character), the player can control the game character to move in the game scene. In this way, the coordinate information of the non-player character (such as a monster) can be generated in real time on the path passed by the game character. After the coordinate information is exported to a configuration file, the configuration file is sent to the server, so that the server loads the configuration file through the hot loading technology, thereby completing the monster placement plan without restarting the client and the server, greatly improving the efficiency of monster placement in the game scene.

[0125] The following is a detailed description of the method for processing non-player characters provided in the embodiment of the present application.

[0126] In some embodiments, see Fig. 6A , Fig. 6A is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Fig. 6AAs shown, after adding the monster spawning state to the game character 601 (i.e., the first player character), a countdown control 602 may be displayed, wherein the countdown control 602 may be used to remind the player of the remaining duration of the monster spawning state. Before the countdown displayed in the countdown control 602 ends, when the player controls the game character 601 to move in the game scene, a non-player character 603 (e.g., a virtual star) may be generated on the moving track of the game character 601.

[0127] In other embodiments, see Figure 6B , Figure 6B is a schematic diagram of an application scenario of the method for processing non-player characters provided in an embodiment of the present application, such as Figure 6B As shown, the player can control the game character 601 to move freely in the game scene, and the non-player characters (such as monsters) generated according to the movement trajectory of the game character 601 can piece together various patterns, such as star patterns, heart patterns, etc.

[0128] The following will continue to describe the method for processing non-player characters provided in the embodiment of the present application from a technical perspective.

[0129] The technical solution provided by the embodiment of the present application mainly includes the following four steps: 1) by adding a monster spawning state, a non-player character (such as a monster) is spawned at the player coordinate position (i.e., the coordinate position of the game character controlled by the player) in this state; 2) the player coordinate information when the monster is spawned is output to the chat box in the game; 3) the output information in the chat box is obtained and processed into configuration data; 4) the specified monster is spawned at the output coordinate. The above four steps are described in detail below.

[0130] 1) By adding a monster spawning state, monsters can be spawned at the player's coordinates in this state

[0131] In some embodiments, a monster spawning state can be created in the state configuration table, and the state can execute an interval effect every set time (for example, 500 milliseconds). Then, the atomic items of spawning a specified monster at the player coordinate point (i.e., the coordinate point of the game character controlled by the player) can be executed in the interval effect, wherein the atomic items of the monster may include: monster identification (ID, Identity Document), direction, distance from the summoner (i.e., the game character controlled by the player), whether it can be created in water, whose offset is used when creating, the number of creations, whether it is in the same camp as the summoner, the existence time, the relationship between the direction of the monster and the summoner when creating, whether to use the caster (EventSource) of the gain (Buff) as the master, and whether to ignore the terrain of the generated location. For example, the atomic items of a monster can be: create monster (6801000, 0, 0, 1, Buff caster, 1, no, 999999, default, no, yes).

[0132] 2) Output the player's coordinate information when the monster is spawned to the in-game chat box

[0133] In some embodiments, in the interval effect, the operation of adding a monster spawning state (Addbuff) to the game character controlled by the player can be executed simultaneously, including: the state source (EventSource, i.e., the buff caster), the state target (EventTarget, i.e., the buff carrier), the string identifier (StringID) of the state, and the duration of the state. For example, an operation of adding a monster spawning state can be: Addbuff (EventSource, EventSource, BUFF_fg_game02_RefreshMons, 200), and the event of the game character controlled by the player being added to the monster spawning state can be monitored in the event. Then, the atomic item of obtaining the player's coordinates can be executed in the event, and the obtained result can be output to the game chat box. Figure 7 As shown, after detecting that the game character controlled by the player is in the monster spawning state (i.e., the player is given BUFF 701), the atomic item of obtaining the player's coordinates can be executed through the custom Lua script 702 in the client, and the obtained result can be output to the game chat box 703.

[0134] 3) Get the output information in the chat box and process it into configuration data

[0135] In some embodiments, the information in the chat box is processed as follows: Figure 8 After the configuration data is shown, the configuration data can be output to the editor log (Editor.log) file, open the log file and search for the keyword player coordinates (MTR_PlayerPos), and copy the coordinate information obtained based on the keyword search to the configuration file.

[0136] 4) Create a new monster at the output coordinates

[0137] In some embodiments, a monster (GenericGreatMonsterByPos) atomic item can be created at a specified position in the configuration file, coordinate information can be traversed, and a specified monster can be spawned at each coordinate point, wherein the GenericGreatMonsterByPos atomic item includes: monster ID, X coordinate, Y coordinate. Subsequently, the configuration file can be uploaded to the server so that the server can hot-load the configuration file and the final effect can be viewed in the game.

[0138] In summary, the technical solution provided by the embodiment of the present application has the following beneficial effects: in the game running mode, by adding a monster spawning state to the game character controlled by the player, the monster coordinate information can be generated in real time on the moving track of the game character, and after the coordinate information is exported to the configuration file, the monster placement plan can be completed without restarting the client and the server through hot loading technology, which greatly improves the efficiency of monster placement. In other words, the embodiment of the present application can realize the rapid visual layout of the monster placement plan in the game running mode without restarting the server and the client.

[0139] The following is a description of an exemplary structure of a non-player character processing device 555 provided in an embodiment of the present application implemented as a software module. In some embodiments, Figure 2 As shown, the software modules stored in the processing device 555 of the non-player character in the memory 550 may include: a display module 5551 and a selection module 5552 .

[0140] Display module 5551 is used to display a virtual scene in the human-computer interaction interface, wherein the virtual scene includes a first player character; selection module 5552 is used to select at least one position in the virtual scene in response to an operation of controlling the movement of the first player character in the virtual scene; display module 5551 is also used to display at least one non-player character at each position.

[0141] In some embodiments, the selection module 5552 is further used to determine at least one position on the movement trajectory of the first player character as at least one position selected in the virtual scene in response to an operation of controlling the movement of the first player character in the virtual scene; or, to determine at least one position in a geometric area centered on the first player character after the movement as at least one position selected in the virtual scene in response to an operation of controlling the movement of the first player character in the virtual scene.

[0142] In some embodiments, the processing device 555 for non-player characters further includes a division module 5553 for dividing the movement trajectory of the first player character into a plurality of trajectory segments; a selection module 5552 for determining at least one position determined based on the plurality of trajectory segments as at least one position selected in the virtual scene.

[0143] In some embodiments, the division module 5553 is also used to perform one of the following processes: dividing the movement trajectory of the first player character into multiple trajectory segments according to a fixed length; dividing the movement trajectory of the first player character into multiple trajectory segments according to a fixed duration; dividing the movement trajectory of the first player character into multiple trajectory segments of the same number according to the number of areas passed by the first player character during the movement.

[0144] In some embodiments, the selection module 5552 is also used to perform one of the following processes: for each trajectory segment, determining at least one position on the trajectory segment as at least one position selected in the virtual scene; determining at least one target trajectory segment from multiple trajectory segments, and determining at least one position on the at least one target trajectory segment as at least one position selected in the virtual scene.

[0145] In some embodiments, the selection module 5552 is also used to perform at least one of the following processing: determining at least one trajectory segment among multiple trajectory segments whose length is greater than a length threshold as at least one target trajectory segment; determining at least one trajectory segment selected from multiple trajectory segments as at least one target trajectory segment; determining at least one trajectory segment among multiple trajectory segments that passes through a set area as at least one target trajectory segment.

[0146] In some embodiments, the selection module 5552 is further used to determine at least one position around the movement trajectory of the first player character as at least one position selected in the virtual scene in response to an operation of controlling the first player character to move in the virtual scene.

[0147] In some embodiments, the selection module 5552 is also used to determine at least one position in the virtual scene that is closest to the movement trajectory of the first player character and meets the display conditions as at least one position selected in the virtual scene, wherein the display conditions include at least one of the following: display geographical conditions and display rule conditions.

[0148] In some embodiments, the division module 5553 is further used to divide the movement trajectory of the first player character into multiple trajectory segments; the selection module 5552 is further used to determine at least one target trajectory segment from the multiple trajectory segments; for each target trajectory segment, at least one position in the virtual scene that is closest to the target trajectory segment and meets the display conditions is determined as at least one position selected in the virtual scene.

[0149] In some embodiments, the selection module 5552 is further used to determine at least one position within the updated field of view of the first player character as at least one position selected in the virtual scene in response to an operation of updating the field of view of the first player character; the display module 5551 is further used to display at least one non-player character at each position.

[0150] In some embodiments, the selection module 5552 is further used to determine at least one position within the updated field of view of the first player character and in a direction corresponding to the current orientation of the first player character as at least one position selected in the virtual scene.

[0151] In some embodiments, the selection module 5552 is further used to determine at least one landing point corresponding to the at least one virtual missile in the virtual scene as at least one position selected in the virtual scene in response to the operation of controlling the first player character to launch at least one virtual missile in the virtual scene; the display module 5551 is further used to display at least one non-player character at each position.

[0152] In some embodiments, the processing device 555 for non-player characters also includes a control module 5554 for performing one of the following processes before responding to an operation of controlling the movement of the first player character in the virtual scene: controlling the first player character to enter a specified state in response to the first player character completing a set task in the virtual scene; controlling the first player character to enter a specified state in response to the second player character releasing a set skill for the first player character; wherein the specified state is a state in which the non-player character is displayed at a position selected based on the first player character.

[0153] In some embodiments, the display module 5551 is also used to display a corresponding position identifier at each position after the selection module 5552 selects at least one position in the virtual scene; and to cancel the display of the triggered position identifier in response to a trigger operation on any position identifier; the processing device 555 of the non-player character also includes a switching module 5555, which is used to switch the position corresponding to the triggered position identifier from a selected state to an unselected state.

[0154] In some embodiments, the non-player character processing device 555 also includes a determination module 5556, which is used for the display module 5551 to perform at least one of the following processes before displaying at least one non-player character at each position: in response to a type setting operation, the set type is used as the type of the non-player character displayed at each position; in response to a quantity setting operation, the set quantity is used as the number of non-player characters displayed at each position; in response to an interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at each position.

[0155] In some embodiments, the determination module 5556 is further configured to cause the display module 5551 to perform at least one of the following processes for each position before displaying at least one non-player character at each position: in response to a type setting operation, using the set type as the type of the non-player character displayed at the position; in response to a quantity setting operation, using the set quantity as the number of non-player characters displayed at the position; in response to an interaction attribute setting operation, using the set interaction attribute as the interaction attribute of the non-player character displayed at the position.

[0156] In some embodiments, when at least one location belongs to different areas, the determination module 5556 is further used for the display module 5551 to perform at least one of the following processes for each area before displaying at least one non-player character at each location: in response to a type setting operation, the set type is used as the type of the non-player character displayed at the location belonging to the area; in response to a quantity setting operation, the set quantity is used as the number of non-player characters displayed at the location belonging to the area; in response to an interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at the location belonging to the area.

[0157] In some embodiments, the non-player character processing device 555 also includes a packaging module 5557 and a sending module 5558, wherein the packaging module 5557 is used to encapsulate at least one coordinate corresponding to at least one position into a configuration file; the sending module 5558 is used to send the configuration file to the server so that the server hot loads the configuration file to display at least one non-player character at each position.

[0158] In some embodiments, the encapsulation module 5557 is also used to obtain at least one coordinate corresponding to at least one position; send at least one coordinate to the chat box of the virtual scene; process at least one coordinate in the chat box into configuration data, and send the configuration data to a log file; and copy the coordinate information obtained based on keyword search in the log file to the configuration file.

[0159] It should be noted that the description of the device in the embodiment of the present application is similar to the description of the method embodiment described above, and has similar beneficial effects as the method embodiment, so it will not be repeated. Figure 3 , Figure 5A ,or Figure 5B The present invention should be understood by referring to the description of any one of the accompanying drawings.

[0160] The embodiment of the present application provides a computer program product, which includes a computer program or a computer executable instruction, and the computer program or the computer executable instruction is stored in a computer-readable storage medium. The processor of the computer device reads the computer executable instruction from the computer-readable storage medium, and the processor executes the computer executable instruction, so that the computer device executes the above-mentioned non-player character processing method of the embodiment of the present application.

[0161] The present application embodiment provides a computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, the processor will execute the non-player character processing method provided by the present application embodiment, for example, Figure 3 , Figure 5A ,or Figure 5B The processing method of non-player characters is shown.

[0162] 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 it may be various devices including one or any combination of the above memories.

[0163] In some embodiments, 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.

[0164] As an example, the 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 at multiple sites and interconnected by a communication network.

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

Claims

1. A method for processing a non-player character, characterized in that: The method comprises: Displaying a virtual scene in a human-computer interaction interface, wherein the virtual scene includes a first player character; In response to an operation of controlling the first player character to move in the virtual scene, at least one position is selected in the virtual scene, and at least one non-player character is displayed at each of the positions.

2. The method according to claim 1, characterized in that In response to the operation of controlling the first player character to move in the virtual scene, selecting at least one position in the virtual scene comprises: In response to an operation of controlling the first player character to move in the virtual scene, determining at least one position on the movement track of the first player character as at least one position selected in the virtual scene; or, In response to an operation of controlling the first player character to move in the virtual scene, at least one position is determined in a geometric area centered on the first player character after the movement to serve as at least one position selected in the virtual scene.

3. The method according to claim 2, characterized in that The step of determining at least one position on the moving track of the first player character as at least one position selected in the virtual scene includes: dividing the movement trajectory of the first player character into a plurality of trajectory segments; At least one position determined based on the plurality of trajectory segments is determined as at least one position selected in the virtual scene.

4. The method according to claim 3, characterized in that The step of dividing the movement trajectory of the first player character into a plurality of trajectory segments comprises: Perform one of the following actions: Dividing the movement trajectory of the first player character into a plurality of trajectory segments according to fixed lengths; Dividing the movement trajectory of the first player character into a plurality of trajectory segments according to a fixed duration; According to the number of areas passed by the first player character during the movement, the movement trajectory of the first player character is divided into a plurality of trajectory segments equal to the number.

5. The method according to claim 3, characterized in that: The step of determining at least one position determined based on the plurality of trajectory segments as at least one position selected in the virtual scene comprises: Perform one of the following actions: For each of the trajectory segments, determining at least one position on the trajectory segment as at least one position selected in the virtual scene; At least one target trajectory segment is determined from the multiple trajectory segments, and at least one position on the at least one target trajectory segment is determined as at least one position selected in the virtual scene.

6. The method according to claim 5, characterized in that The determining at least one target trajectory segment from the plurality of trajectory segments comprises: Perform at least one of the following: Determine at least one trajectory segment of the plurality of trajectory segments, the length of which is greater than a length threshold, as at least one target trajectory segment; Determining at least one selected trajectory segment from the plurality of trajectory segments as at least one target trajectory segment; At least one trajectory segment passing through a set area among the multiple trajectory segments is determined as at least one target trajectory segment.

7. The method according to any one of claims 1 to 6, characterized in that: In response to the operation of controlling the first player character to move in the virtual scene, selecting at least one position in the virtual scene comprises: In response to an operation of controlling the first player character to move in the virtual scene, at least one position around the movement track of the first player character is determined as at least one position selected in the virtual scene.

8. The method according to claim 7, characterized in that The step of determining at least one position around the moving track of the first player character as at least one position selected in the virtual scene includes: At least one position in the virtual scene that is closest to the moving track of the first player character and meets a display condition is determined as at least one position selected in the virtual scene, wherein the display condition includes at least one of the following: a display geographical condition and a display rule condition.

9. The method according to claim 8, characterized in that The step of determining at least one position in the virtual scene that is closest to the moving track of the first player character and satisfies a display condition as the at least one position selected in the virtual scene includes: Dividing the movement trajectory of the first player character into a plurality of trajectory segments, and determining at least one target trajectory segment from the plurality of trajectory segments; For each of the target trajectory segments, at least one position in the virtual scene that is closest to the target trajectory segment and satisfies a display condition is determined as the at least one position selected in the virtual scene.

10. The method according to claim 1, characterized in that The method further comprises: In response to the operation of updating the field of view of the first player character, at least one position within the updated field of view of the first player character is determined as at least one position selected in the virtual scene, and at least one non-player character is displayed at each of the positions.

11. The method according to claim 10, characterized in that The step of determining at least one position within the updated visual field of the first player character as at least one position selected in the virtual scene comprises: At least one position within the updated visual field of the first player character and in a direction corresponding to the current orientation of the first player character is determined as at least one position selected in the virtual scene.

12. The method according to claim 1, characterized in that The method further comprises: In response to an operation of controlling the first player character to launch at least one virtual missile in the virtual scene, at least one landing point corresponding to the at least one virtual missile in the virtual scene is determined as at least one position selected in the virtual scene, and at least one non-player character is displayed at each of the positions.

13. The method according to claim 1, characterized in that Before responding to an operation of controlling the first player character to move in the virtual scene, the method further includes: Perform one of the following actions: In response to the first player character completing a set task in the virtual scene, controlling the first player character to enter a specified state; In response to the second player character releasing a set skill for the first player character, controlling the first player character to enter a specified state; The designated state is a state in which a non-player character is displayed at a position selected based on the first player character.

14. The method according to claim 1, characterized in that After selecting at least one position in the virtual scene, the method further comprises: Displaying a corresponding location marker at each of the locations; In response to a triggering operation on any of the position markers, the triggered position marker is cancelled from display, and the position corresponding to the triggered position marker is switched from a selected state to an unselected state.

15. The method according to claim 1, characterized in that Prior to displaying at least one non-player character at each of the locations, the method further comprises: Perform at least one of the following: In response to the type setting operation, using the set type as the type of the non-player character displayed at each of the positions; In response to the quantity setting operation, setting the set quantity as the number of non-player characters displayed at each of the positions; In response to the interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at each of the positions.

16. The method according to claim 1, characterized in that Prior to displaying at least one non-player character at each of the locations, the method further comprises: For each of the positions, at least one of the following processes is performed: In response to the type setting operation, using the set type as the type of the non-player character displayed at the position; In response to the quantity setting operation, setting the set quantity as the number of non-player characters displayed at the position; In response to the interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at the position.

17. The method according to claim 1, characterized in that When the at least one location belongs to a different area, before displaying at least one non-player character at each of the locations, the method further includes: For each of the regions, at least one of the following processes is performed: In response to the type setting operation, using the set type as the type of the non-player character displayed at the position belonging to the area; In response to the number setting operation, setting the set number as the number of non-player characters displayed at the positions belonging to the area; In response to the interaction attribute setting operation, the set interaction attribute is used as the interaction attribute of the non-player character displayed at the position belonging to the area.

18. The method according to claim 1, characterized in that The step of displaying at least one non-player character at each of the locations comprises: Encapsulating at least one coordinate corresponding to each of the at least one position into a configuration file; The configuration file is sent to a server so that the server hot loads the configuration file to display at least one non-player character at each of the locations.

19. The method according to claim 18, characterized in that The step of packaging at least one coordinate corresponding to the at least one position into a configuration file includes: Obtain at least one coordinate corresponding to each of the at least one position; sending the at least one coordinate to a chat box of the virtual scene; processing the at least one coordinate in the chat box into configuration data, and sending the configuration data into a log file; The coordinate information obtained based on the keyword search in the log file is copied to the configuration file.

20. A processing device for a non-player character, characterized in that: The device comprises: A display module, used for displaying a virtual scene in a human-computer interaction interface, wherein the virtual scene includes a first player character; a selection module, configured to select at least one position in the virtual scene in response to an operation of controlling the first player character to move in the virtual scene; The display module is further used to display at least one non-player character at each of the positions.

21. An electronic device, characterized in that: include: A memory for storing executable instructions; The processor is configured to implement the method for processing a non-player character according to any one of claims 1 to 19 when executing the executable instructions stored in the memory.

22. A computer-readable storage medium storing computer-executable instructions, characterized in that: When the computer executable instructions are executed by a processor, the method for processing a non-player character according to any one of claims 1 to 19 is implemented.

23. A computer program product comprising a computer program or computer executable instructions, characterized in that When the computer program or computer executable instructions are executed by a processor, the method for processing a non-player character according to any one of claims 1 to 19 is implemented.