A virtual map processing method, device, equipment, computer readable storage medium and computer program product
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- TENCENT TECHNOLOGY (SHENZHEN) CO LTD
- Filing Date
- 2025-02-05
- Publication Date
- 2026-08-07
AI Technical Summary
而当玩家玩多了该游戏后,会逐渐发现最佳探索路线,使得游戏过程变得套路化,玩家会逐渐失去游玩的新鲜感,降低了游戏的用户粘性
[0037]应用本申请实施例,在虚拟地图的渲染或生成应用中,将与渲染虚拟地图所需的环境场景相对应的交互场景划分为多个级别的子场景,以环境场景(如海洋、沙漠、森林等)为虚拟地图的环境载体,环境场景为虚拟地图提供了统一的背景和氛围,增强了游戏的沉浸感;子场景根据环境场景而生成,并与环境场景无缝连接,提升了虚拟地图的真实感和一致性;根据子场景的级别生成相应的虚拟角色、虚拟物资和撤离区域,这种级别化的生成方式不仅避免了资源浪费,使得每次游戏的地图布局和内容都会有所不同,增加了游戏的多样性和可玩性,还可基于这种模块化和游戏需求进行灵活调整,适用多种地图风格和玩法模式,具有较好的可扩展性与灵活性;不同级别的子场景对应不同的资源丰富度和挑战难度,故通过子场景级别化为玩家提供了多样化的探索和策略选择。即本方案通过动态生成、级别化设计、资源管理和玩家交互等多方面的优化,提供了高度多样性、沉浸感和策略深度的游戏体验;同时,模块化的设计和可扩展性使其适用于多种游戏类型和玩法模式,具有广泛的应用前景。
Smart Images

