Game map generation method, system and equipment based on artificial intelligence simulation

Through the game map generation method based on artificial intelligence simulation, the template map and density value adjustment technology are used to solve the problem of non-connected areas that may occur in game maps, and diversified and connected game map generation is achieved, improving the user experience.

CN120227651AActive Publication Date: 2025-07-01CHILLYROOM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510726426.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-03
Publication Date
2025-07-01
Estimated Expiration
2045-06-03

AI Technical Summary

Technical Problem

Existing randomly generated game maps may have non-connected areas, resulting in some map areas being invalid and affecting the experience of game users.

Method used

The game map generation method based on artificial intelligence simulation is adopted to generate a basic map through the template map, set the density value to adjust the game road, perform terrain aggregation and iteration, generate a cave-shaped initial game map, and adjust the density value according to the game task duration to ensure that the generated map is connected and meets user needs.

Benefits of technology

It realizes the generation of diversified game maps, avoids the emergence of non-connected areas, improves the experience of game users, and ensures the connectivity and diversity of game maps.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120227651A_ABST
    Figure CN120227651A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a game map generation method, system and equipment based on artificial intelligence simulation, and is applied to the technical field of image processing. According to the game map generation method, on the basis of the preset template map, the initial game map can be generated through density value-based random adjustment and terrain aggregation iteration, so that diversified template maps can be set in a game system to randomly generate multi-pattern game maps and provide the multi-pattern game maps for game players; meanwhile, non-connected areas of game maps generated before and after can be avoided by purposefully reading the template map; furthermore, after the initial game map is generated, the game duration for actually executing the game task in the initial game map needs to be obtained, and the density value is adjusted through the game duration so as to readjust the complexity of the game road, so that the generated game map better meets the actual demand of the game user.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to a method, system and device for generating a game map based on artificial intelligence simulation. Background Art

[0002] In today's game systems such as role-playing games, in order to ensure the flexibility and fun of the game and encourage game players to repeatedly enter the game system to perform tasks, fixed game levels are generally not set. Instead, the game terrain and levels are randomly generated as the game players operate in the game. However, existing randomly generated game maps may have unconnected areas, resulting in some game map areas being invalid areas. Game users cannot interact with monster treasure chests in the invalid areas, resulting in a poor experience for game users on this part of the map (for example, they cannot obtain certain achievements, etc.). Summary of the invention

[0003] The embodiments of the present invention provide a method, system and device for generating a game map based on artificial intelligence simulation, which realizes the generation of diversified game maps and avoids the generation of non-connected game maps.

[0004] An embodiment of the present invention provides a method for generating a game map based on artificial intelligence simulation, comprising: Generate a basic map based on the template map, wherein the basic map includes game road pixel points and non-road pixel points; Setting a density value for adjusting the game road, and randomly adjusting the first game road pixel point and the second non-road pixel point in the edge area of ​​the game road in the basic map according to the density value to obtain an adjusted map; Performing terrain aggregation iteration on the game roads in the adjusted map to generate an initial game map in the shape of a cave; The execution of a game task is simulated in the initial game map, and the game time of executing the game task is obtained, and the density value is adjusted according to the game time to re-randomly adjust the pixel points until the game time of the game map generated after adjustment is within the set range.

[0005] An embodiment of the present invention provides a game map generation system based on artificial intelligence simulation, comprising: A basic map unit, used to generate a basic map based on a template map, wherein the basic map includes game road pixel points and non-road pixel points; A random adjustment unit, used to set a density value for adjusting the game road, and to randomly adjust the first game road pixel point and the second non-road pixel point in the edge area of ​​the game road in the basic map according to the density value to obtain an adjusted map; A terrain iteration unit for performing terrain aggregation iteration on the game roads in the adjusted map to generate an initial game map in the shape of a karst cave; A density value adjustment unit for simulating and executing a game task in the initial game map, obtaining the game duration of the executed game task, and adjusting the density value according to the game duration to re-perform random adjustment of pixel points until the game duration of the generated game map is within a set range.

[0006] Another aspect of the embodiment of the present invention further provides a terminal device, including a processor and a memory; The memory is used to store a plurality of computer programs, and the computer programs are used to be loaded and executed by the processor to perform the game map generation method based on artificial intelligence simulation as described in one aspect of the embodiment of the present invention; the processor is used to implement each computer program in the plurality of computer programs.