Figure CN122516601A_ABST
Abstract
Description
Technical Field
[0001] This application relates to computer technology, and more particularly to a method, apparatus, device, storage medium, and program product for processing virtual maps. Background Technology
[0002] In most evacuation-themed games nowadays, the game map... Figure 1 Generally, these spawn points are fixed. Players have fixed spawn points, extraction points, and resource points each time they play. For example, multiple spawn points are usually pre-set around the perimeter of the game map. During gameplay, player characters are randomly generated from some of these spawn points. The players then explore the map while moving towards extraction points. The number of extraction points is usually very small, the purpose being to create overlapping extraction routes, leading to encounters and strategic maneuvering between players. However, as players play the game more, they gradually discover the optimal exploration routes, making the gameplay routine and causing players to lose interest and reduce user engagement. Summary of the Invention
[0003] This application provides a method, apparatus, electronic device, computer-readable storage medium, and computer program product for processing virtual maps, which can improve the randomness and novelty of virtual map generation, thereby increasing user stickiness.
[0004] The technical solution of this application embodiment is implemented as follows:
[0005] This application provides a method for processing virtual maps, including:
[0006] In response to a rendering request for a virtual map, determine the environmental scene required to render the virtual map, and multiple levels of sub-scenes corresponding to the environmental scene;
[0007] The environment scene is rendered using the environment scene as the environment carrier of the virtual map, and the corresponding level of the sub-scene is generated in the sub-region corresponding to the level of each sub-scene in the environment scene;
[0008] In the first sub-scene of each of the generated sub-scenes, virtual characters are generated; in the second sub-scene, virtual resources are generated; and in the third sub-scene, an evacuation area is generated.
[0009] In response to a control operation on the virtual character, the virtual character is controlled to collect the virtual resources, and when the evacuation conditions are met, the virtual character is controlled to evacuate to the evacuation area with the virtual resources.
[0010] This application provides a virtual map processing apparatus, comprising:
[0011] The determination module is used to determine, in response to a rendering request for a virtual map, the environmental scene required to render the virtual map, and multiple levels of sub-scenes corresponding to the environmental scene.
[0012] The first rendering module is used to render the environment scene as the environment carrier of the virtual map, and generate the sub-scene of the corresponding level in the sub-region corresponding to the level of each sub-scene in the environment scene;
[0013] The second rendering module is used to generate virtual characters in the first sub-scene of each of the generated sub-scenes, virtual resources in the second sub-scene, and evacuation areas in the third sub-scene.
[0014] The control module is configured to respond to control operations on the virtual character, control the virtual character to collect the virtual resources, and control the virtual character to evacuate to the evacuation area with the virtual resources when the evacuation conditions are met.
[0015] In the above scheme, the determining module is further configured to, in response to the presence of multiple candidate environment scenes associated with the virtual map, display a scene selection interface, wherein the scene selection interface includes at least two candidate environment scenes; and, in response to the scene selection operation, determine the selected candidate environment scene as the environment scene required for rendering the virtual map.
[0016] In the above scheme, the determining module is further configured to, in response to the presence of multiple candidate environment scenarios associated with the virtual map, call a neural network model to predict the usage probability of each candidate environment scenario based on the influencing factors affecting the use of each candidate environment scenario, and determine the candidate environment scenario with the highest usage probability as the environment scenario required for rendering the virtual map; wherein, the influencing factors include at least one of the following: historical usage rate, feedback information, resources required to render the candidate environment scenario, and the matching degree between the account characteristics of the target account that triggered the rendering request and the scene characteristics of the candidate environment scenario; the neural network model is trained in the following way: based on the influencing factors of the environment scenario samples, the neural network model is called to predict the probability of using the environment scenario samples, and backpropagation is performed based on the difference between the probability of using the environment scenario samples and the label of the actual usage result to update the parameters of the neural network model.
[0017] In the above scheme, the first rendering module is further configured to obtain a first number of pre-marked generation coordinate points in the model of the environment scene, and select a second number of generation coordinate points from the first number of generation coordinate points, each of the generation coordinate points being assigned a level; for each of the second number of generation coordinate points, in the sub-region corresponding to the generation coordinate point, a sub-scene corresponding to a level matching the level assigned to the generation coordinate point is generated, and the sub-scene is rotated with the vertical direction of the sub-region as the central axis.
[0018] In the above scheme, the first rendering module is further configured to generate sub-scenes of corresponding levels in each of the sub-regions in such a way that the closer the sub-region is to the center of the environment scene, the higher the level of the sub-scene generated in the sub-region.
[0019] In the above scheme, the first rendering module is further configured to select a third number of sub-regions from each sub-region in the environment scene, and form the third number of sub-regions into a resource-rich area; generate sub-scenes with a level higher than the level threshold in the resource-rich area, and randomly generate sub-scenes with a level lower than the level threshold in other sub-regions in the environment scene other than the resource-rich area.
[0020] In the above scheme, the first rendering module is further configured to set the resource richness gradient of each sub-region along the target direction of the environment scene; and generate sub-scenes of corresponding levels in each sub-region in such a way that the higher the resource richness, the higher the level of the sub-scene generated in the corresponding gradient sub-region.
[0021] In the above scheme, the first rendering module is further configured to respond to the exploration path set in the environment scene, and sequentially generate sub-scenes of corresponding levels in each of the sub-regions traversed by the exploration path along the exploration direction of the exploration path; wherein, the sub-scenes generated in the sub-region at the starting point of the exploration path have the lowest level, and the sub-scenes generated in the sub-region at the ending point of the exploration path have the highest level.
[0022] In the above scheme, the first rendering module is further configured to determine the matching degree between the terrain features of each sub-region and the level of each sub-scene; and generate sub-scenes corresponding to the levels in each sub-region where the matching degree exceeds the matching degree threshold.
[0023] In the above scheme, the second rendering module is further configured to determine a first sub-scene, a second sub-scene, and a third sub-scene in each of the generated sub-scenes; determine a preset character spawn point in the first sub-scene, a preset resource generation point in the second sub-scene, and a preset evacuation point in the third sub-scene; generate a virtual character at the character spawn point in the first sub-scene, generate virtual resources at the resource generation point in the second sub-scene, and generate an evacuation area at the evacuation point in the third sub-scene.
[0024] In the above scheme, the second rendering module is further configured to respond to the fact that there are multiple preset character spawn points in the first sub-scene, select a fifth number of character spawn points from the multiple character spawn points, and generate virtual characters at each of the fifth number of character spawn points; wherein, the distance between the virtual characters generated from different character spawn points is greater than a distance threshold, and the orientation of the virtual characters is the direction of the virtual supplies or the direction of the evacuation point.
[0025] In the above scheme, the second rendering module is further configured to determine the fourth quantity and target category of virtual materials corresponding to the level in the second sub-scene; select the fourth quantity of material generation points from the preset material generation points in the second sub-scene; and generate virtual materials of the target category at each of the material generation points in the fourth quantity of material generation points.
[0026] In the above scheme, after generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene, the device further includes: an indication module, used to display level indication information for each sub-scene in the virtual map in response to a viewing operation of the virtual map; wherein the level indication information is used to indicate the level of the sub-scene, and the level is used to indicate the resource abundance of the sub-scene.
[0027] In the above scheme, the device further includes: an adjustment module, used to determine the interaction progress of the virtual character in the virtual map during the process of controlling the virtual character to collect the virtual resources, or during the process of controlling the virtual character to evacuate to the evacuation area; and as the interaction progresses, adjusting the distribution probability of each sub-scene in the virtual map according to the interaction progress, so that the adjusted distribution probability matches the interaction progress.
[0028] In the above scheme, the control module is further configured to, in response to a control operation on the virtual character, control the virtual character to move towards the virtual resource; during the movement of the virtual character, in response to the presence of other virtual characters in the sub-scene where the virtual character is located, control the virtual character to engage in combat interaction with the other virtual characters; in response to the absence of other virtual characters in the sub-scene where the virtual character is located, generate a non-player character with a target combat strength in the sub-scene where the virtual character is located, and control the virtual character to engage in combat interaction with the non-player character; wherein, the other virtual characters and the non-player character are used to prevent the virtual character from collecting the virtual resource, and the target combat strength corresponds to the level of the sub-scene where the virtual character is located; in response to the virtual character moving to the location of the virtual resource, control the virtual character to pick up the virtual resource.
[0029] In the above scheme, the control module is further configured to respond to the fact that there are multiple preset non-player character generation points in the sub-region where the virtual character is located, and to select a sixth number of generation points from the multiple generation points; to generate non-player characters at each of the sixth number of generation points, wherein the difference between the sum of the combat strength of the non-player characters generated at the sixth number of generation points and the target combat strength is lower than the difference threshold.
[0030] In the above scheme, the device further includes: a clearing module, used to clear the non-player character in response to the virtual character leaving the sub-scene.
[0031] This application provides an electronic device, including:
[0032] Memory is used to store executable instructions or computer programs.
[0033] The processor is configured to execute computer-executable instructions or computer programs stored in the memory to implement the virtual map processing method provided in the embodiments of this application.
[0034] This application provides a computer-readable storage medium storing computer-executable instructions or computer programs for implementing the virtual map processing method provided in this application when executed by a processor.
[0035] This application provides a computer program product, including a computer program or computer executable instructions. When the computer program or computer executable instructions are executed by a processor, they implement the virtual map processing method provided in this application.
[0036] The embodiments of this application have the following beneficial effects:
[0037] In the application of this invention, in the rendering or generation of virtual maps, the interactive scene corresponding to the environmental scene required for rendering the virtual map is divided into multiple levels of sub-scenes. The environmental scene (such as ocean, desert, forest, etc.) serves as the environmental carrier of the virtual map, providing a unified background and atmosphere, enhancing the game's immersion. Sub-scenes are generated based on the environmental scene and seamlessly connected to it, improving the realism and consistency of the virtual map. Corresponding virtual characters, virtual resources, and evacuation areas are generated according to the level of the sub-scene. This hierarchical generation method not only avoids resource waste, ensuring that the map layout and content differ each time the game is played, increasing the game's diversity and playability, but also allows for flexible adjustments based on this modularity and game requirements, suitable for various map styles and gameplay modes, exhibiting good scalability and flexibility. Different levels of sub-scenes correspond to different resource richness and challenge levels, thus providing players with diverse exploration and strategic choices through sub-scene hierarchies. This solution provides a highly diverse, immersive, and strategically deep gaming experience through optimizations in dynamic generation, hierarchical design, resource management, and player interaction. Furthermore, its modular design and scalability make it suitable for various game genres and gameplay modes, offering broad application prospects. Attached Figure Description
[0038] Figure 1 This is a schematic diagram of the architecture of the virtual map processing system 100 provided in an embodiment of this application;
[0039] Figure 2 This is a schematic diagram of the structure of the electronic device 500 provided in the embodiments of this application;
[0040] Figure 3 This is a flowchart illustrating the virtual map processing method provided in an embodiment of this application;
[0041] Figure 4 This is a schematic diagram illustrating the structure of the virtual map provided in the embodiments of this application;
[0042] Figure 5 This is a schematic diagram of a sub-scenario provided in an embodiment of this application;
[0043] Figure 6 This is a schematic diagram illustrating the generation of a player character provided in an embodiment of this application;
[0044] Figure 7 This is a schematic diagram showing the orientation of the player character provided in an embodiment of this application;
[0045] Figure 8 This is a flowchart illustrating the virtual map processing method provided in the embodiments of this application. Detailed Implementation
[0046] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0047] It is understood that in the embodiments of this application, data such as user information are involved. When the embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with relevant laws, regulations and standards.
[0048] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0049] In the following description, the terms “first, second…” are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that “first, second…” may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.
[0050] In this application embodiment, the terms "module" or "unit" refer to a computer program or part of a computer program that has a predetermined function and works with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.
[0051] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.
[0052] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.
[0053] 1) Client: An application that runs on a terminal and provides various services, such as a video playback client or a game client.
[0054] 2) In response, used to indicate the conditions or states on which the operation performed depends. When the conditions or states on which it depends are met, one or more operations performed may be performed in real time or with a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations are performed.
[0055] 3) A virtual scene is a virtual scene displayed (or provided) by an application when it runs on a terminal. This virtual scene can be a simulation of the real world, a semi-simulated / semi-fictional virtual environment, or a purely fictional virtual environment. A virtual scene can be any of a two-dimensional, 2.5-dimensional, or three-dimensional virtual scene; this application does not limit the dimension of the virtual scene. For example, the virtual scene may include sky, land, ocean, etc., and the land may include environmental elements such as deserts and cities. The user can control a virtual character to move within this virtual scene.
[0056] 4) Virtual characters: These are interactive images of people and objects within a virtual scene, or movable objects within that scene. These movable objects can be virtual characters, virtual animals, anime characters, etc., such as people or animals displayed in a virtual scene. A virtual character can be a virtual avatar representing the user within that scene. A virtual scene can include multiple virtual characters, each with its own shape and volume, occupying a portion of the virtual scene's space. Virtual characters can also be game characters controlled by the user (or player).
[0057] This application provides a method, apparatus, electronic device, computer-readable storage medium, and computer program product for processing virtual maps, which can improve the randomness and novelty of virtual map generation, thereby increasing user stickiness. The following describes exemplary applications of the electronic device provided in this application. The electronic device provided in this application can be implemented as various types of user terminals such as laptops, tablets, desktop computers, set-top boxes, mobile devices (e.g., mobile phones, portable music players, personal digital assistants, dedicated messaging devices, portable gaming devices), smartphones, smart speakers, smartwatches, smart TVs, in-vehicle terminals, augmented reality (AR) devices, and virtual reality (VR) devices, or it can be implemented as a server. The following will describe exemplary applications when the device is implemented as a terminal.
[0058] See Figure 1 , Figure 1This is a schematic diagram of the architecture of the virtual map processing system 100 provided in the embodiments of this application. In order to support an exemplary application, the terminal (terminal 400-1 and terminal 400-2 are shown as examples) connects to the server 200 through the network 300. The network 300 can be a wide area network or a local area network, or a combination of the two.
[0059] In some embodiments, the terminal is equipped with a client that has virtual map processing capabilities, such as a video playback client, instant messaging client, game client, live streaming client, etc. Server 200 is the backend server corresponding to the client; it can be an independent physical server, a server cluster consisting of multiple physical servers, or a distributed system. The terminal and the server can be directly or indirectly connected via wired or wireless communication, which is not limited in this embodiment.
[0060] In practical applications, when a player logs into and launches the client in the terminal, or switches scenes in the client, a rendering request for the virtual map is triggered. The terminal sends this rendering request to the server 200. Based on the rendering request, the server 200 determines the environmental scene required to render the virtual map, as well as multiple levels of sub-scenes corresponding to the environmental scene, and returns them to the terminal. The terminal renders the environmental scene using the environmental scene as the environmental carrier of the virtual map, and generates sub-scenes of corresponding levels in the sub-regions corresponding to the levels of each sub-scene in the environmental scene. Virtual characters are generated in the first sub-scene of each of the generated sub-scenes, virtual resources are generated in the second sub-scene, and an evacuation area is generated in the third sub-scene. In response to the control operation on the virtual character, the virtual character is controlled to collect virtual resources, and when the evacuation conditions are met, the virtual character is controlled to evacuate to the evacuation area with the virtual resources.
[0061] See Figure 2 , Figure 2 This is a schematic diagram of the structure of the electronic device 500 provided in the embodiments of this application, with the electronic device 500 as an example. Figure 1 Taking the terminal in the middle as an example, Figure 2 The illustrated electronic device 500 includes at least one processor 510, a memory 550, at least one network interface 520, and a user interface 530. The various components in the electronic device 500 are coupled together via a bus system 540. It is understood that the bus system 540 is used to implement communication between these components. In addition to a data bus, the bus system 540 also includes a power bus, a control bus, and a status signal bus. However, for clarity, ... Figure 2 The general labeled all buses as Bus System 540.
[0062] The processor 510 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc.
[0063] Memory 550 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), and the volatile memory may be random access memory (RAM). The memory 550 described in this application embodiment is intended to include any suitable type of memory. Memory 550 may optionally include one or more storage devices physically located away from processor 510.
[0064] In some embodiments, memory 550 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, as illustrated below.
[0065] Operating system 551 includes system programs for handling various basic system services and performing hardware-related tasks, such as framework layer, core library layer, driver layer, etc., for implementing various basic business functions and handling hardware-based tasks; network communication module 552 is used to reach other electronic devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 include: Bluetooth, WiFi, and Universal Serial Bus (USB), etc.
[0066] In some embodiments, the virtual map processing apparatus provided in this application can be implemented in software. The virtual map processing apparatus provided in this application can be provided in various software embodiments, including various forms such as applications, software, software modules, scripts or code. Figure 2 A processing device 555 for a virtual map stored in memory 550 is shown. It may be software in the form of programs and plug-ins, and includes a series of modules, including a determination module 5551, a first rendering module 5552, a second rendering module 5553, and a control module 5554. These modules are logically related and can therefore be arbitrarily combined or further divided according to the functions they implement. The functions of each module will be described below.
[0067] In other embodiments, the apparatus provided in this application can be implemented in hardware. As an example, the apparatus provided in this application can be a processor in the form of a hardware decoding processor, which is programmed to execute the virtual map processing method provided in this application. For example, the processor in the form of a hardware decoding processor can be one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), or other electronic components.
[0068] In some embodiments, the terminal or server can implement the virtual map processing method provided in this application by running various computer-executable instructions or computer programs. For example, computer-executable instructions can be microprogram-level commands, machine instructions, or software instructions. Computer programs can be native programs or software modules in an operating system; they can be native applications (APPs), i.e., programs that need to be installed in the operating system to run, such as instant messaging APPs or live streaming APPs; or they can be applets that can be embedded in any APP, i.e., programs that only need to be downloaded to a browser environment to run. In summary, the aforementioned computer-executable instructions can be any form of instruction, and the aforementioned computer programs can be any form of application, module, or plugin.
[0069] As mentioned above, the virtual map processing method provided in this application embodiment can be implemented by various types of electronic devices, such as... Figure 1 Either the terminal or the server 200 can be executed independently, or it can be... Figure 1 The terminal and server 200 in the process work together. Next, [the process will be carried out by...] Figure 1 The following description uses an example of a terminal executing the virtual map processing method provided in this application embodiment. See also... Figure 3 , Figure 3 This is a flowchart illustrating the virtual map processing method provided in this application embodiment, which will be combined with... Figure 3 The steps shown are explained.
[0070] Step 101: In response to the rendering request for the virtual map, the terminal determines the environmental scene required to render the virtual map, as well as multiple levels of sub-scenes corresponding to the environmental scene.
[0071] In practical applications, rendering requests are also called map update requests. They are used to request rendering of virtual maps (such as game spaces for players to fight in a game, such as battlefields) or to request updates to virtual maps. These can be real-time map update requests triggered when players move, explore, or interact in a virtual scene. They can also be map update requests automatically triggered by the system when players complete a specific event (such as unlocking a new area) or reach a specific progress in a virtual scene. They can also be periodic map update tasks set in a virtual scene. This application does not limit the source or triggering method of rendering requests.
[0072] The virtual map, in this context, describes the spatial layout and environment of a virtual scene. It serves as the area for players to explore, interact, and engage in activities, providing spatial support for events, tasks, and gameplay within the virtual scene. The core function of a virtual scene is to provide users with an immersive visual and interactive experience, allowing them to control virtual characters to move, explore, and interact within the scene; thus, virtual scenes emphasize visual presentation (such as 3D rendering and lighting effects). The core function of the virtual map is to provide spatial information support, helping users understand the structure and layout of the virtual scene and supporting task allocation and gameplay design; thus, virtual maps emphasize spatial structure and logical relationships (such as top-down views, grid maps, and path planning).
[0073] It should be noted that if both visual experience and spatial logic support are required simultaneously (such as in games and virtual reality applications), then virtual scenes and virtual maps can be strictly distinguished. For example, in games, virtual scenes are used to render the visuals seen by the player, while virtual maps are used to support logical functions such as task systems and path planning. If the required functionality is relatively simple and the boundary between virtual scenes and virtual maps is blurred (such as in some simple 2D games or educational applications), then a strict distinction is not necessary. In practical applications, the relationship between the two can be flexibly handled according to specific needs. For example, a virtual map can serve as an abstract representation of a virtual scene, or virtual maps and virtual scenes can share the same data model to maintain data consistency while separately meeting the needs of visual presentation and logical functionality.
[0074] In response to a rendering request, the terminal first determines the environment scene (i.e., the model corresponding to the environment scene) required for rendering the virtual map, and the sub-scenes (i.e., the models corresponding to the sub-scenes) corresponding to the environment scene. The environment scene is the environmental carrier of the virtual map or each sub-scene, used to hold and connect the sub-scenes. The category of the sub-scene corresponds to the environment scene. For example, if the ocean is the environment scene, sub-scenes can be distributed on islands within the ocean. Similarly, in a forest environment scene, sub-scenes of trees can be generated, but not sub-scenes of tall buildings. There can be multiple sub-scenes in terms of both number and level. The number of sub-scenes can be set according to actual needs. Different levels of sub-scenes have different attributes, reflecting differences in resource richness, enemy density, terrain complexity, and challenge difficulty. For example, based on resource richness, sub-scenes can be divided into five levels: S, A, B, C, and D. Higher-level sub-scenes contain richer virtual resources and have stronger hostile non-player characters (NPCs). Each sub-scene is part of a virtual map, with a fixed size and specific content. Sub-scenes are connected by entrances and exits, ensuring that players can move seamlessly between different sub-scenes. All sub-scenes are pieced together to form a complete virtual map, which in turn forms a logically coherent and complete game space.
[0075] See Figure 4 , Figure 4 This is a schematic diagram of the virtual map provided in the embodiments of this application. Assuming that the environment scene (also known as the empty scene) of the virtual map (i.e. the game space, such as the battlefield) is the sea, it is composed of 25 sub-scenes (i.e., modular scenes) of 200 meters × 200 meters. Then, the entire battlefield can be regarded as being composed of 25 sub-scenes of 200 meters × 200 meters distributed in the sea.
[0076] See Figure 5 , Figure 5 This is a schematic diagram of the sub-scenes provided in the embodiments of this application. Each sub-scene is an independent space with a fixed size (such as a square area of 200 meters × 200 meters). The sub-scenes contain specific terrain and environmental elements (such as buildings), character spawn points (i.e., player spawn points, used to generate virtual characters), resource spawn points (used to generate virtual resources), non-player character spawn points (i.e., non-player spawn points, used to generate non-player characters), extraction points (used to generate extraction areas), and other elements. Each sub-scene has independent functions. The sub-scenes are seamlessly connected through entrances and exits to form a logically coherent battlefield. Players can move between different sub-scenes, explore resources, fight enemies, and plan extraction routes.
[0077] The modular map design described above not only enables the modular generation of virtual maps, maintaining their logical coherence and enhancing the player's exploration experience, but also allows players to become familiar with the basic layout and characteristics of each sub-scene, rather than memorizing the details of the entire virtual map, as the virtual map is composed of modular sub-scenes. Furthermore, by combining different sub-scenes, different virtual maps can be generated. This design reduces the learning curve for players while maintaining a sense of novelty in each game. It can also be flexibly adjusted based on game needs, adapting to various map styles and gameplay modes, and exhibits good scalability and flexibility.
[0078] In some embodiments, the terminal may determine the environmental scene required for rendering the virtual map in the following manner: in response to the presence of multiple candidate environmental scenes associated with the virtual map, a scene selection interface is displayed, which includes at least two candidate environmental scenes; in response to the scene selection operation, the selected candidate environmental scene is determined as the environmental scene required for rendering the virtual map.
[0079] In practical applications, for a virtual map, multiple candidate environment scenarios can be preset and configured, such as ocean, forest, and mountains. Different sub-scenes can be generated in different candidate environment scenarios. For example, in the ocean candidate environment scenario, ocean-related sub-scenes (such as islands) can be generated, and in the forest candidate environment scenario, forest-related sub-scenes (such as vegetation) can be generated. In other words, for a game, different candidate environment scenarios can be preset and configured, and players can play in the game map under different candidate environment scenarios.
[0080] Here, in response to a rendering request for a virtual map, the terminal first obtains the candidate environment scenes associated with the virtual map. When there are multiple candidate environment scenes associated with the virtual map, a scene selection interface can pop up for the player to select the desired environment scene. For example, the scene selection interface can display candidate environment scene 1, candidate environment scene 2, and candidate environment scene 3. When the player selects candidate environment scene 2, the selected candidate environment scene can be determined as the environment scene required for rendering the virtual map. In this way, the player's initiative in rendering the map can be improved, and the targeting of the environment scene used for rendering the virtual map can be improved.
[0081] In some embodiments, the terminal may determine the environmental scene required for rendering the virtual map in the following manner: In response to the existence of multiple candidate environmental scenes associated with the virtual map, based on the influencing factors affecting the use of each candidate environmental scene, a neural network model is invoked to predict the usage probability of each candidate environmental scene, and the candidate environmental scene with the highest usage probability is determined as the environmental scene required for rendering the virtual map; wherein, the influencing factors include at least one of the following: historical usage rate, feedback information, resources required for rendering the candidate environmental scene, and the matching degree between the account characteristics of the target account that triggered the rendering request and the scene characteristics of the candidate environmental scene; the neural network model is trained in the following manner: based on the influencing factors of the environmental scene samples, the neural network model is invoked to predict the probability of using the environmental scene samples, and backpropagation is performed based on the difference between the probability of using the environmental scene samples and the label of the actual usage result to update the parameters of the neural network model.
[0082] In practical applications, when there are multiple candidate environmental scenarios associated with the virtual map, the terminal can also obtain influencing factors that affect the use of each candidate environmental scenario. For example, the influencing factor can be the historical usage rate of the candidate environmental scenario (i.e., the probability that the candidate environmental scenario has been used in the past period of time). The higher the historical usage rate, the more popular the environmental scenario is with players. However, this also reflects to some extent the fixity of players' past use of environmental scenarios, which makes it easy to lose interest. The influencing factor can also include player feedback information. The so-called feedback information is the feedback and evaluation of players on the candidate environmental scenarios they use. Therefore, when recommending candidate environmental scenarios to players, it is necessary to balance between player preference and novelty, and to combine feedback information to try to recommend environmental scenarios that are both popular and novel to players.
[0083] The influencing factor may also include the resources required to render candidate environment scenes. The resources required to render different candidate environment scenes are usually different, including art resources, technical resources, computational resources, and storage resources. Art resources are the core of virtual scene rendering and mainly include model resources, texture resources, material resources, environment resources, and special effects resources. Model resources include 3D models (the 3D models corresponding to virtual objects such as virtual characters and virtual materials in the virtual scene), detail models (models at different levels of detail, used to optimize rendering performance), and simplified collider models for physical collision detection. Texture resources include diffuse maps (representing the color and pattern of virtual object surfaces), normal maps (used to simulate the lighting effects of virtual object surface details), specular maps (used to control the reflection intensity of virtual object surfaces), ambient occlusion maps (used to simulate the shadow details of virtual object surfaces), metallic maps (used to control the metallic texture of virtual objects), and roughness maps (used to control the smoothness of virtual object surfaces). Material resources describe parameters (such as metallicity and roughness) of how object surfaces interact with light. Environment resources are used to render environment scenes, such as skyboxes used to render the sky or background in a virtual map. Special effects resources are used to render effects such as fire, smoke, and explosions in the virtual map. Technical resources are the underlying tools and frameworks supporting virtual map rendering, including the rendering engine, rendering pipeline, and lighting system. Computational resources are the hardware and performance support required for rendering the virtual map, including Graphics Processing Unit (GPU) resources (used to store textures, models, and buffers, and to execute shaders, lighting calculations, and post-processing), Central Processing Unit (CPU) resources (used for logical calculations such as physics simulation, animation calculations, and AI logic, as well as rendering scheduling such as submitting rendering commands and managing resources), memory resources (used to store loaded scene data and intermediate calculation results), and storage resources (storage media used to save and manage rendering-related data, such as hard drives, resource packs, and cloud resources). When recommending candidate environment scenes, it is necessary to consider the different resources required to render different candidate environment scenes, striving to recommend visually appealing and high-performance game environment scenes to players.
[0084] The influencing factors can also include the matching degree between the account characteristics of the target account that triggered the rendering request (such as the player's interests, gender, age, account level, and preferred interaction methods) and the scene characteristics of the candidate environment scene (such as scene category and scene elements). The greater the matching degree, the greater the probability of using the candidate environment scene. After determining the influencing factors that affect the use of each candidate environment scene, the influencing factors are input into a trained neural network model for prediction processing to obtain the usage probability of each candidate environment scene, which makes the prediction more accurate. After determining the usage probability of each candidate environment scene, the candidate environment scene with the highest usage probability can be determined as the environment scene required for rendering the virtual map.
[0085] Before applying a neural network model, an initial neural network model needs to be trained. This trained model is then put into application to combine influencing parameters and use artificial intelligence to predict the usage probability of candidate environmental scenarios. The neural network model is trained using the influencing factors of environmental scenario samples and the usage probabilities of labeled environmental scenario samples. For example, based on environmental scenario samples, feedback information associated with environmental scenario samples, and the usage probabilities of labeled environmental scenario samples, the initial neural network model is invoked for prediction processing to obtain the predicted usage probabilities. After determining the value of the loss function of the neural network model using the predicted and labeled usage probabilities, it can be determined whether the value of the loss function exceeds a preset threshold. When the value of the loss function exceeds the preset threshold, an error signal is determined based on the loss function. This error signal is then backpropagated within the neural network model, updating the model parameters of each layer during the propagation process.
[0086] The embodiments of this application do not limit the model structure of the neural network model. For example, the neural network model can be a convolutional neural network, a deep neural network, etc.; nor are they limited to the form of the loss function. For example, it can be a cross-entropy loss function, an L2 loss function, etc.
[0087] Here, we explain backpropagation. Training sample data is input into the input layer of the neural network model, passes through the hidden layers, and finally reaches the output layer to output the result. This is the forward propagation process of the neural network model. Since there is an error between the output result of the neural network model and the actual result, the error between the output result and the actual value is calculated and backpropagated from the output layer to the hidden layers until it reaches the input layer. During the backpropagation process, the values of the model parameters are adjusted according to the error. That is, a loss function is constructed based on the error between the output result and the actual value, and the partial derivatives of the loss function with respect to the model parameters are calculated layer by layer to generate the gradient of the loss function with respect to the model parameters of each layer. Since the direction of the gradient indicates the direction of error amplification, the gradient of the model parameters is inverted and summed with the original parameters of each layer of the model. The summation result is used as the updated model parameters of each layer, thereby reducing the error caused by the model parameters. The above process is iterated until convergence.
[0088] Step 102: Render the environment scene using the environment scene as the environment carrier of the virtual map, and generate sub-scenes of the corresponding level in the sub-regions corresponding to the levels of each sub-scene in the environment scene.
[0089] In practical applications, after the terminal determines the environmental scene (i.e., the model corresponding to the environmental scene) required for rendering the virtual map, it renders the environmental scene as the environmental carrier of the virtual map. This involves rendering the model of the environmental scene to obtain a visualized 3D environment. For example, when the environmental scene is a model of an ocean, the ocean model is rendered to obtain a 3D ocean, which is then used as the environmental carrier or background of the virtual map. After rendering the environmental scene of the virtual map, multiple sub-scenes can be randomly placed within it to increase the randomness of virtual map generation. However, since different sub-scenes can have different levels, and there may be multiple sub-scenes of the same level, when generating sub-scenes within the environmental scene, the level of the sub-scene can be considered. Sub-scenes of the corresponding level can be randomly generated in sub-regions or locations within the environmental scene to increase the randomness of virtual map generation while providing players with diverse exploration and strategic choices through sub-scene hierarchy.
[0090] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environment scene in the following manner: obtaining a first number of pre-marked generation coordinate points in the model of the environment scene, and selecting a second number of generation coordinate points from the first number of generation coordinate points, each generation coordinate point being assigned a level; for each generation coordinate point in the second number of generation coordinate points, generating a sub-scene corresponding to a level that matches the level assigned to the generation coordinate point in the sub-region corresponding to the generation coordinate point, and rotating the sub-scene with the vertical direction of the sub-region as the central axis.
[0091] In practical applications, when setting up the environment scene model, a first number of generation coordinate points for placing sub-scenes are usually marked in the environment scene model. In the initial rendering stage, some sub-scenes can be rendered in the environment scene first to improve rendering efficiency and ensure smooth interaction in the virtual scene. When rendering some sub-scenes, a second number (less than the first number) of generation coordinate points can be selected from the first number. Then, for each of the second number of generation coordinate points, sub-scenes corresponding to the level matching the level attached to that generation coordinate point are selected, and the selected sub-scenes are generated in the sub-region corresponding to that generation coordinate point. After generating the selected sub-scenes in the sub-regions corresponding to each generation coordinate point, each sub-scene can be randomly rotated with the vertical direction of the sub-region as the central axis to further improve the randomness of sub-scene generation.
[0092] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environment scene in the following manner: sub-scenes of corresponding levels are generated in each sub-region in such a way that the closer the sub-region is to the center of the environment scene, the higher the level of the sub-scene generated in the sub-region.
[0093] In practical applications, the environment or virtual map is divided into several sub-regions. When randomly placing sub-scenes in each sub-region, different levels of sub-scenes can be placed according to their probability of occurrence. Generally, higher-level sub-scenes are more likely to appear in the central area of the virtual map, while lower-level sub-scenes are more likely to appear at the edge of the virtual map. For example, sub-scenes of the corresponding level can be generated in each sub-region according to the principle that the closer the sub-region is to the center of the environment, the higher the level of the sub-scene generated in the sub-region. This ensures both the randomness of sub-scene generation and provides a certain degree of regularity, which is suitable for games that require a balance between exploration and strategy.
[0094] In some embodiments, each sub-region in the environment scene can be divided into multiple ring-shaped sub-regions from the outside in. The sub-scenes are placed in the corresponding ring-shaped sub-regions in a manner that the level of the sub-scenes gradually increases from the outer ring-shaped sub-region to the inner ring-shaped sub-region. That is, the outer ring-shaped sub-regions contain low-level sub-scenes, the middle ring-shaped sub-regions contain medium-level sub-scenes, and the inner ring-shaped sub-regions contain high-level sub-scenes. Players need to gradually advance from the outside to the center, which is suitable for games that emphasize exploration and growth gameplay.
[0095] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environmental scene in the following manner: selecting a third number of sub-regions from each sub-region in the environmental scene and forming a resource-rich area from the third number of sub-regions; generating sub-scenes with levels higher than the level threshold in the resource-rich area, and randomly generating sub-scenes with levels lower than the level threshold in other sub-regions in the environmental scene other than the resource-rich area.
[0096] In practical applications, since higher-level sub-scenes contain richer virtual resources compared to lower-level sub-scenes, higher-level sub-scenes can be randomly clustered into several resource-rich areas based on game requirements. In other words, higher-level sub-scenes can be placed within these resource-rich areas. In actual implementation, a third number of sub-regions can be randomly selected from each sub-region in the environment scene. These selected sub-regions form the resource-rich areas, and sub-scenes with levels higher than a certain threshold are generated within these resource-rich areas. Meanwhile, sub-scenes with levels lower than the threshold are randomly generated in other sub-regions. This not only maintains the randomness of virtual map generation but also encourages players to explore specific areas, increasing gameplay diversity.
[0097] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environment scene in the following manner: setting the gradient of resource richness of each sub-region along the target direction of the environment scene; generating sub-scenes of corresponding levels in each sub-region in such a way that the higher the resource richness, the higher the level of the sub-scene generated in the sub-region of the corresponding gradient.
[0098] In practical applications, resource richness can be gradientd along a certain direction of the virtual map (such as from left to right or from bottom to top) according to game requirements. Sub-scenes of corresponding levels can be generated in each sub-region as the resource richness increases. For example, low-level sub-scenes can be placed on one side of the virtual map (such as the left side), high-level sub-scenes can be placed on the other side (such as the right side), and sub-scenes of corresponding levels can be placed in the middle area according to the gradient. This not only maintains the randomness of virtual map generation, but is also suitable for linear or semi-open world games. Players can gradually challenge higher difficulty areas along the gradient direction, increasing the diversity of gameplay.
[0099] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environmental scene in the following manner: in response to the presence of an exploration path in the environmental scene, sub-scenes of corresponding levels are generated sequentially in each sub-region along the exploration direction of the exploration path; wherein, the sub-scenes generated in the sub-region at the starting point of the exploration path have the lowest level, and the sub-scenes generated in the sub-region at the ending point of the exploration path have the highest level.
[0100] In practical applications, depending on the game's requirements, exploration paths can be set in the environment (i.e., virtual map). Along the exploration path, sub-scenes of corresponding levels are generated sequentially in each sub-region along the path. In other words, several key path points are set in the virtual map, and these key path points form the exploration path. Higher-level sub-scenes are placed gradually along the key path points. This not only maintains the randomness of virtual map generation but also guides players to explore step by step. It is suitable for linear narrative or task-driven games, ensuring that players progress according to the designed route.
[0101] In some embodiments, the terminal can generate sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in the environmental scene by: determining the matching degree between the terrain features of each sub-region and the level of each sub-scene; and generating sub-scenes corresponding to the levels of each sub-region where the matching degree exceeds the matching degree threshold.
[0102] In practical applications, the level distribution of sub-scenes is determined based on the terrain features (such as mountains, rivers, forests, plains, etc.) of each sub-region in the virtual map. The matching degree between the terrain features of each sub-region and the level of each sub-scene is calculated, and sub-scenes corresponding to the levels with matching degrees exceeding the matching degree threshold are generated in each sub-region. For example, high-level sub-scenes are placed in sub-regions of mountains or highlands, and low-level sub-scenes are placed in sub-regions of plains or lowlands. In this way, not only is the randomness of virtual map generation maintained, but the realism and immersion of the virtual map are also increased, which is suitable for open-world or sandbox games.
[0103] In some embodiments, the distribution probability of sub-scenes can be dynamically adjusted based on player behavior or game progress. For example, at the beginning of the game, high-level sub-scenes are randomly generated in sub-regions of the virtual map (i.e., high-level sub-scenes are randomly distributed). As players explore or complete tasks, the distribution of high-level sub-scenes is adjusted so that they gradually concentrate towards the player's current location. In other embodiments, each sub-scene can be assigned a weight. The higher the weight, the greater the probability that the sub-scene will be placed on the virtual map. Therefore, higher weights are set for high-level sub-scenes, and lower weights are set for low-level sub-scenes. Sub-scenes of different levels are randomly generated in the virtual map according to their weights. For example, at the beginning of the game, sub-scenes with weights below a weight threshold are randomly generated in sub-regions of the virtual map. As the game progresses, sub-scenes with weights above a weight threshold are randomly generated in sub-regions of the virtual map. In this way, the distribution of sub-scenes can be flexibly controlled according to the weight adjustment, which is suitable for games that require fine-tuning. The above-described method of dynamically adjusting sub-scenes maintains the randomness of virtual map generation while increasing the dynamism and challenge of the game, making it suitable for games that emphasize the impact of player behavior.
[0104] Furthermore, various distribution methods can be combined to place sub-scenes of different levels. For example, a circular distribution can be used in the central area, randomly generating higher-level sub-scenes, while a random clustering distribution can be used in the outer area, randomly generating lower-level sub-scenes. Alternatively, a gradient distribution can be used to gradually generate higher-level sub-scenes on one side of the virtual map (e.g., the left side), while a random distribution can be used on the other side (e.g., the right side) to generate sub-scenes of different levels. In short, these random generation methods can be selected and combined according to the specific needs and design goals of the game. By flexibly applying these methods, virtual maps that are both interesting and challenging can be generated.
[0105] In the above-described method, in the rendering or generation of virtual maps, the interactive scene corresponding to the environmental scene required for rendering the virtual map is divided into multiple levels of sub-scenes. The environmental scene serves as the environmental carrier of the virtual map, providing a unified background and atmosphere, thus enhancing the game's immersion. Sub-scenes are generated based on the environmental scene and seamlessly connected to it, improving the realism and consistency of the virtual map. Sub-scenes of the corresponding level are generated in different areas of the environmental scene according to their level. This hierarchical generation method not only avoids resource waste, ensuring that the map layout and content are different each time the game is played, increasing the game's diversity and playability, but also allows for flexible adjustments based on this modularity and game requirements, suitable for various map styles and gameplay modes, exhibiting good scalability and flexibility.
[0106] Step 103: Generate virtual characters in the first sub-scene of each generated sub-scene, virtual resources in the second sub-scene, and evacuation areas in the third sub-scene.
[0107] In some embodiments, virtual characters can be generated in the first sub-scene of each generated sub-scene, virtual resources can be generated in the second sub-scene, and an evacuation area can be generated in the third sub-scene in the following manner: determining the first sub-scene, the second sub-scene, and the third sub-scene in each generated sub-scene; determining the preset character spawn point in the first sub-scene, the preset resource generation point in the second sub-scene, and the preset evacuation point in the third sub-scene; generating virtual characters at the character spawn point in the first sub-scene, generating virtual resources at the resource generation point in the second sub-scene, and generating an evacuation area at the evacuation point in the third sub-scene.
[0108] In practical applications, the first, second, and third sub-scenes can be any one or more of all sub-scenes generated within a virtual map or environment. That is, the first, second, and third sub-scenes can be the same or different sub-scenes, and the number of each can be one or more. Although each of the first, second, and third sub-scenes is an independent space with the same function, in practice, different virtual objects can be generated in different sub-scenes according to the actual game requirements. For example, one or more virtual characters can be generated in the first sub-scene, one or more virtual resources in the second sub-scene, and one or more isolated areas in the third sub-scene.
[0109] For example, in a game of left-right chess, five character spawn points (i.e., player spawn points) can be selected in each of the leftmost and rightmost sub-scenes of the virtual map to generate five virtual characters (i.e., player characters); multiple resource spawn points can be selected in the middle sub-scene of the virtual map, and virtual resources can be generated at each resource spawn point; one extraction point can be selected in each of the leftmost and rightmost sub-scenes of the virtual map, and extraction zones can be generated at each extraction point. In this way, five virtual characters are generated on the left side of the virtual map, five virtual characters are generated on the right side of the virtual map, multiple virtual resources are generated in the middle area of the virtual map, and one extraction zone is generated on the left side and one extraction zone is generated on the right side of the virtual map. During the game, the virtual characters on the left side of the virtual map need to go to the middle area of the virtual map to collect virtual resources and then extract to the extraction zone on the right, while the virtual characters on the right side need to go to the middle area of the virtual map to collect virtual resources and then extract to the extraction zone on the left, thus creating player encounters and enhancing the game experience. Of course, in practical applications, the selection of character spawn points, resource spawn points, and extraction points can be determined according to specific game requirements. For example, character spawn points can be selected in sub-scenes located at the edge of the virtual map to generate virtual characters, resource spawn points can be selected in sub-scenes located in the middle of the virtual map to generate virtual resources, and extraction points can be selected in sub-scenes located in the middle of the virtual map to generate extraction areas, etc.
[0110] Through the above methods, in the rendering or generation of virtual maps, corresponding virtual characters, virtual resources, and extraction zones are generated according to the level of sub-scenes. This hierarchical generation method not only avoids resource waste and ensures that the map layout and content are different each time the game is played, increasing the diversity and playability of the game, but also allows for flexible adjustments based on this modularity and game requirements, applicable to various map styles and gameplay modes, and has good scalability and flexibility. Different levels of sub-scenes correspond to different resource richness and challenge difficulty, thus providing players with diverse exploration and strategic choices through sub-scene hierarchization. In short, this solution provides a highly diverse, immersive, and strategically deep gaming experience through optimizations in dynamic generation, hierarchical design, resource management, and player interaction; at the same time, its modular design and scalability make it suitable for various game types and gameplay modes, with broad application prospects.
[0111] In some embodiments, the preset character spawn points in the first sub-scene can be determined in the following manner: in response to the presence of multiple preset character spawn points in the first sub-scene, a fifth number of character spawn points are selected from the multiple character spawn points, and virtual characters are generated at each of the fifth number of character spawn points; wherein the distance between the virtual characters generated from different character spawn points is greater than a distance threshold, and the orientation of the virtual characters is the direction of the virtual resources or the direction of the evacuation point.
[0112] In practical applications, the number of virtual characters to be generated in the first sub-scene can be set according to specific game requirements. For example, when the required number of virtual characters is the fifth number (which can be any positive integer), the fifth number of character spawn points is randomly selected from multiple character spawn points, and virtual characters are generated at each of these fifth number of spawn points. For instance, in a left-right chess game, five character spawn points can be selected in each of the five leftmost sub-scenes of the battlefield to generate five virtual characters, that is, five virtual characters are generated on the left side of the virtual map.
[0113] It should be noted that once a virtual character is generated at a certain character's spawn point, it is possible to prevent other virtual characters from being generated at character spawn points within a certain distance of that spawn point. This can prevent players from encountering each other at the beginning of the game, but the specific distance range can be determined according to the actual needs of the game.
[0114] After generating virtual supplies or evacuation areas, the virtual character's orientation can be adjusted to the direction of the virtual supplies or evacuation area that the virtual character needs to go to. A marker for the virtual supplies or evacuation point will also be generated at the associated location of the virtual character. This allows players to easily check the direction of the virtual supplies or evacuation area at any time to plan appropriate exploration or evacuation routes.
[0115] In some embodiments, virtual resources can be generated at material generation points in a second sub-scene in the following manner: determining a fourth quantity and target category of virtual resources corresponding to a level in a preset manner in the second sub-scene; selecting a fourth quantity of material generation points from the preset material generation points in the second sub-scene, and generating virtual resources of the target category at each of the fourth quantity of material generation points.
[0116] In practical applications, after generating the second sub-scene, a fourth number (which can be any positive integer) of resource generation points can be randomly selected based on the resource abundance of the second sub-scene, and virtual resources can be randomly generated at the selected resource generation points. For example, assuming the level of the second sub-scene is D, the number of virtual resources corresponding to a level D second sub-scene is 2, but there are 10 resource generation points S1-S10 in a level D second sub-scene, then 2 resource generation points S1 and S2 can be randomly selected, and virtual resources can be generated at resource generation points S1 and S2. In this way, by pre-setting resource generation points and target categories, players need to plan their actions more strategically. Players need to formulate strategies for collecting and using virtual resources based on their distribution and categories, which increases the challenge of the game. At the same time, game developers can manage game resources more effectively, ensuring the rational allocation and utilization of resources.
[0117] Furthermore, the target category of the generated virtual resources can be determined based on the level of the second sub-scene, and virtual resources of the target type can be generated at the resource generation point. The target category of virtual resources includes, but is not limited to: survival-related virtual resources (such as food, water, medical supplies, etc.), equipment-related virtual resources (such as virtual weapons, protective gear, etc.), building-related virtual resources (such as wood, metal, stone, etc.), transportation-related virtual resources (such as virtual vehicles, virtual vehicles, etc.), and mission-related virtual resources (such as keys, passwords, or documents used to complete specific tasks or unlock new areas). In this way, by randomly generating different categories of virtual resources in the second sub-scene, a more diverse and unpredictable gaming experience can be provided to players. Players may encounter different combinations of resources each time they play the game, increasing the replay value of the game.
[0118] By using the above methods, and by presetting resource generation points and target categories in the second sub-scene, as well as randomly selecting and generating virtual resources, the randomness and diversity of the game are enhanced, as well as the strategic depth and challenge of the game are increased. Simultaneously, it also helps optimize resource management, enhance game immersion, increase scalability (due to the easily expandable classification scheme of the number and categories of resource spawn points, developers can add new resource categories and generation rules as needed without rewriting the entire map generation system), improve server performance (i.e., by filtering and generating a predefined number of resources, the server can reduce unnecessary computation and memory usage, thereby improving server performance and response speed), reduce player waiting time (since the generation of virtual resources is preset and filtered, it can reduce player waiting time in the game, especially in multiplayer games, which can provide a smoother gaming experience), support personalized game design (developers can adjust the resource generation rules according to player behavior and preferences to provide players with a personalized gaming experience), enhance game maintainability (by using the virtual resource generation rules and quantities as configuration parameters, developers can easily adjust and update game content without delving into the code level), and promote player interaction (i.e., in multiplayer games, the random generation of resources can promote interaction and cooperation between players, such as jointly collecting resources and exchanging resources). These beneficial effects collectively improve the overall quality of the game and the player's gaming experience.
[0119] In some embodiments, after generating sub-scenes of corresponding levels in sub-regions corresponding to the levels of each sub-scene in an environmental scene, in response to a viewing operation on a virtual map, level indication information for each sub-scene is displayed on the virtual map; wherein, the level indication information is used to indicate the level of the sub-scene, and the level is used to indicate the abundance of resources in the sub-scene.
[0120] In practical applications, after entering the virtual map, players can open the virtual map to view the resource abundance of all sub-scenes. Different colored blocks (i.e., level indicators) can be used on the virtual map to indicate the resource abundance of the corresponding sub-scenes. For example, S-level sub-scenes are displayed in red, and A-level sub-scenes are displayed in orange. This can guide players to formulate exploration routes that suit them. For example, it can guide skilled players to compete for virtual resources in higher-level sub-scenes and engage in skirmishes, or it can guide novice players to go to lower-level sub-scenes to collect virtual resources and evacuate safely, avoiding encounters with other players.
[0121] Step 104: In response to the control operation on the virtual character, control the virtual character to collect virtual resources, and when the evacuation conditions are met, control the virtual character to evacuate to the evacuation area with the virtual resources.
[0122] In practical applications, when the virtual character generated in the first sub-scene is a player-controlled virtual character on the current terminal, the terminal responds to control operations on the virtual character and can control the virtual character to perform corresponding interactive actions in any sub-scene of the virtual map (including the first sub-scene where it spawns). For example, the terminal can control the virtual character to move from the first sub-scene to other sub-scenes. These interactive actions can be any action of the virtual character, such as moving towards virtual resources, collecting or picking up virtual resources, moving towards the extraction area, or fighting against other virtual characters or non-player characters. In extraction games, players can plan exploration routes and extraction routes for collecting virtual resources and control the virtual character to move along the exploration route to the location of virtual resources. When the virtual character reaches the location of virtual resources, it can pick up or collect the virtual resources. When extraction conditions are met (such as defeating enemies or collecting specific virtual resources), the player can control the virtual character to carry the collected virtual resources to the extraction area. When the virtual character is detected entering the extraction area, it indicates a successful extraction, and the player can control the virtual character to leave the battlefield with all virtual resources and head to the safe zone.
[0123] In some embodiments, during the process of controlling the virtual character to collect virtual resources, or during the process of controlling the virtual character to evacuate to the evacuation area, the interaction progress of the virtual character in the virtual map is determined; as the interaction progresses, the distribution probability of each sub-scene in the virtual map is adjusted according to the interaction progress so that the adjusted distribution probability matches the interaction progress.
[0124] In practical applications, during the process of controlling virtual characters to perform corresponding interactive actions in a virtual map, the distribution probability of sub-scenes at different levels in the virtual map can be dynamically adjusted according to the interaction progress of the virtual characters, so that the adjusted distribution probability always matches the interaction progress. In this way, by adaptively adjusting the distribution probability of sub-scenes at different levels according to the interaction progress of the virtual characters (i.e., according to the player's behavior and progress), the difficulty of the game can be dynamically adjusted. For example, as the virtual characters collect more virtual resources, the probability of higher-level sub-scenes appearing can be increased, thereby increasing the game's challenge and making the game more adaptable to the player's playstyle and ability. By adjusting the distribution probability of sub-scenes at different levels, new exploration goals and strategic choices can be provided to players, enhancing the replayability and exploration of the game.
[0125] In some embodiments, the terminal can control a virtual character to collect virtual resources in response to a control operation on the virtual character as follows: In response to a control operation on a virtual character in a sub-scene where the virtual character is located, the terminal controls the virtual character to move towards the virtual resources; during the virtual character's movement, in response to the presence of other virtual characters in the sub-scene where the virtual character is located, the terminal controls the virtual character to engage in combat interaction with other virtual characters; in response to the absence of other virtual characters in the sub-scene where the virtual character is located, the terminal generates a non-player character with a target combat strength in the sub-scene where the virtual character is located, and controls the virtual character to engage in combat interaction with the non-player character; wherein, the other virtual characters and non-player characters are used to hinder the virtual character from collecting virtual resources, and the target combat strength corresponds to the level of the sub-scene where the virtual character is located; in response to the virtual character moving to the location of the virtual resources, the terminal controls the virtual character to pick up the virtual resources.
[0126] In practical applications, during the process of a virtual character entering a sub-scene and performing various interactive actions, it is possible to detect whether there are other virtual characters (i.e., other player characters) in the sub-scene where the virtual character is located. If there are other virtual characters in the sub-scene where the virtual character is located and these other virtual characters are used to hinder the virtual character from collecting virtual resources (i.e., the other virtual characters are hostile to the virtual character), the terminal can control the virtual character to fight against other virtual characters in the virtual map. If there are no other virtual characters in the sub-scene where the virtual character is located, a non-player spawn point in the sub-scene is randomly selected. Based on the level of the sub-scene, a certain number of non-player character spawn points are randomly selected to randomly generate hostile non-player characters of a strength corresponding to the level of the sub-scene. The virtual character is then controlled to fight and interact with the generated hostile non-player characters.
[0127] In some embodiments, a non-player character with a target adversarial strength can be generated in a sub-region as follows: in response to the fact that there are multiple preset non-player character generation points in the sub-region where the virtual character is located, a sixth number of generation points is selected from the multiple generation points; a non-player character is generated at each of the sixth number of generation points, wherein the difference between the sum of the adversarial strengths of the non-player characters generated at the sixth number of generation points and the target adversarial strength is lower than a difference threshold.
[0128] In practical applications, if there are multiple preset non-player character spawn points in a sub-scene where the virtual character resides, the sixth non-player character spawn point is randomly selected based on the sub-scene's level. This randomly generates hostile NPCs with strengths corresponding to the sub-scene's level, ensuring that the sum of the combat strengths of the non-player characters generated at the sixth spawn point differs from the target's combat strength by less than a threshold difference. For example, if a sub-scene of level S has a total combat power of approximately 10,000 for its hostile NPCs, and there are five non-player spawn points (S1-S5) in this sub-scene, then three non-player spawn points (S1, S2, and S3) can be randomly selected. In S1, a soldier with a combat power of 1000 will be generated; in S2, a medkit with a combat power of 2000 will be generated; and in S3, a machine gunner with a combat power of 8000 will be generated. Thus, the total combat power of the NPCs generated at these three non-player character spawn points (S1, S2, and S3) is 11,000, which is considered to meet the requirement.
[0129] In some embodiments, non-player characters are cleared in response to a virtual character leaving its sub-scene.
[0130] In practical applications, once all virtual characters leave their current sub-scene, all hostile NPCs in that scene are cleared to avoid consuming computing resources. When a virtual character is detected entering the extraction zone, it indicates a successful extraction, allowing them to bring all virtual supplies with them as they leave the battlefield and head to the safe zone.
[0131] In the application of this invention, in the rendering or generation of virtual maps, the interactive scene corresponding to the environmental scene required for rendering the virtual map is divided into multiple levels of sub-scenes. The environmental scene (such as ocean, desert, forest, etc.) serves as the environmental carrier of the virtual map, providing a unified background and atmosphere, enhancing the game's immersion. Sub-scenes are generated based on the environmental scene and seamlessly connected to it, improving the realism and consistency of the virtual map. Corresponding virtual characters, virtual resources, and evacuation areas are generated according to the level of the sub-scene. This hierarchical generation method not only avoids resource waste, ensuring that the map layout and content differ each time the game is played, increasing the game's diversity and playability, but also allows for flexible adjustments based on this modularity and game requirements, suitable for various map styles and gameplay modes, exhibiting good scalability and flexibility. Different levels of sub-scenes correspond to different resource richness and challenge levels, thus providing players with diverse exploration and strategic choices through sub-scene hierarchies. This solution provides a highly diverse, immersive, and strategically deep gaming experience through optimizations in dynamic generation, hierarchical design, resource management, and player interaction. Furthermore, its modular design and scalability make it suitable for various game genres and gameplay modes, offering broad application prospects.
[0132] The following will describe an exemplary application of the embodiments of this application in a real-world application scenario. Taking a virtual scene as a game and a virtual map as the game's battlefield as an example, the virtual map processing method provided by the embodiments of this application will be further explained.
[0133] like Figure 4 As shown, the entire battlefield is composed of an empty scene (i.e., the aforementioned environmental scene) and multiple modular scenes (i.e., the aforementioned sub-scenes). The empty scene serves as the environmental carrier of the battlefield, and the size and number of each modular scene can be determined according to the game settings, such as... Figure 4 The battlefield is composed of 25 sub-scenes, each 200 meters by 200 meters, with the ocean as the main setting.
[0134] In practical applications, both empty scenes and modular scenes are pre-designed scenarios and come in different types. For example, an empty scene can be a sea, a forest, or a mountain, serving as the environment for the overall map, while a modular scene can be a tall building, a small house, a parking lot, or a construction site. Empty scenes and modular scenes have a corresponding relationship; for example, a modular scene of a "tall building" will not be generated in an empty scene like a "forest," and a modular scene of a "construction site" will not appear in an empty scene like a "sea." Each modular scene pre-places player spawn points, non-player spawn points, resource spawn points, and extraction points, such as... Figure 5As shown. In addition, based on the abundance of resources, modular scenarios can be divided into five levels: S, A, B, C, and D. Generally, the higher the level of the modular scenario, the richer the virtual resources in the modular scenario, and the stronger the hostile non-player characters.
[0135] At the start of the game, modular scenes can be randomly placed in an empty scene. For example, the closer to the center of the map, the higher the probability of a higher-level modular scene appearing. The specific method for randomly generating modular scenes depends on the game design. When generating modular scenes, their coordinates can be determined based on the surface coordinates of the empty scene's model. Specifically, the generation coordinates of the modular scenes can be pre-placed when designing the empty scene model. After generating modular scenes, the randomness of the generated scenes can be increased by randomly rotating them around a vertical axis.
[0136] After a modular scene is generated, a certain number of resource generation points are randomly selected based on the resource abundance of the modular scene, and virtual resources are randomly generated at these points. For example, assuming that the number of virtual resources in a D-level modular scene is 2, and there are 10 resource generation points S1-S10 in the D-level modular scene, then 2 resource generation points S1 and S2 can be randomly selected, and virtual resources can be generated at resource generation points S1 and S2.
[0137] After the modular scene is generated, player spawn points can be randomly selected on the modular scene of the battlefield according to game requirements, and player characters can be randomly generated at the player spawn points. For example, see Figure 6 , Figure 6 This is a schematic diagram of player character generation provided in the embodiments of this application. For games of left-right chess, five player spawn points can be selected on the leftmost and rightmost modular scenes of the battlefield to generate five player characters, that is, five player characters are generated on the left side of the map and five player characters are generated on the right side of the map.
[0138] After the modular scene is generated, extraction points can be randomly selected on the modular scene of the battlefield according to game requirements, and extraction zones can be randomly generated at the extraction points. For example, see still Figure 6For games with left-right card game elements, one extraction point can be selected on each of the leftmost and rightmost modular scenes of the battlefield, and extraction zones can be generated at each extraction point. That is, one extraction zone is generated on the left side of the map, and one on the right side. During gameplay, players on the left side of the map need to go to the right extraction zone to extract, while players on the right side need to go to the left extraction zone, thus creating player encounters and enhancing the gaming experience. Of course, in practical applications, the selection of player spawn points and extraction points can be determined according to specific game requirements. For example, player spawn points can be selected in modular scenes located at the edge of the map to generate player characters, while extraction points can be selected in modular scenes located in the middle of the map to generate extraction zones, and so on.
[0139] It should be noted that once a player character is generated at a certain player spawn point, it is possible to prevent other player characters from being generated at player spawn points within a certain distance of that player spawn point. This can prevent players from encountering each other at the beginning of the game, but the specific distance range can be determined according to the actual needs of the game.
[0140] After generating the player character, see Figure 7 , Figure 7 This is a schematic diagram of the player character's orientation provided in this application embodiment. The player character's orientation can be adjusted to the direction of the extraction point that the player character needs to go to, and an extraction point marker is generated at the player character's associated location. This makes it convenient for the player to check the direction of the extraction point at any time in order to formulate a suitable extraction route.
[0141] Once players enter the battlefield, they can open the game map to view the resource abundance of all modular scenes. Different colored blocks on the game map indicate the resource abundance of corresponding modular areas. For example, S-level modular areas are displayed in red, and A-level modular areas are displayed in orange. This can guide players to develop exploration routes that suit them. For example, it can guide skilled players to compete for virtual resources in higher-level modular scenes and engage in skirmishes, or guide novice players to go to lower-level modular scenes to collect virtual resources and evacuate safely, avoiding encounters with other players.
[0142] When a player enters a modular scene area, the system checks if other player characters are present. If not, it randomly selects a number of non-player character spawn points based on the modular scene's level. These spawn points generate enemy non-player characters (NPCs) of a strength corresponding to the modular scene's level. For example, in a level S modular scene, the total combat power of the enemy NPCs is approximately 10,000. If this scene has five non-player character spawn points (S1-S5), three spawn points (S1, S2, and S3) are randomly selected. In S1, a soldier with a combat power of 1000 is spawned; in S2, a medkit with a combat power of 2000 and a machine gunner with a combat power of 8000 are spawned. The total combat power of the NPCs generated from these three spawn points is 11,000. Once all players leave the modular scene, all enemy NPCs are removed to avoid consuming computational resources. When a player character is detected entering the extraction zone, it means that the player character has successfully extracted and can take all virtual resources with them to leave the battlefield and head to the safe zone.
[0143] See Figure 8 , Figure 8 This is a flowchart illustrating a virtual map processing method provided in an embodiment of this application. The method includes:
[0144] Step 201: In response to a rendering request for a virtual map, determine the empty scene required to render the virtual map and the multiple modular scenes corresponding to the empty scene.
[0145] Here, when a rendering request for a virtual map is received, an empty scene can be randomly selected, and multiple modular scenes corresponding to the selected empty scene can be obtained.
[0146] Step 202: Render the empty scene as the environment carrier of the virtual map, and randomly generate modular scenes in the empty scene.
[0147] Here, after the terminal determines the empty scene (usually the model corresponding to the empty scene) required to render the virtual map, it renders the empty scene as the environment carrier of the virtual map. That is, it renders the model of the empty scene to obtain a visualized three-dimensional environment scene. For example, when the empty scene is a sea model, the sea model is rendered to obtain a three-dimensional sea, and the sea is used as the environment carrier or background of the virtual map.
[0148] After rendering an empty virtual map scene, multiple modular scenes can be randomly placed within the empty scene (i.e., the virtual map or battlefield) to increase the randomness of virtual map generation. However, since different modular scenes can have different levels, and there may be multiple modular scenes of the same level, when generating modular scenes in the empty scene, the level of the modular scenes can be combined to randomly generate modular scenes of the corresponding level in sub-regions or locations within the empty scene. This not only increases the randomness of virtual map generation but also provides players with diverse exploration and strategic choices through the hierarchical nature of modular scenes.
[0149] In addition, when generating modular scenes, the vertical direction of the area where the modular scene is located can be used as the central axis to randomly rotate the modular scene, thereby further improving the randomness of the modular scene generation.
[0150] Step 203: Generate virtual characters in the first modular scene.
[0151] Here, the first modular scene refers to the first sub-scene mentioned above, which can be any one or more of the modular scenes generated in the virtual map. The selection method of the first modular scene can be determined according to the specific game requirements. For example, in a game of left-right chess, five player spawn points can be selected on the leftmost and rightmost modular scenes of the battlefield to generate five player characters, that is, five player characters are generated on the left side of the virtual map and five player characters are generated on the right side of the virtual map.
[0152] It should be noted that once a player character is generated at a certain player spawn point, it is possible to prevent other player characters from being generated at player spawn points within a certain distance of that player spawn point. This can prevent players from encountering each other at the beginning of the game, but the specific distance range can be determined according to the actual needs of the game.
[0153] Step 204: Generate virtual resources in the second modular scenario.
[0154] The second modular scenario is the second sub-scenario mentioned above, which can be any one or more of the modular scenarios generated in the virtual map. In actual implementation, all modular scenarios generated in the virtual map are traversed, and according to the resource richness corresponding to their level, a corresponding number of resource generation points are randomly selected on the modular scenario to randomly generate virtual resources.
[0155] Step 205: Generate the evacuation zone in the third modular scenario.
[0156] The third modular scene is the aforementioned third sub-scene, which can be any one or more of the modular scenes generated in the virtual map. In actual implementation, a certain number of extraction points can be selected on the modular scene according to specific game requirements, and extraction areas can be generated at the extraction points.
[0157] After generating the extraction zone, the player character's orientation can be adjusted to the direction of the extraction point the player needs to go to, and an extraction point marker can be generated at the player character's associated location. This makes it easy for the player to check the direction of the extraction point at any time in order to plan a suitable extraction route.
[0158] Once players enter the battlefield, they can open the game map to view the resource abundance of all modular scenes. Different colored blocks on the game map indicate the resource abundance of corresponding modular areas. For example, S-level modular areas are displayed in red, and A-level modular areas are displayed in orange. This can guide players to develop exploration routes that suit them. For example, it can guide skilled players to compete for virtual resources in higher-level modular scenes and engage in skirmishes, or guide novice players to go to lower-level modular scenes to collect virtual resources and evacuate safely, avoiding encounters with other players.
[0159] Step 206: In response to the control operation on the first virtual character in the target modular scene, control the first virtual character to perform interactive actions.
[0160] Here, the first virtual character is the player character controlled by the player on the current terminal side in the game. When the first virtual character enters the target modular scene of the battlefield (which can be any modular scene generated in the virtual map), the player can control the first virtual character to perform corresponding interactive actions in the modular scene. The interactive actions can be any action of the first virtual character, such as moving towards virtual resources, collecting or picking up virtual resources, moving towards the extraction area, fighting against other players or NPCs, etc.
[0161] Step 207: Determine whether a second virtual character exists in the target modular scene.
[0162] Here, when the first virtual character enters the target modular scene, it can be detected whether there are other player characters in the target modular scene where the first virtual character is located. If there is a second virtual character (a virtual character controlled by another player) in the target modular scene, that is, there are other player characters in the target modular scene, then step 208 is executed; if there is no second virtual character in the target modular scene, then step 209 is executed.
[0163] Step 208: Control the first virtual character to fight against the second virtual character.
[0164] Here, if a second virtual character exists in the target modular scene where the first virtual character is located, and the second virtual character is used to prevent the first virtual character from evacuating to the evacuation area, then the first virtual character can be controlled to fight against the second virtual character.
[0165] Step 209: Generate a non-player character in the target modular scene and control the first virtual character to fight against the non-player character.
[0166] Here, if the second virtual character does not exist in the target modular scene where the first virtual character is located, non-player spawn points in the target modular scene can be randomly selected. Based on the level of the target modular scene, a certain number of non-player character spawn points can be randomly selected to randomly generate hostile non-player characters of strength corresponding to the level of the target modular scene. For example, if the target modular scene is a level S modular scene, its corresponding hostile NPCs have a total combat power of approximately 10,000. If there are 5 non-player spawn points in this modular scene (S1-S5), then 3 non-player spawn points S1, S2, and S3 can be randomly selected. In S1, one soldier with a combat power of 1000 will be generated; in S2, one medkit with a combat power of 2000 will be generated; and in S3, one machine gunner with a combat power of 8000 will be generated. Thus, the total combat power of the NPCs generated from these three non-player character spawn points (S1, S2, and S3) will be 11,000.
[0167] Since the generated non-player characters are usually used to prevent the first virtual character from evacuating to the evacuation area, the first virtual character can be controlled to fight against the non-player characters.
[0168] Step 210: Determine whether the first virtual character has left the target modular scene.
[0169] Here, if the first virtual character leaves the target modular scene, such as moving to the next modular scene, then step 211 is executed; if the first virtual character does not leave the target modular scene, then step 206 is executed.
[0170] Step 211: Remove non-player characters from the target modular scene.
[0171] Here, when a player controls the first virtual character to leave the target modular scene and there are no other player characters in the target modular scene, all hostile NPCs in the target modular scene can be cleared to avoid consuming computing resources.
[0172] Step 212: In response to the evacuation conditions being met, control the first virtual character to evacuate to the evacuation area with virtual supplies.
[0173] Here, when players need to meet certain evacuation conditions (such as defeating enemies, collecting specific virtual resources, etc.), the player controls the first virtual character to carry the collected virtual resources to the evacuation area. When the first virtual character is detected to have entered the evacuation area, it means that the first virtual character has successfully evacuated and can be controlled to leave the battlefield with all virtual resources and head to the safe zone.
[0174] By using the above method, which generates virtual maps based on modular scenes, the battlefield is randomly generated modularly at the start of the game. This includes random player spawn points, extraction points, resource points, NPC spawn points, etc. Players can customize new extraction routes based on the resource abundance of each modular scene in the battlefield. At the same time, modular scenes can reduce the learning cost of virtual maps for players. This embodiment of the application can keep players feeling fresh even after multiple playthroughs while satisfying the game mechanics of extraction gameplay.
[0175] The exemplary application and implementation of the electronic device provided in the embodiments of this application have been used to describe the virtual map processing method provided in the embodiments of this application. The following will continue to describe the cooperation of the various modules in the virtual map processing device 555 provided in the embodiments of this application to implement the virtual map processing scheme.
[0176] The determination module 5551 is used to determine, in response to a rendering request for a virtual map, the environmental scene required for rendering the virtual map, and multiple levels of sub-scenes corresponding to the environmental scene; the first rendering module 5552 is used to render the environmental scene using the environmental scene as the environmental carrier of the virtual map, and generate sub-scenes of corresponding levels in the sub-regions corresponding to the levels of each sub-scene in the environmental scene; the second rendering module 5553 is used to generate virtual characters in the first sub-scene of each generated sub-scene, generate virtual resources in the second sub-scene, and generate evacuation areas in the third sub-scene; the control module 5554 is used to control the virtual character to collect the virtual resources in response to a control operation for the virtual character, and control the virtual character to evacuate to the evacuation area with the virtual resources when the evacuation conditions are met.
[0177] In some embodiments, the determining module is further configured to, in response to the presence of multiple candidate environment scenes associated with the virtual map, display a scene selection interface, wherein the scene selection interface includes at least two candidate environment scenes; and, in response to the scene selection operation, determine the selected candidate environment scene as the environment scene required for rendering the virtual map.
[0178] In some embodiments, the determining module is further configured to, in response to the presence of multiple candidate environment scenarios associated with the virtual map, invoke a neural network model to predict the usage probability of each candidate environment scenario based on an influencing factor affecting the use of each candidate environment scenario, and determine the candidate environment scenario with the highest usage probability as the environment scenario required for rendering the virtual map; wherein, the influencing factor includes at least one of the following: historical usage rate, feedback information, resources required to render the candidate environment scenario, and the matching degree between the account characteristics of the target account that triggered the rendering request and the scene characteristics of the candidate environment scenario; the neural network model is trained by: invoking the neural network model to predict the probability of using the environment scenario sample based on the influencing factor of the environment scenario sample, and performing backpropagation based on the difference between the probability of using the environment scenario sample and the label of the actual usage result to update the parameters of the neural network model.
[0179] In some embodiments, the first rendering module is further configured to obtain a first number of pre-marked generation coordinate points in the model of the environment scene, and select a second number of generation coordinate points from the first number of generation coordinate points, each of the generation coordinate points being assigned a level; for each of the second number of generation coordinate points, in the sub-region corresponding to the generation coordinate point, a sub-scene corresponding to a level matching the level assigned to the generation coordinate point is generated, and the sub-scene is rotated about the vertical direction of the sub-region as the central axis.
[0180] In some embodiments, the first rendering module is further configured to generate sub-scenes of a corresponding level in each of the sub-regions, such that the closer the sub-region is to the center of the environment scene, the higher the level of the sub-scene generated in the sub-region.
[0181] In some embodiments, the first rendering module is further configured to select a third number of sub-regions from each sub-region in the environment scene, and form the third number of sub-regions into a resource-rich region; generate sub-scenes with a level higher than a level threshold in the resource-rich region, and randomly generate sub-scenes with a level lower than the level threshold in other sub-regions in the environment scene other than the resource-rich region.
[0182] In some embodiments, the first rendering module is further configured to set a gradient of resource richness for each of the sub-regions along the target direction of the environment scene; and generate sub-scenes of corresponding levels in each of the sub-regions in such a way that the higher the resource richness, the higher the level of the sub-scene generated in the corresponding gradient sub-region.
[0183] In some embodiments, the first rendering module is further configured to, in response to an exploration path being provided in the environment scene, sequentially generate sub-scenes of corresponding levels along the exploration direction of the exploration path in each of the sub-regions traversed by the exploration path; wherein, the sub-scenes generated in the sub-region at the starting point of the exploration path have the lowest level, and the sub-scenes generated in the sub-region at the ending point of the exploration path have the highest level.
[0184] In some embodiments, the first rendering module is further configured to determine the matching degree between the terrain features of each sub-region and the level of each sub-scene; and generate a sub-scene corresponding to the level in each sub-region where the matching degree exceeds the matching degree threshold.
[0185] In some embodiments, the second rendering module is further configured to determine a first sub-scene, a second sub-scene, and a third sub-scene in each of the generated sub-scenes; determine a preset character spawn point in the first sub-scene, a preset resource generation point in the second sub-scene, and a preset evacuation point in the third sub-scene; generate a virtual character at the character spawn point in the first sub-scene, generate virtual resources at the resource generation point in the second sub-scene, and generate an evacuation area at the evacuation point in the third sub-scene.
[0186] In some embodiments, the second rendering module is further configured to, in response to the presence of multiple preset character spawn points in the first sub-scene, select a fifth number of character spawn points from the multiple character spawn points, and generate virtual characters at each of the fifth number of character spawn points; wherein the distance between virtual characters generated from different character spawn points is greater than a distance threshold, and the orientation of the virtual characters is the direction of the virtual resources or the direction of the evacuation point.
[0187] In some embodiments, the second rendering module is further configured to determine a fourth quantity and target category of virtual resources corresponding to the level in the second sub-scene; select the fourth quantity of resource generation points from the preset resource generation points in the second sub-scene; and generate virtual resources of the target category at each of the fourth quantity of resource generation points.
[0188] In some embodiments, after generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene, the device further includes: an indication module, configured to display level indication information for each sub-scene in the virtual map in response to a viewing operation on the virtual map; wherein the level indication information is used to indicate the level of the sub-scene, and the level is used to indicate the resource abundance of the sub-scene.
[0189] In some embodiments, the apparatus further includes: an adjustment module, configured to determine the interaction progress of the virtual character in the virtual map during the process of controlling the virtual character to collect the virtual resources, or during the process of controlling the virtual character to evacuate to the evacuation area; and as the interaction progresses, adjust the distribution probability of each of the sub-scenes in the virtual map according to the interaction progress, so that the adjusted distribution probability matches the interaction progress.
[0190] In some embodiments, the control module is further configured to, in response to a control operation on the virtual character, control the virtual character to move toward the virtual resource; during the movement of the virtual character, in response to the presence of other virtual characters in the sub-scene where the virtual character is located, control the virtual character to engage in combat interaction with the other virtual characters; in response to the absence of other virtual characters in the sub-scene where the virtual character is located, generate a non-player character with a target combat strength in the sub-scene where the virtual character is located, and control the virtual character to engage in combat interaction with the non-player character; wherein the other virtual characters and the non-player character are used to prevent the virtual character from collecting the virtual resource, and the target combat strength corresponds to the level of the target sub-scene; in response to the virtual character moving to the location of the virtual resource, control the virtual character to pick up the virtual resource.
[0191] In some embodiments, the control module is further configured to, in response to the presence of multiple preset non-player character generation points in the sub-region where the virtual character is located, select a sixth number of generation points from the multiple generation points; generate non-player characters at each of the sixth number of generation points, wherein the difference between the sum of the combat strength of the non-player characters generated at the sixth number of generation points and the target combat strength is lower than a difference threshold.
[0192] In some embodiments, the apparatus further includes a clearing module for clearing the non-player character in response to the virtual character leaving the target sub-scene.
[0193] This application provides a computer program product, which includes a computer program or computer-executable instructions stored in a computer-readable storage medium. The processor of an electronic device reads the computer-executable instructions from the computer-readable storage medium and executes the computer-executable instructions, causing the electronic device to perform the virtual map processing method described above in this application.
[0194] This application provides a computer-readable storage medium storing computer-executable instructions or a computer program. When the computer-executable instructions or the computer program are executed by a processor, the processor will execute the virtual map processing method provided in this application. For example, ... Figure 3 The method for processing virtual maps is shown.
[0195] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or it may be a variety of devices including one or any combination of the above-mentioned memories.
[0196] In some embodiments, computer-executable instructions may take the form of programs, software, software modules, scripts, 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 stand-alone programs or as modules, components, subroutines, or other units suitable for use in a computing environment.
[0197] As an example, computer-executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple co-located files (e.g., files that store one or more modules, subroutines, or code sections).
[0198] As an example, computer-executable instructions can be deployed to execute on a single electronic device, or on multiple electronic devices located in one location, or on multiple electronic devices distributed across multiple locations and interconnected via a communication network.
[0199] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, and improvements made within the spirit and scope of this application are included within the scope of protection of this application.
Claims
1. A method for processing virtual maps, characterized in that, The method includes: In response to a rendering request for a virtual map, determine the environmental scene required to render the virtual map, and multiple levels of sub-scenes corresponding to the environmental scene; The environment scene is rendered using the environment scene as the environment carrier of the virtual map, and the corresponding level of the sub-scene is generated in the sub-region corresponding to the level of each sub-scene in the environment scene; In the first sub-scene of each of the generated sub-scenes, virtual characters are generated; in the second sub-scene, virtual resources are generated; and in the third sub-scene, an evacuation area is generated. In response to a control operation on the virtual character, the virtual character is controlled to collect the virtual resources, and when the evacuation conditions are met, the virtual character is controlled to evacuate to the evacuation area with the virtual resources.
2. The method according to claim 1, characterized in that, Determining the environmental scene required for rendering the virtual map includes: In response to the presence of multiple candidate environment scenarios associated with the virtual map, a scenario selection interface is displayed, which includes at least two candidate environment scenarios. In response to the scene selection operation, the selected candidate environment scene is determined as the environment scene required for rendering the virtual map.
3. The method according to claim 1, characterized in that, Determine the environmental scene required for rendering the virtual map, including: Since there are multiple candidate environment scenarios associated with the virtual map, based on the influencing factors that affect the use of each candidate environment scenario, a neural network model is invoked to predict the usage probability of each candidate environment scenario, and the candidate environment scenario with the highest usage probability is determined as the environment scenario required for rendering the virtual map. The influencing factors include at least one of the following: historical usage rate, feedback information, resources required to render the candidate environment scene, and the matching degree between the account characteristics of the target account that triggered the rendering request and the scene characteristics of the candidate environment scene. The neural network model is trained in the following way: based on the influence factors of environmental scene samples, the neural network model is called to predict the probability of using the environmental scene samples, and backpropagation is performed based on the difference between the probability of using the environmental scene samples and the label of the actual usage result to update the parameters of the neural network model.
4. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: A first number of pre-marked generated coordinate points are obtained in the model of the environmental scene, and a second number of generated coordinate points are selected from the first number of generated coordinate points, each of the generated coordinate points being assigned a level; For each of the second number of generated coordinate points, in the sub-region corresponding to the generated coordinate point, a sub-scene corresponding to the level attached to the generated coordinate point is generated, and the sub-scene is rotated with the vertical direction of the sub-region as the central axis.
5. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: Sub-scenes of corresponding levels are generated in each of the sub-regions in such a way that the closer the sub-region is to the center of the environment scene, the higher the level of the sub-scene generated in the sub-region.
6. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: A third number of sub-regions are selected from each sub-region in the environmental scene, and the third number of sub-regions are combined into a resource-rich area. In the resource-rich area, sub-scenes with a level higher than the level threshold are generated, and in other sub-regions of the environment scene other than the resource-rich area, sub-scenes with a level lower than the level threshold are randomly generated.
7. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: Along the target direction of the environmental scene, set the gradient of resource richness for each of the sub-regions; Sub-scenes of corresponding levels are generated in each of the sub-regions in such a way that the greater the resource richness, the higher the level of the sub-scene generated in the corresponding gradient sub-region.
8. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: In response to the presence of an exploration path in the environment, sub-scenes of corresponding levels are generated sequentially in each of the sub-regions traversed by the exploration path, along the exploration direction of the exploration path. Among them, the sub-scenes generated in the sub-region at the starting point of the exploration path have the lowest level, and the sub-scenes generated in the sub-region at the ending point of the exploration path have the highest level.
9. The method according to claim 1, characterized in that, The step of generating the corresponding level of the sub-scene in the sub-region corresponding to the level of each sub-scene in the environmental scene includes: Determine the degree of matching between the terrain features of each sub-region and the level of each sub-scene; In each of the sub-regions, a sub-scene is generated corresponding to the level where the matching degree exceeds the matching degree threshold.
10. The method according to claim 1, characterized in that, The process of generating virtual characters in the first sub-scene, virtual supplies in the second sub-scene, and evacuation areas in the third sub-scene includes: Determine the first sub-scene, the second sub-scene, and the third sub-scene among the generated sub-scenes; Determine the preset character spawn point in the first sub-scene, the preset resource generation point in the second sub-scene, and the preset evacuation point in the third sub-scene; Virtual characters are generated at the character spawn point in the first sub-scene, virtual resources are generated at the material generation point in the second sub-scene, and an evacuation area is generated at the evacuation point in the third sub-scene.
11. The method according to claim 10, characterized in that, Determining the preset character spawn point in the first sub-scene includes: In response to the fact that there are multiple preset character spawn points in the first sub-scene, a fifth number of character spawn points are selected from the multiple character spawn points, and virtual characters are generated at each of the fifth number of character spawn points; In this context, the distance between virtual characters generated from different character spawn points is greater than a distance threshold, and the orientation of the virtual characters is either the direction of the virtual resources or the direction of the evacuation point.
12. The method according to claim 10, characterized in that, The generation of virtual resources at the material generation point in the second sub-scene includes: Determine the fourth quantity and target category of the virtual materials corresponding to the level in the second sub-scenario; The fourth number of material generation points are selected from the preset material generation points in the second sub-scene, and virtual materials of the target category are generated at each of the fourth number of material generation points.
13. The method according to claim 1, characterized in that, After generating the corresponding level of sub-scenes in the sub-regions corresponding to the levels of each sub-scene in the environmental scene, the method further includes: In response to a viewing operation on the virtual map, level indication information for each of the sub-scenes is displayed in the virtual map; The level indication information is used to indicate the level of the sub-scene, and the level is used to indicate the abundance of resources in the sub-scene.
14. The method according to claim 1, characterized in that, The method further includes: During the process of controlling the virtual character to collect the virtual resources, or during the process of controlling the virtual character to evacuate to the evacuation area, the interaction progress of the virtual character in the virtual map is determined; As the interaction progresses, the distribution probability of each sub-scene in the virtual map is adjusted according to the interaction progress so that the adjusted distribution probability matches the interaction progress.
15. The method according to claim 1, characterized in that, The control operation in response to the virtual character, controlling the virtual character to collect the virtual resources, includes: In response to a control operation on the virtual character, the virtual character is controlled to move toward the virtual resource; During the movement of the virtual character, in response to the presence of other virtual characters in the sub-scene where the virtual character is located, the virtual character is controlled to engage in combat and interaction with the other virtual characters. In response to the absence of other virtual characters in the sub-scene where the virtual character is located, a non-player character with target combat strength is generated in the sub-scene where the virtual character is located, and the virtual character is controlled to interact and fight against the non-player character. The other virtual characters and the non-player characters are used to prevent the virtual characters from collecting the virtual resources, and the target confrontation intensity corresponds to the level of the sub-scene where the virtual character is located; In response to the virtual character moving to the location of the virtual resource, the virtual character is controlled to pick up the virtual resource.
16. The method according to claim 15, characterized in that, The generation of a non-player character with target combat strength in the sub-scene where the virtual character is located includes: In response to the fact that there are multiple preset non-player character generation points in the sub-scene where the virtual character is located, a sixth generation point is selected from the multiple generation points; Non-player characters are generated at each of the sixth number of generation points, wherein the difference between the sum of the adversarial strengths of the non-player characters generated at the sixth number of generation points and the target adversarial strength is less than a difference threshold.
17. A virtual map processing apparatus, characterized in that, The device includes: The determination module is used to determine, in response to a rendering request for a virtual map, the environmental scene required to render the virtual map, and multiple levels of sub-scenes corresponding to the environmental scene. The first rendering module is used to render the environment scene as the environment carrier of the virtual map, and generate the sub-scene of the corresponding level in the sub-region corresponding to the level of each sub-scene in the environment scene; The second rendering module is used to generate virtual characters in the first sub-scene of each of the generated sub-scenes, virtual resources in the second sub-scene, and evacuation areas in the third sub-scene. The control module is configured to respond to control operations on the virtual character, control the virtual character to collect the virtual resources, and control the virtual character to evacuate to the evacuation area with the virtual resources when the evacuation conditions are met.
18. An electronic device, characterized in that, include: Memory is used to store executable instructions or computer programs. A processor, configured to execute computer-executable instructions or computer programs stored in the memory, implements the virtual map processing method according to any one of claims 1 to 16.
19. A computer-readable storage medium, characterized in that, The system stores computer-executable instructions or computer programs, which, when executed by a processor, implement the virtual map processing method according to any one of claims 1 to 16.
20. 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 the processor, the virtual map processing method according to any one of claims 1 to 16 is implemented.