[0007] It can be seen that in the game map generation method of the present application, based on a preset template map, an initial game map can be generated through random adjustment based on density values and terrain aggregation iteration. In this way, not only can a variety of template maps be set in the game system to randomly generate various game maps for game players, but also the non-connected areas of the game maps generated before and after can be avoided by purposefully reading the template maps; further, in this embodiment, after the initial game map is generated, it is necessary to obtain the game duration of actually executing the game task in the initial game map, and adjust the density value through the game duration to re-adjust the complexity of the game road. In this way, through the actual use situation of the generated initial game map, the re-adjustment of the game road is guided, so that the generated game map better meets the actual needs of game users. Description of the Drawings

[0008] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0009] Figure 1 It is a schematic diagram of a game map generation method based on artificial intelligence simulation provided by an embodiment of the present invention; Figure 2 It is a flowchart of a game map generation method based on artificial intelligence simulation provided by an embodiment of the present invention; Figure 3 It is a schematic diagram of pixel magnification in an embodiment of the present invention; Figure 4It is a schematic diagram of selecting the edge area of the game road in the embodiment of the present invention; Figure 5 It is a flowchart of a game map generation method based on artificial intelligence simulation provided by an application embodiment of the present invention; Figure 6a It is a schematic diagram of the adjusted map obtained in the embodiment of the present invention; Figure 6b It is a schematic diagram of the map after terrain aggregation iteration in the embodiment of the present invention; Figure 6c It is a schematic diagram of the initial game map generated in the embodiment of the present invention; Figure 7 It is a schematic diagram of the logical structure of a game map generation system based on artificial intelligence simulation provided by the embodiment of the present invention; Figure 8 It is a schematic diagram of the logical structure of a terminal device provided by the embodiment of the present invention. Detailed implementation manners

[0010] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present invention.

[0011] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and do not have to be used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present invention described herein can be implemented in an order different from those illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units does not have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products, or devices.

[0012] The embodiment of the present invention provides a game map generation method based on artificial intelligence simulation, mainly a method for randomly generating a game map, mainly a method executed by a game system, such as Figure 1 shown, and can be implemented by the following method: Generate a base map based on a template map, where the base map includes game road pixels and non-road pixels; set a density value for adjusting the game road, and randomly adjust the first game road pixels and the second non-road pixels in the edge area of the game road in the base map according to the density value to obtain an adjusted map; perform terrain aggregation iteration on the game road in the adjusted map to generate an initial game map in the shape of a karst cave; simulate and execute a game task in the initial game map, and obtain the game duration of executing the game task, and adjust the density value according to the game duration to re-perform random adjustment of the pixels until the game duration of the generated game map is within a set range.

[0013] Among them, in this application, the game map is generated based on a template map. In this way, not only can the diversity of the template map make the generated game maps diverse, but also the non-connected areas of the game maps generated before and after can be avoided by purposefully reading the template map. For example, the exit position of the currently loaded map corresponds to the entrance position of the template map to be read, making the game maps generated before and after connected and avoiding the non-connected areas of the game maps generated before and after.

[0014] Among them, the game system that executes the method of this application may include a game terminal, or include a game terminal and a game server that interact with each other, and no specific limitation is made here.

[0015] In the process of executing the method of this application, the processes of generating the base map, randomly adjusting the pixels, and terrain aggregation iteration can all be implemented by different machine learning sub-models respectively. In this way, these machine learning sub-models form a complete game map generation model; or only implement the relatively important steps, such as the operation of terrain aggregation iteration, using a machine learning model. Further, in the process of generating a game map, by first generating an initial game map, and then based on the actual situation of executing the game task in the initial game map, such as the game duration, as feedback, and then adjusting the density value in the process of generating the game map, continuously re-adjusting the effect of generating the game map, this is a process of training a game map generation model based on artificial intelligence (AI), mainly to make the game map generation model generate diverse and appropriately complex game maps.

[0016] Among them, artificial intelligence is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making.

[0017] Artificial intelligence technology is a comprehensive discipline that covers a wide range of fields, including both hardware-level and software-level technologies. The basic technologies of artificial intelligence generally include sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics and other technologies. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, machine learning and / deep learning.

[0018] In one embodiment of the present invention, a method for generating a game map based on artificial intelligence simulation is provided, and the flow chart is as follows: Figure 2 As shown, including: Step 101, generating a basic map based on a template map, wherein the basic map includes game road pixel points and non-road pixel points.

[0019] It is understandable that in order to generate diversified game maps in this embodiment, it is necessary to pre-set diversified template maps in the game system in advance, and generate game maps based on the template maps in real time, thereby achieving the purpose of generating diversified game maps. Among them, the diversity of the template maps pre-set in the game system is mainly reflected in the diversity of game roads in the template maps. Each template map includes game road pixel points and non-road pixel points. Game road pixel points refer to pixel points with terrain attributes of game roads, corresponding to game roads, and non-road pixel points refer to pixel points with terrain attributes of non-roads, corresponding to obstacles in the game process. The shapes of game roads between different template maps are different, so that a rich game terrain map can be provided for game players to improve the fun of the game.

[0020] When initiating the process of this embodiment, when generating a basic map, in one case, a template map can be read, so that the basic map can be obtained by directly enlarging the pixels of the read template map. Specifically, each pixel point in the template map is enlarged to the same multiple.

[0021] For example Figure 3In the template map shown, non-road pixel points correspond to terrain attribute 0, and game road pixel points correspond to terrain attribute 1. Taking the pixel points in the square frame in the figure as an example, each pixel point in the square frame is enlarged into a 4*4 pixel point matrix.

[0022] In other cases, multiple (more than one) template maps can also be read. In this way, multiple template maps can be spliced first. For example, roads can be connected between the game roads in multiple template maps to form a template map of a new game road, and then the template map of the new game road can be pixel-enlarged to form a base map.

[0023] It should be noted that the game map is loaded and displayed on the game terminal in real time based on the user's operations in the game map. In this way, when any game map needs to be loaded, the process of generating the game map can be initiated. During the process of generating the game map, when reading the template map, a template map can be randomly read, or the template map can be read according to the currently actually loaded map, so that the currently loaded map can be connected to the template map, ensuring that the entrances and exits of the currently loaded map and the template map can be connected, making the game coherent before and after, and avoiding non-connected areas in the game map before and after.

[0024] Specifically, a template map can be read based on the exit position of the currently loaded map. The entrance position of the template map corresponds to the exit position of the currently loaded map. For example, if the exit position of the currently loaded map is to leave from the lower right corner position, the entrance position in the read template map needs to enter the template map from the upper side position or the upper left corner position of the template map.

[0025] Step 102, set the density value for adjusting the game road, and randomly adjust the first game road pixel points and the second non-road pixel points in the edge area of the game road in the base map according to the density value to obtain an adjusted map.

[0026] The density value here is mainly a reference value for adjusting each pixel point in the edge area of the game road in the base map. After adjusting the base map with density values of different sizes respectively, the finally adjusted game roads can present different widths. Generally, for a game map with a wider game road, in practical applications, the complexity of executing game tasks is higher, and the time that game players stay in the game is also longer. In this way, game maps with different complexities can be generated by using density values of different sizes.

[0027] Specifically, during random adjustment, multiple rows (such as 4 to 6 rows) of pixel points at the edge of the game road can be selected as the pixel points for random adjustment. These pixel points include the first game road pixel points and the second non-road pixel points. For each of these pixel points, a random number is first given. If the random number is less than the above density value, the pixel point is set as a non-road pixel point. If the random number is greater than or equal to the above density value, the pixel point is set as a game road pixel point. In this way, the higher the density value set above, the narrower the generated road will be, and vice versa, the wider the generated road will be.

[0028] For example Figure 4 In the shown base map, the terrain attribute 0 corresponds to non-road pixel points, and the terrain attribute 1 corresponds to game road pixel points. In this way, 4 rows of pixel points at the edge of the game road are selected as the pixel points in the game road edge area for random adjustment. Among them, two rows of game road pixel points and two rows of non-road pixel points at the edge of the game road can be selected.

[0029] Since the exits and entrances of the base map need to be spliced with other maps, the exit area and the entrance area of the base map are not set as the game road edge area.

[0030] Step 103: Perform terrain aggregation iteration on the game road in the adjusted map to generate an initial game map in the shape of a karst cave.

[0031] Since the pixel points in the game road edge area are randomly adjusted in the above step 102, the positions of some game road pixel points and non-road pixel points in the adjusted map are relatively discrete. The terrain aggregation iteration here is mainly to aggregate the game road pixel points and non-road pixel points in the adjusted map to form a smoother game road. Specifically, multiple strategies can be used for multiple rounds of iteration, including but not limited to the following aggregation strategies to achieve the aggregation of pixel points with the same terrain attribute: Traverse the pixel points in the adjusted map, sample the surrounding pixel points (usually 8 pixel points) of each pixel point in the adjusted map. If more than half of the surrounding pixel points have a different terrain attribute from the current pixel point, the terrain attribute of the current pixel point is set to the terrain attribute of more than half of the surrounding pixel points. For example, if the current pixel point is a game road pixel point and more than half of the surrounding pixel points are non-road pixel points, the current pixel point is set as a non-road pixel point.

[0032] Furthermore, in order to make the game road more tortuous and avoid the edge of the game road being too smooth, during the terrain aggregation iteration process, the following strategies can also be used but are not limited to: If, during consecutive multiple rounds (e.g., two rounds) of terrain aggregation iteration, among the surrounding pixels of a pixel with a certain terrain attribute in the edge area of the game road, no pixel with another terrain attribute appears, set the pixel with a certain terrain attribute to a pixel with another terrain attribute. For example, if during consecutive multiple rounds of terrain aggregation iteration, among the surrounding pixels of a certain game road pixel, there are no non-road pixels, then this game road pixel can be directly set to a non-road pixel. Among them, in order not to have many small non-road pixels appear in the game road after the final iteration, the operation of "setting the pixel with a certain terrain attribute to a pixel with another terrain attribute" will not be placed in the last iteration process, so as to effectively improve the quality of the generated map.

[0033] Furthermore, during the process of terrain aggregation iteration, game task objects can also be set in the game road, such as randomly setting rewards or hidden levels at the end area of a closed game road.

[0034] It should be noted that for the selection of the number of iterations of terrain aggregation iteration, generally a relatively large number of iterations will not be adopted. For example, 3 to 5 iterations. If the number of iterations of terrain aggregation iteration is large, the edge of the game road will be smoother.

[0035] Step 104, simulate the execution of the game task in the initial game map, and obtain the game duration for executing the game task. Adjust the density value set in the above step 102 according to the game duration, so as to re-perform the random adjustment of pixels until the game duration of the generated game map after adjustment is within the set range.

[0036] Specifically, the game system can simulate actual game users to execute game tasks in the initial game map and obtain the game duration. Here, the game duration can refer to the average game duration of simulating different game users to execute game tasks in the initial game map, or the average game duration of simulating the same game user to repeatedly enter the initial game map to execute game tasks. There is no specific limitation here. The benchmark value for adjusting the random adjustment of pixels is the density value set above. Its main purpose is to make the game duration of the generated game map after adjustment be within a certain set range, such as between the minimum threshold and the maximum threshold.

[0037] Specifically, when adjusting the density value, if the game duration is relatively long and greater than a certain maximum threshold, it indicates that the initial game map generated in the above steps is relatively complex. In this case, the density value set in step 102 above can be increased to randomly adjust the pixel points again, making the game roads narrower and simplifying the complexity of the game roads. If the game duration is relatively short and less than a certain minimum threshold, it indicates that the initial game map generated in the above steps is relatively simple. In this case, the density value set in step 102 above can be decreased to randomly adjust the pixel points again, making the game roads wider and increasing the complexity of the game roads.

[0038] It should be noted that in this embodiment, the game duration is used as a parameter to measure the complexity of the generated initial game map. In specific applications, other parameters presented when performing game tasks in the initial game map can also be used to measure the complexity of the initial game map, so as to adjust the set density value based on other parameters. Specific limitations are not provided here.

[0039] Furthermore, to implement the game generation method of this embodiment, multiple template maps can be preset in the game system in advance. Specifically, multiple template maps can be drawn first. Each template map includes game road pixel points and non-road pixel points, and the game roads in different template maps are different. Then, these multiple template maps are stored.

[0040] It can be seen that in the method of this embodiment, based on the preset template maps, an initial game map can be generated through random adjustment based on the density value and terrain aggregation iteration. In this way, by setting diverse template maps in the game system, various game maps can be randomly generated and provided to game players. At the same time, non-connected areas of the game maps generated before and after can be avoided by purposefully reading the template maps. Further, in this embodiment, after the initial game map is generated, the game duration of actually performing game tasks in the initial game map needs to be obtained, and the density value is adjusted through this game duration to readjust the complexity of the game roads. In this way, through the actual usage of the generated initial game map, the readjustment of the game roads is guided, making the generated game map more in line with the actual needs of game users.

[0041] The following uses a specific application example to illustrate the game map generation method in this embodiment, as Figure 5 shown, including: Step 201: Read a template map in the game system and magnify the pixels of the read template map to generate a basic map, which includes game road pixel points and non-road pixel points.

[0042] Step 202: Set the density value for adjusting the game roads.

[0043] Step 203: For any pixel among the first game road pixels and the second non-road pixels in the edge area of the game road in the base map, a random value is given. If the random value is less than the set density value, the pixel is set as a non-road pixel; if the random value is greater than or equal to the density value, the pixel is set as a game road pixel.

[0044] For example Figure 6a As shown, after randomly adjusting each pixel in the edge area, the adjusted map is obtained. In the adjusted map, there are relatively discrete game road pixels and non-road pixels at the edge of the game road.

[0045] Step 204: Perform terrain aggregation iteration on the game road in the adjusted map. During the terrain aggregation iteration process, in consecutive multiple rounds of terrain aggregation iteration, the pixels with relatively smooth edges of the game road are set as pixels with another terrain attribute. After the iteration ends, objects of the game tasks are set in the game road, and thus an initial game map in the shape of a karst cave can be generated.

[0046] Among them, terrain aggregation iteration mainly traverses each pixel in the adjusted map. If among the surrounding pixels of the current pixel, more than half of the pixels have different terrain attributes from the current pixel, the terrain attribute of the current pixel is set to the terrain attribute of more than half of the pixels.

[0047] For example Figure 6b As shown is the map obtained after performing terrain aggregation iteration on the adjusted map shown above. It can be seen that after terrain aggregation iteration, the pixels with the same terrain attribute in the edge area of the game road are aggregated, making the edge area relatively smooth. Figure 6a This is the finally formed initial game map. After randomly adjusting each pixel, the adjusted map is obtained. In the adjusted map, there are relatively discrete game road pixels and non-road pixels at the edge of the game road. Figure 6c

[0048] Step 205: When performing a game task in the initial game map, obtain the game duration for performing the game task, adjust the density value set in Step 202 according to the game duration, and based on the adjusted density value, return to execute Step 203 until the game duration for generating the game map after adjustment is within the set range.

[0049] In this way, through the actual use situation of the generated initial game map, it guides the readjustment of the game road, making the generated game map more in line with the actual needs of game users.

[0050] Figure 7 The embodiment of the present invention also provides a game map generation system based on artificial intelligence simulation, and its structural schematic diagram is as Figure 7As shown, it may specifically include: A basic map unit 10 for generating a basic map based on a template map, where the basic map includes game road pixels and non-road pixels.

[0051] Specifically, the basic map unit 10 can read a preset template map; magnify the pixels of the read template map to obtain the basic map.

[0052] A random adjustment unit 11 for setting a density value for game road adjustment and randomly adjusting the first game road pixels and the second non-road pixels in the edge area of the game road in the basic map generated by the basic map unit 10 according to the density value to obtain an adjusted map.

[0053] Specifically, the random adjustment unit 11 is used to give a random value to any one of the first game road pixels and the second non-road pixels; if the random value is less than the density value, set the any one pixel as a non-road pixel, and if the random value is greater than or equal to the density value, set the any one pixel as a road pixel.

[0054] A terrain iteration unit 12 for performing terrain aggregation iteration on the game road in the adjusted map obtained by the random adjustment unit 11 to generate a cave-like initial game map.

[0055] Specifically, the terrain iteration unit 12 is used to traverse the pixels in the adjusted map. If more than half of the surrounding pixels of the current pixel have different terrain attributes from the current pixel, set the terrain attribute of the current pixel to the terrain attribute of the more than half of the surrounding pixels.

[0056] Further, the terrain iteration unit 12 is also used to, if in consecutive rounds of terrain aggregation iteration, among the surrounding pixels of the pixels with a certain terrain attribute in the edge area of the game road, no pixels with another terrain attribute appear, set the pixels with the certain terrain attribute to pixels with another terrain attribute.

[0057] A density value adjustment unit 13 for simulating and executing a game task in the initial game map obtained by the terrain iteration unit 12, obtaining the game duration of the execution of the game task, and adjusting the density value according to the game duration to re-perform random adjustment of pixels until the game duration of the generated game map after adjustment is within a set range.

[0058] Specifically, the density value adjustment unit 13 is used to, if the game duration is greater than a certain highest threshold, increase the density value to re-perform random adjustment of pixels; if the game duration is less than a certain lowest threshold, decrease the density value to re-perform random adjustment of pixels.

[0059] Furthermore, the system of this embodiment may further include: A template unit 14, which is used to draw a plurality of template maps. Each template map includes game road pixels and non-road pixels, and the game roads in different template maps are different; and store the plurality of template maps. In this way, the above-mentioned basic map unit 10 directly reads at least one template map from the template maps stored in the template unit 14.

[0060] In the system of this embodiment, based on the preset template maps, an initial game map can be generated through random adjustment based on density values and terrain aggregation iteration. In this way, by setting diverse template maps in the game system, various game maps can be randomly generated and provided to game players. At the same time, non-connected areas of the game maps generated before and after can be avoided by purposefully reading template maps; further, in this embodiment, after the initial game map is generated, it is necessary to obtain the game duration of actually performing game tasks in the initial game map, and adjust the density value through this game duration to readjust the complexity of the game roads. In this way, based on the actual usage of the generated initial game map, the readjustment of the game roads is guided, making the generated game map more in line with the actual needs of game users.

[0061] The embodiment of the present invention also provides a terminal device, and its structural schematic diagram is as Figure 8 shown. The terminal device may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPUs) 20 (for example, one or more processors) and a memory 21, and one or more storage media 22 (for example, one or more mass storage devices) for storing application programs 221 or data 222. Among them, the memory 21 and the storage media 22 can be transient storage or persistent storage. The programs stored in the storage media 22 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations for the terminal device. Further, the central processing unit 20 can be set to communicate with the storage media 22 and execute a series of instruction operations in the storage media 22 on the terminal device.

[0062] Specifically, the application program 221 stored in the storage media 22 includes an application program for game map generation, and this program may include the basic map unit 10, the random adjustment unit 11, the terrain iteration unit 12, the density value adjustment unit 13, and the template unit 14 in the above-mentioned game map generation system, which will not be elaborated here. Further, the central processing unit 20 can be set to communicate with the storage media 22 and execute a series of operations corresponding to the application program for game map generation stored in the storage media 22 on the terminal device.

[0063] The terminal device may further include one or more power supplies 23, one or more wired or wireless network interfaces 24, one or more input / output interfaces 25, and / or one or more operating systems 223, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSD TM, and so on.

[0064] The steps performed by the game system in the above method embodiments may be based on the Figure 8 structure of the illustrated terminal device.

[0065] Furthermore, another aspect of the embodiments of the present invention also provides a computer-readable storage medium storing a plurality of computer programs, which are adapted to be loaded and executed by a processor to perform the method for generating a game map based on artificial intelligence simulation as executed by the above game system.

[0066] Another aspect of the embodiments of the present invention also provides a terminal device, including a processor and a memory; The memory is used to store a plurality of computer programs, and the computer programs are used to be loaded and executed by the processor to perform the method for generating a game map based on artificial intelligence simulation as executed by the above game system; the processor is used to implement each of the computer programs in the plurality of computer programs.

[0067] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing relevant hardware through a program, and the program can be stored in a computer-readable storage medium. The storage medium may include: read-only memory (ROM), random access memory (RAM), magnetic disk or optical disc, etc.

[0068] The above has introduced in detail a method, system, and device for generating a game map based on artificial intelligence simulation provided by the embodiments of the present invention. Specific examples are used in this article to elaborate on the principle and implementation manner of the present invention. The description of the above embodiments is only used to help understand the method and its core idea of the present invention; at the same time, for those of ordinary skill in the art, according to the idea of the present invention, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present invention.

Claims

1. A method for generating a game map based on artificial intelligence simulation, characterized in that, Including: Generating a base map based on a template map, where the base map includes game road pixels and non-road pixels; Setting a density value for adjusting the game road, and randomly adjusting the first game road pixels and the second non-road pixels in the edge area of the game road in the base map according to the density value to obtain an adjusted map; Performing terrain aggregation iteration on the game road in the adjusted map to generate an initial game map in the shape of a karst cave; Simulating and executing a game task in the initial game map, obtaining the game duration of executing the game task, and adjusting the density value according to the game duration to re-perform random adjustment of pixels until the game duration of the generated game map is within a set range.

2. The method according to claim 1, characterized in that, The generating the base map based on the template map includes: Reading a preset template map; Enlarging the pixels of the read template map to obtain the base map.

3. The method according to claim 1, wherein The randomly adjusting the first game road pixels and the second non-road pixels in the edge area of the game road in the base map according to the density value specifically includes: Giving a random value to any one of the first game road pixels and the second non-road pixels; If the random value is less than the density value, setting the any one pixel as a non-road pixel, and if the random value is greater than or equal to the density value, setting the any one pixel as a game road pixel.

4. The method according to claim 1, wherein, The performing terrain aggregation iteration on the game road in the adjusted map specifically includes: Traversing the pixels in the adjusted map, and if more than half of the surrounding pixels of the current pixel have different terrain attributes from the current pixel, setting the terrain attribute of the current pixel as the terrain attribute of the more than half of the surrounding pixels.

5. The method according to claim 4, characterized in that, Before generating the initial game map in the shape of a karst cave, it further includes: If in consecutive multiple rounds of terrain aggregation iteration, among the surrounding pixels of the pixels with a certain terrain attribute in the edge area of the game road, no pixels with another terrain attribute appear, setting the pixels with the certain terrain attribute as pixels with another terrain attribute.

6. The method according to claim 5, characterized in that The number of terrain aggregation iterations is 3 - 5 times, and the step of setting the pixels with a certain terrain attribute as pixels with another terrain attribute will not be placed in the last iteration process.

7. The method according to any one of claims 1 to 6, characterized in that The adjusting the density value according to the game duration specifically includes: If the game duration is greater than a certain highest threshold, increasing the density value to re-perform random adjustment of pixels; If the game duration is less than a certain lowest threshold, decreasing the density value to re-perform random adjustment of pixels.

8. The method according to any one of claims 1 to 6, characterized in that The method further includes: Drawing a plurality of template maps, each template map including game road pixels and non-road pixels, and the game roads in different template maps are different; Storing the plurality of template maps.

9. A game map generation system based on artificial intelligence simulation, characterized in that, Including: A base map unit for generating a base map based on a template map, where the base map includes game road pixels and non-road pixels; A random adjustment unit, configured to set a density value for adjusting the game road, and randomly adjust the first game road pixel points and the second non-road pixel points in the edge area of the game road in the base map according to the density value to obtain an adjusted map; A terrain iteration unit, configured to perform terrain aggregation iteration on the game road in the adjusted map to generate an initial game map in the shape of a karst cave; A density value adjustment unit, configured to simulate and execute a game task in the initial game map, obtain the game duration of the executed game task, adjust the density value according to the game duration, and re-perform random adjustment of pixel points until the game duration of the generated game map after adjustment is within a set range.

10. A terminal device, characterized in that, It includes a processor and a memory; The memory is used to store a plurality of computer programs, and the computer programs are used to be loaded and executed by the processor to perform the method for generating a game map based on artificial intelligence simulation according to any one of claims 1 to 8; the processor is used to implement each computer program in the plurality of computer programs.

Citation Information

Patent Citations

  • Map generation method and device, computer equipment and storage medium

    CN116212395A

  • Game processing method and device, electronic equipment, storage medium and program product

    CN120019841A