A game map drawing method and related equipment

By having the game client draw its own map and provide interactive services, it solves the problems of difficult map personalization and slow interaction speed in existing technologies, and achieves improved cost-effectiveness and user experience.

CN115063543BActive Publication Date: 2025-09-23NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210457851.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-28
Publication Date
2025-09-23
Estimated Expiration
2042-04-28

AI Technical Summary

Technical Problem

Existing game terminals rely on third-party map data suppliers to draw maps, which makes it difficult to meet personalized needs, has slow interaction speeds, and high development and maintenance costs.

Method used

The game client draws its own map of the predetermined geographical area and provides interactive services, reducing dependence on third-party map data suppliers.

Benefits of technology

It reduces the development and maintenance costs of LBS gameplay and improves the speed of human-computer interaction and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115063543B_ABST
    Figure CN115063543B_ABST
Patent Text Reader

Abstract

This application provides a game map drawing method and related equipment, relating to the field of computer technology. The method includes a client obtaining geographic location information of a user terminal. The client determines, based on the geographic location information, that the user terminal is in a predetermined geographic area. Based on the determination result, the client obtains map data for the predetermined geographic area. The client draws a game map of the predetermined geographic area based on the map data for the predetermined geographic area. The client displays the game map to the user terminal. This application independently draws a game map of the predetermined geographic area based on map data provided by a map data source and provides interactive services based on the game map. This reduces development costs while also improving the speed of human-computer interaction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a game map drawing method and related equipment. Background Art

[0002] Games based on location-based services (LBS) have been gaining popularity in recent years, consistently topping the charts in various regions. LBS can be simply understood as mobile location-based services, integrating mobile communication technology, social gaming, and location-based LBS functionality. Specifically, LBS revolves around virtual items in a real-world location. When a game user moves to a predetermined geographic area, game tasks related to that area appear on the game console for the user to complete.

[0003] In games that provide LBS gameplay, the game terminal needs to provide maps of each predetermined geographical area and allow game users to interact with the map. Existing game terminals all rely on third-party map data suppliers to provide maps and interactive services. The game terminal can only control the display style of the map. Specifically, the third-party map data supplier draws a map of each predetermined geographical area, and then provides the map texture to the game terminal, which then displays the texture to the game user. When the user sends an interactive operation to the map, the game terminal also needs to forward the interactive operation to the third-party map data supplier, and then the third-party map data supplier performs the relevant operation on the map, and finally sends the texture of the operation result to the game terminal.

[0004] Because the maps displayed on the game side are drawn by third-party map data providers, it is difficult to meet the personalized needs of the game side. Furthermore, when game users need to interact with the map, they must rely on the API interface provided by the third-party map data provider to transmit commands, which greatly increases response time and leads to slow interaction. Furthermore, the third-party map data provider must be compatible with the game side. Any changes to the LBS gameplay require coordinated modifications to the game side and the third-party map data provider's programs, which greatly increases the development and maintenance cycle of LBS gameplay and the difficulty of daily maintenance and updates. Summary of the Invention

[0005] In view of this, the present application provides a map drawing method and related equipment. The game client draws a game map of a predetermined geographical area based on a map data source, and provides interactive services based on the game map to game users. In this way, game users can interact directly with the client, saving game development costs while also improving the speed of human-computer interaction.

[0006] A first aspect of an embodiment of the present application provides a map drawing method, the method comprising:

[0007] The client obtains the user's geographic location information.

[0008] The client determines that the user terminal is in a predetermined geographical area based on the geographical location information.

[0009] The client obtains map data of a predetermined geographical area according to the determination result.

[0010] The client draws a game map of the predetermined geographical area based on the map data of the predetermined geographical area.

[0011] The client displays the game map to the user.

[0012] In an optional embodiment, there is at least one task object on the game map. The map drawing method further includes:

[0013] The client receives an operation instruction from the user terminal for at least one task object.

[0014] The client displays a task interface corresponding to at least one task object according to the operation instruction.

[0015] In an optional implementation, the geographical location information of the user terminal includes the latitude and longitude information of the user terminal.

[0016] The client determines that the user terminal is in a predetermined geographical area based on the geographical location information, including:

[0017] The client obtains the latitude and longitude information of the default location of the predetermined geographic area.

[0018] The client determines, based on the latitude and longitude information of the user terminal and the latitude and longitude information of the default location, that the distance between the user terminal and the default location is less than a preset distance threshold.

[0019] The client determines that the user terminal is in a predetermined geographical area according to the determination result.

[0020] In an optional embodiment, the map data of the predetermined geographical area includes data information of at least one type of map element.

[0021] The client draws a game map of the predetermined geographical area based on the map data of the predetermined geographical area, including:

[0022] The client determines a drawing batch for each map element type in at least one map element type, wherein the drawing batch is used to describe the map drawing order of the client.

[0023] The client draws the area corresponding to each type of map element in the game map in sequence according to the drawing batch of each type of map element.

[0024] In an optional embodiment, the client sequentially draws the area range corresponding to each type of map element in the game map, including:

[0025] The client determines a vertex list corresponding to each type of map element and a vertex connection order corresponding to the vertex list based on data information of at least one type of map element.

[0026] The client determines the position of each vertex in the vertex list on the game map.

[0027] The client determines and draws the area range corresponding to each type of map element in the game map based on the position of each vertex in the game map and the order of vertex connection.

[0028] In an optional embodiment, the game map includes coordinates of default positions, and the client determines the position of each vertex in the vertex list in the game map, including:

[0029] The client determines the longitude and latitude information corresponding to each vertex.

[0030] The client determines the relative distance between each vertex and the default location based on the latitude and longitude information corresponding to each vertex and the latitude and longitude information of the default location.

[0031] The client determines the coordinates corresponding to each vertex based on the coordinates and relative distance of the default position in the game map.

[0032] In an optional embodiment, the client determines the coordinates corresponding to each vertex based on the coordinates and relative distance of the default position in the game map, including:

[0033] The client determines the scaling factor.

[0034] The client determines the relative coordinate distance of each vertex from the default position based on the zoom factor and relative distance.

[0035] The client determines the coordinates of each vertex based on the coordinates of the default position and the relative coordinate distance.

[0036] In an optional embodiment, the method further comprises:

[0037] Determine the name and identification of at least one target object in each type of map element.

[0038] Mark at least one target object on the game map.

[0039] In an optional embodiment, the method further comprises:

[0040] The client determines the rendering mode.

[0041] The client processes the game map according to the rendering mode.

[0042] The client displays the game map to the user, including:

[0043] The client displays the processed game map to the user.

[0044] In an optional embodiment, the rendering mode includes color rendering, animation rendering, or special effect rendering.

[0045] A second aspect of an embodiment of the present application provides a client device, the device comprising:

[0046] The acquisition unit is used to obtain the geographical location information of the user terminal.

[0047] The determining unit is configured to determine, based on the geographical location information, whether the user terminal is in a predetermined geographical area.

[0048] The determination unit is further configured to obtain map data of a predetermined geographical area according to the determination result.

[0049] The processing unit is used to draw a game map of the predetermined geographical area according to the map data of the predetermined geographical area.

[0050] The display unit is used to display the game map to the user terminal.

[0051] In an optional embodiment, there is at least one task object on the game map. The device further includes a receiving unit.

[0052] The receiving unit is configured to receive an operation instruction from a user terminal for at least one task object.

[0053] The display unit is further used to display a task interface corresponding to at least one task object according to the operation instruction.

[0054] In an optional implementation, the geographical location information of the user terminal includes the latitude and longitude information of the user terminal.

[0055] The acquiring unit is further configured to acquire the latitude and longitude information of a default location of a predetermined geographical area.

[0056] The determining unit is specifically configured to determine, based on the latitude and longitude information of the user terminal and the latitude and longitude information of the default location, whether the distance between the user terminal and the default location is less than a preset distance threshold, and determine, based on the determination result, that the user terminal is in a predetermined geographical area.

[0057] In an optional embodiment, the map data of the predetermined geographical area includes data information of at least one type of map element.

[0058] The processing unit is specifically configured to determine a drawing batch for each of at least one type of map element. The drawing batch describes the order in which the map is drawn. Based on the drawing batch for each type of map element, the area corresponding to each type of map element is sequentially drawn on the game map.

[0059] In an optional embodiment, the determining unit is further configured to determine, based on data information of at least one type of map element, a vertex list corresponding to each type of map element and a vertex connection order corresponding to the vertex list, and determine a position of each vertex in the vertex list on the game map.

[0060] The processing unit is specifically used to determine and draw the area range corresponding to each type of map element in the game map according to the position of each vertex in the game map and the vertex connection order.

[0061] In an optional embodiment, the game map includes coordinates of a default location, and the determination unit is specifically configured to determine the longitude and latitude information corresponding to each vertex. The relative distance between each vertex and the default location is determined based on the longitude and latitude information corresponding to each vertex and the longitude and latitude information of the default location. The coordinates corresponding to each vertex are determined based on the coordinates of the default location in the game map and the relative distance.

[0062] In an optional embodiment, the determining unit is specifically configured to determine a scaling factor, determine a relative coordinate distance between each vertex and a default position based on the scaling factor and the relative distance, and determine the coordinates of each vertex based on the coordinates of the default position and the relative coordinate distance.

[0063] In an optional embodiment, the determining unit is further configured to determine a name identifier of at least one target object in each type of map element.

[0064] The processing unit is further used to mark the name of at least one target object in the game map.

[0065] In an optional implementation, the determining unit is further configured to determine a rendering mode.

[0066] The processing unit is also used to process the game map according to the rendering mode.

[0067] The display unit is used to display the processed game map to the user terminal.

[0068] In an optional embodiment, the rendering mode includes color rendering, animation rendering, or special effect rendering.

[0069] A third aspect of an embodiment of the present application further provides a server, including: a memory and a processor, wherein the memory and the processor are coupled.

[0070] The memory is used to store one or more computer instructions.

[0071] The processor is used to execute one or more computer instructions to implement the map drawing method described in the first aspect above.

[0072] The fifth aspect of the embodiment of the present application also provides a computer-readable storage medium on which one or more computer instructions are stored, characterized in that the instruction is executed by a processor to implement the map drawing method described in any of the above technical solutions.

[0073] According to the technical solution provided by the embodiment of the present application, the client needs to monitor the geographical location information of the user terminal. When it is detected that the user terminal is in a predetermined geographical area, it is necessary to draw a game map of the predetermined geographical area. Specifically, the client can obtain map data of the predetermined geographical area from the map database, and then draw and display the game map based on the obtained map data. Since the client can draw the game map by itself and can interact directly with the user terminal, there is no need for a third-party map data supplier to provide interactive services for the game map, which greatly reduces the development cost of the LBS gameplay. At the same time, there is no need to consider the compatibility issues between the client and the third-party map data supplier. Subsequent version updates and modifications can directly modify the client program, thereby greatly reducing the cost and difficulty of daily maintenance and updates of the LBS gameplay. At the same time, the client can also provide personalized LBS gameplay according to demand, greatly improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0074] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments of the present application. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0075] Figure 1 This is a flowchart of a map drawing method provided in an embodiment of the present application;

[0076] Figure 2 A flowchart of another map drawing method provided in an embodiment of the present application;

[0077] Figure 3 A schematic diagram of the structure of a client device provided in an embodiment of the present application;

[0078] Figure 4A schematic diagram of the structure of a client server provided in an embodiment of the present application. DETAILED DESCRIPTION

[0079] This application provides a map drawing method and related equipment. The game client draws a game map of a predetermined geographical area based on a map data source and provides interactive services based on the game map to game users. In this way, game users can interact directly with the game client, saving game development costs while also speeding up human-computer interaction.

[0080] In order to enable those skilled in the art to better understand the technical solutions of this application, the following clearly and completely describes this application in conjunction with the drawings in the embodiments of this application. However, this application can be implemented in many other ways different from the above description. Therefore, based on the embodiments provided in this application, all other embodiments obtained by those skilled in the art without creative work should fall within the scope of protection of this application.

[0081] It should be noted that the terms "first", "second", "third", etc. in the claims, description and drawings of the present application are used to distinguish similar objects and are not used to describe a specific order or sequence. The data used in this way are interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in a sequence other than that illustrated or described herein. In addition, the terms "including", "having" and their variations are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0082] Games based on location-based services (LBS) have been gaining popularity in recent years, consistently topping the charts in various regions. LBS can be simply understood as mobile location-based services, integrating mobile communication technology, social gaming, and location-based LBS functionality. Specifically, LBS revolves around virtual items in a real-world location. When a game user moves to a predetermined geographic area, game tasks related to that area appear on the game console for the user to complete.

[0083] For example, LBS gameplay can be centered around the user's city, with various virtual activities taking place in different areas of the city. When a user moves to a certain area, they can participate in that area's virtual activities, such as "killing monsters" with other users in the area or participating in the area's "limited-time gold coin" event. Understandably, if a user is not in the area, they cannot participate in that area's activities. Therefore, LBS gameplay is a powerful attempt to enhance the social nature of the game itself, strengthening social interaction among players in the same area and improving the user experience.

[0084] In games that provide LBS gameplay, the game terminal needs to provide game maps for each predetermined geographical area and need to allow game users to interact with the game map. Existing game terminals all rely on third-party map data suppliers to provide game maps and interactive services. The game terminal can only control the display style of the map. Specifically, the third-party map data supplier draws the game map of each predetermined geographical area, and then provides the game terminal with a texture of the game map, which then displays the texture to the game user. When the user sends an interactive operation to the game map, the game terminal also needs to forward the interactive operation to the third-party map data supplier, and then the third-party map data supplier performs the relevant operation on the game map, and finally sends the texture of the operation result to the game terminal.

[0085] Because the game maps displayed on the game side are drawn by third-party map data providers, it is difficult to meet the personalized needs of the game side. At the same time, when game users need to interact with the game map, they need to rely on the API interface provided by the third-party map data provider to transmit commands, which will greatly increase response time and lead to slow interaction. Third-party map data providers also need to be compatible with the game side. When any changes are made to the LBS gameplay, the programs of the game side and the third-party map data provider need to be modified in conjunction, which greatly increases the development and maintenance cycle of LBS gameplay and the difficulty of daily maintenance and updates. Therefore, how to more efficiently provide game maps and game map-specific services has become a problem that needs to be solved in LBS gameplay.

[0086] To address the above issues, this application provides a map-drawing method and related devices. A game client automatically draws a game map of a predetermined geographic area based on a map data source and directly provides interactive services based on the game map to game users. This reduces game development costs while improving the speed of human-computer interaction. The method, device, terminal, and computer-readable storage medium described in this application are further described in detail below, with reference to specific embodiments and accompanying drawings.

[0087] Figure 1 This is a flowchart of a map drawing method provided in an embodiment of the present application. Figure 1As shown, the map drawing method includes the following steps:

[0088] 101. The client obtains the geographic location information of the user.

[0089] The client is the service provider. When providing LBS-based services, it needs to monitor the user's geographic location. When the user moves into a predetermined geographic area, it needs to display a game map of that area to the user, allow the user to interact with the map, and provide related services based on the interaction.

[0090] For example, the client can be a game provider, and the user end can be each game player. The game provider can provide LBS gameplay based on the game player's current geographic location. For example, when a game player is in Beijing, the game provider needs to display a map of Beijing and provide a game copy corresponding to Beijing. The game player can operate on the map of Beijing, and the provider needs to display the content of the game copy based on the game player's operation. If the game provider moves from Beijing to Guangzhou, the game provider needs to display a map of Guangzhou and provide a game copy corresponding to Guangzhou. At this time, the game player in Guangzhou can no longer play the game copy corresponding to Beijing and can only play the game copy corresponding to Guangzhou.

[0091] 102. The client determines, based on the geographic location information, that the user terminal is in a predetermined geographic area.

[0092] Based on the above description, the client provides specific business services based on LBS. Therefore, the client needs to obtain the location of the user terminal and then provide business services based on the current location of the client. For example, the client can obtain the longitude and latitude information of the user terminal from the positioning system, and then the longitude and latitude information of the default location of the predetermined geographical area. Then, the longitude and latitude information of the user terminal is compared with the longitude and latitude information of the default location. When the distance between the user terminal and the default location is less than a preset distance threshold, it is determined that the user terminal has entered the predetermined geographical area.

[0093] Taking the game scene as an example, when designing LBS gameplay, the game provider will provide game services based on multiple predetermined geographical locations. For example, different game copies can be provided based on different cities. Different cities will first determine a default location, such as the Canton Tower in Guangzhou or the Bell Tower in Xi'an. When the game provider obtains the current latitude and longitude information of the user terminal, it can compare it with the latitude and longitude information of the Canton Tower to determine the distance between the user terminal and the Canton Tower. If the distance between the user terminal and the Canton Tower is less than the preset distance threshold, it means that the user terminal has entered the Guangzhou area, and the game provider needs to provide a map of the Guangzhou area and a game copy based on the Guangzhou map. If the distance between the user terminal and the Canton Tower is greater than the preset distance threshold, it means that the user terminal has not entered the Guangzhou area or has left the Guangzhou area, and the game provider will prohibit the user terminal from playing the game copy based on the Guangzhou map.

[0094] 103. The client obtains map data of the predetermined geographical area according to the determination result.

[0095] When the client determines that the user is in a predetermined geographic area, it needs to display a map of the predetermined geographic area and provide business services based on the map of the predetermined geographic area. In this embodiment of the application, the client no longer displays a two-dimensional map drawn by a third-party map data provider, but instead draws its own game map of the predetermined geographic area based on the map data source. It also directly provides interactive services based on the game map to game users.

[0096] For example, the client can obtain map data for a predetermined geographic area from a map database. The map database can provide data information for various map element types within the predetermined geographic area. Map element types refer to elements such as buildings, grasslands, water bodies, flat land, and roads contained in the map. The client needs to obtain the outline information, location information, and other information for each map element type before drawing the game map based on the information for each map element type.

[0097] 104. The client draws a game map of the predetermined geographical area based on the map data of the predetermined geographical area.

[0098] After acquiring data for each map element type, the client can use its own graphics rendering interface to draw the game map. Game maps can be either two-dimensional or three-dimensional. This significantly reduces the development cost of LBS gameplay by eliminating the need for client-side compatibility with third-party map data providers. Subsequent version updates and modifications can be made directly to the client program, significantly reducing the cost and difficulty of routine maintenance and updates for LBS gameplay. Furthermore, its own graphics rendering interface allows for easy customization of maps for personalized presentation, streamlining the workflow for stylized map development and significantly improving development efficiency.

[0099] For example, the client can draw a game map centered on a default location in a predetermined geographic area. First, the relative position of a map element type to the default location and the outline of the map element type are determined. Then, the game map is drawn based on the relative position, the outline of the map element type, and the area occupied by the map element type. Finally, a business service based on the map element type is designed.

[0100] For example, in a game scenario, you can use the Guangzhou Tower as the origin and draw the buildings, roads, rivers, and parks near the Guangzhou Tower. Then, you can design game copies based on the types of map elements. For example, you can design a "kill monsters and level up" game activity at a certain building, and design a "get gold coins" game copy next to a river. The final game map can receive user operation instructions. For example, the user can click on the building to enter the "kill monsters and level up" game scene. Or double-click on the river. You can team up with other players in the same city to complete the "get gold coins" game task. It is understandable that different business services can be designed for game scenarios based on needs, and this is not limited here.

[0101] 105. The client displays the game map to the user.

[0102] After the client draws the game map, it needs to be displayed to the user. For example, the client can determine the rendering mode based on user needs. The game map is then personalized based on the rendering mode. Finally, the processed game map is displayed. Rendering methods include color rendering, animation rendering, and special effects rendering, which are not limited here.

[0103] Taking the game scene as an example, the game supplier can render the game map based on the game's design color, such as determining the color of the game map, adding dynamic special effects to the game map, or unifying the design of each element in the game map, etc., without limitation here.

[0104] 106. The client receives an operation instruction from the user terminal for at least one task object.

[0105] It is understandable that the client not only needs to display the game map for the user, but also needs to provide interactive services for the game map. For example, there are task objects on the game map. The client can receive user operations related to the task object and then display the task interface corresponding to the task object.

[0106] In the above game scenario, a building on the map offers a "kill monsters and level up" game activity, while a "get gold coins" game instance is located next to a river. Users can click on the building to enter the "kill monsters and level up" game scenario. Alternatively, double-clicking on the river allows them to team up with other players in the same city to complete the "get gold coins" game mission. As you can see, different business services can be designed for different game scenarios based on specific needs, and this is not a limitation here.

[0107] 107. The client displays a task interface corresponding to at least one task object according to the operation instruction.

[0108] After receiving the operation instruction sent by the client, the task interface corresponding to the task object is required to provide specific business services to the user end.

[0109] According to the technical solution provided by the embodiment of the present application, the client needs to monitor the geographical location information of the user terminal. When it is detected that the user terminal is in a predetermined geographical area, it is necessary to draw a game map of the predetermined geographical area. Specifically, the client can obtain map data of the predetermined geographical area from the map database, and then draw and display the game map based on the obtained map data. Since the client can draw the game map by itself and can interact directly with the user terminal, there is no need for a third-party map data supplier to provide interactive services for the game map, which greatly reduces the development cost of the LBS gameplay. At the same time, there is no need to consider the compatibility issues between the client and the third-party map data supplier. Subsequent version updates and modifications can directly modify the client program, thereby greatly reducing the cost and difficulty of daily maintenance and updates of the LBS gameplay. At the same time, the client can also provide personalized LBS gameplay according to demand, greatly improving the user experience.

[0110] The following is a detailed introduction to the client's drawing process of the game map. Figure 2 A flowchart of another map drawing method provided in an embodiment of the present application is shown as follows: Figure 2 As shown, the map drawing method includes the following steps:

[0111] 201. The client obtains data information of the map element type.

[0112] It is understandable that when the client provides LBS-based business services, it is necessary to first monitor the user's geographical location. When the user is detected to have moved into a predetermined geographical area, a game map of the predetermined geographical area needs to be displayed to the user, and the user needs to be allowed to interact with the game map and provide related services based on the interactive operations.

[0113] The client needs to obtain map data for a predetermined geographic area. This map data includes data information for various map element types. Map element types refer to elements such as buildings, grasslands, water bodies, flat land, and roads within the map. The client needs to obtain the outline and location information for each map element type and use this data to draw the game map.

[0114] 202. The client determines the vertex list corresponding to the map element type and the vertex connection order corresponding to the vertex list based on the data information of the map element type.

[0115] For example, the client can obtain a vertex list and vertex connection order for each type of map element from the map database. The vertex list is used to describe the basic outline of each type of map element. For example, if the map element type is a building, then it is necessary to determine the various prominent points (vertices) of the building's top view. By connecting the prominent points, the basic outline of the building can be obtained. Furthermore, if the coordinates of each vertex of the building can be determined, the building can be drawn on the map.

[0116] The map database provides a vertex list corresponding to each map element type, which records the longitude and latitude of each vertex. The client can obtain the longitude and latitude of each vertex corresponding to a map element type, convert the longitude and latitude information of each vertex into map coordinates, determine the position of each vertex on the map, and finally connect the vertices according to the vertex connection order to draw the map element on the map. Finally, each map element is drawn in sequence, and the game map is finally obtained.

[0117] 203. The client determines the position of each vertex in the vertex list in the game map.

[0118] For example, the client can determine the position of each vertex in the game map based on the coordinates of the default position. The client can determine the default position as the origin of the game map. The client then obtains the longitude and latitude distance between each vertex and the default position, and then multiplies the longitude and latitude distance by a scaling factor to obtain the relative coordinate distance. Finally, the coordinates of each vertex are determined based on the coordinates of the default position (origin) and the relative coordinate distance.

[0119] For example, a building is located 1000 meters northwest of the default position at 45 degrees. The building has four vertices, and its length and width are both 20 meters. If the scaling factor is determined to be 100, if the coordinates of the default position are (0, 0), then the coordinates of the center point of the building are approximately (-32, 32), and the coordinates of the corresponding four vertices are (-32.2, 31.8), (-31.8, 31.8), (-32.2, 32.2), (-31.8, 32.2). After the client determines the position of each vertex on the game map, it connects the vertices in order to draw the map element. It can be understood that the basic outline and location information of each map element can be displayed on the game map, so that business services can be designed based on each map element.

[0120] 204. The client determines and draws the area range corresponding to the map element type in the game map according to the position of each vertex in the game map and the vertex connection order.

[0121] Finally, the client draws each map element on the game map in turn, completes the drawing of the entire game map, and finally displays the drawn game map to the user.

[0122] For example, after the client draws the game map, it needs to be displayed to the user. The client can determine the rendering mode based on user needs. The game map is then personalized based on the rendering mode. Finally, the processed game map is displayed. Rendering methods include color rendering, animation rendering, or special effects rendering, which are not limited here. Taking the game scene as an example, the game provider can render the game map based on the game's design color, such as determining the color of the game map, adding dynamic special effects to the game map, or unifying the design of each element in the game map, etc., which are not limited here.

[0123] It is understandable that the game map includes multiple types of map elements, and each type of map element may include multiple target objects. For example, a building element may include multiple buildings, a river element may include multiple rivers, a road element may include multiple roads, and so on. During the map drawing process, the client can draw each type of map element in batches. The drawing batch is used to describe the map drawing order of the client. In a preferred example, the client needs to draw all the target objects included in one type of map element in the same batch. After drawing one type of map element, the next type of map element will be drawn. In other words, the client can draw all the buildings first and then the rivers, and after drawing all the rivers, the roads, and so on. This is because the drawing method and rendering method of the same type of map element are the same, so when drawing multiple target objects of the same type of map element, the processor does not need to adjust the drawing method and rendering method. This can reduce the switching frequency of the processor, thereby reducing the pressure on the processor.

[0124] For example, when drawing a map element type, it is also necessary to determine the name identifier of at least one target object in the map element type, and then mark the name identifier of the target object once on the game map.

[0125] Figure 3 A schematic diagram of the structure of a client device provided in an embodiment of the present application is shown below. Figure 3 The embodiments provided in this embodiment are described in detail. The embodiments described below are used to explain the technical solutions of this application and are not intended to be limiting in actual use.

[0126] The client device includes:

[0127] The acquisition unit 301 is configured to acquire geographic location information of a user terminal.

[0128] The determining unit 302 is configured to determine, based on the geographical location information, whether the user terminal is in a predetermined geographical area.

[0129] The determining unit 302 is further configured to obtain map data of a predetermined geographical area according to the determination result.

[0130] The processing unit 303 is configured to draw a game map of the predetermined geographical area according to the map data of the predetermined geographical area.

[0131] The display unit 304 is used to display the game map to the user terminal.

[0132] In an optional embodiment, there is at least one task object on the game map. The device further includes a receiving unit 305 .

[0133] The receiving unit 305 is configured to receive an operation instruction from a user terminal for at least one task object.

[0134] The display unit 304 is further configured to display a task interface corresponding to at least one task object according to the operation instruction.

[0135] In an optional implementation, the geographical location information of the user terminal includes the latitude and longitude information of the user terminal.

[0136] The acquiring unit 301 is further configured to acquire the latitude and longitude information of a default location of a predetermined geographical area.

[0137] The determining unit 302 is specifically configured to determine, based on the latitude and longitude information of the user terminal and the latitude and longitude information of the default location, whether the distance between the user terminal and the default location is less than a preset distance threshold, and to determine, based on the determination result, that the user terminal is in a predetermined geographical area.

[0138] In an optional embodiment, the map data of the predetermined geographical area includes data information of at least one type of map element.

[0139] Processing unit 303 is specifically configured to determine a drawing batch for each of at least one type of map element. A drawing batch describes the order in which the map is drawn. Based on the drawing batch for each type of map element, the area corresponding to each type of map element is sequentially drawn on the game map.

[0140] In an optional embodiment, the determining unit 302 is further configured to determine, based on data information of at least one type of map element, a vertex list corresponding to each type of map element and a vertex connection order corresponding to the vertex list, and determine a position of each vertex in the vertex list on the game map.

[0141] The processing unit 303 is specifically configured to determine and draw an area range corresponding to each type of map element in the game map according to the position of each vertex in the game map and the vertex connection order.

[0142] In an optional embodiment, the game map includes coordinates of a default location, and the determination unit 302 is specifically configured to determine the longitude and latitude information corresponding to each vertex. Based on the longitude and latitude information corresponding to each vertex and the longitude and latitude information of the default location, the relative distance between each vertex and the default location is determined. Based on the coordinates of the default location in the game map and the relative distance, the coordinates corresponding to each vertex are determined.

[0143] In an optional embodiment, the determining unit 302 is specifically configured to determine a scaling factor, determine a relative coordinate distance between each vertex and the default position based on the scaling factor and the relative distance, and determine the coordinates of each vertex based on the coordinates of the default position and the relative coordinate distance.

[0144] In an optional implementation, the determining unit 302 is further configured to determine a name identifier of at least one target object in each type of map element.

[0145] The processing unit 303 is further configured to mark the name of at least one target object in the game map.

[0146] In an optional implementation, the determining unit 302 is further configured to determine a rendering mode.

[0147] The processing unit 303 is further configured to process the game map according to the rendering mode.

[0148] The display unit 304 is used to display the processed game map to the user terminal.

[0149] In an optional embodiment, the rendering mode includes color rendering, animation rendering, or special effect rendering.

[0150] The client device provided in the embodiment of the present application needs to monitor the geographic location information of the user terminal. When it is detected that the user terminal is in a predetermined geographic area, it is necessary to draw a game map of the predetermined geographic area. Specifically, the acquisition unit can obtain the map data of the predetermined geographic area from the map database, and then draw the game map and display it based on the acquired map data. Since the client device can draw the game map by itself and can interact directly with the user terminal, there is no need for a third-party map data supplier to provide interactive services for the game map, which greatly reduces the development cost of the LBS gameplay. At the same time, there is no need to consider the compatibility issues between the client device and the third-party map data supplier. Subsequent version updates and modifications can directly modify the client program, which greatly reduces the cost and difficulty of daily maintenance and updates of the LBS gameplay. At the same time, the client can also provide personalized LBS gameplay according to demand, greatly improving the user experience.

[0151] It should be noted that the information interaction, execution process, etc. between the modules / units in the device are the same as those in this application. Figures 1 to 2 The corresponding method embodiments are based on the same concept. For specific contents, please refer to the description in the method embodiments shown above in this application, which will not be repeated here.

[0152] Next, we introduce a client server provided by the embodiment of the present application. Figure 4 , Figure 4 A schematic diagram of the structure of the client server provided in the embodiment of the present application. Figure 3 The client device described in the corresponding embodiment is used to implement Figures 1 to 2Specifically, the client server 800 includes: a receiver 801, a transmitter 802, a processor 803 and a memory 804 (wherein the number of the processor 803 in the client server 800 can be one or more, Figure 4 (taking one processor as an example), the processor 803 may include an application processor 8031 ​​and a communication processor 8032. In some embodiments of the present application, the receiver 801, the transmitter 802, the processor 803 and the memory 804 may be connected via a bus or other means.

[0153] The memory 804 may include a read-only memory and a random access memory, and provides instructions and data to the processor 803. A portion of the memory 804 may also include non-volatile random access memory (NVRAM). The memory 804 stores processor and operation instructions, executable modules, or data structures, or subsets or extended sets thereof. The operation instructions may include various operation instructions for implementing various operations.

[0154] Processor 803 controls the operation of the client server. In specific applications, the various components of the client server are coupled together via a bus system. In addition to a data bus, the bus system may also include a power bus, a control bus, and a status signal bus. However, for clarity, all bus systems are referred to as a bus system in the figure.

[0155] The methods disclosed in the above embodiments of the present application can be applied to or implemented by the processor 803. The processor 803 can be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by hardware integrated logic circuits or software instructions in the processor 803. The above processor 803 can be a general-purpose processor, a digital signal processing (DSP), a microprocessor, or a microcontroller, and can further include an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The processor 803 can implement or execute the various methods, steps, and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of the present application can be directly implemented and executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium well-known in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. The storage medium is located in memory 804, and processor 803 reads information in memory 804 and, in conjunction with its hardware, completes the steps of the above method.

[0156] Receiver 801 can be used to receive input digital or character information and generate signal input related to client server settings and function control. Transmitter 802 can be used to output digital or character information through the first interface. Transmitter 802 can also be used to send instructions to the disk group through the first interface to modify data in the disk group. Transmitter 802 can also include a display device such as a display screen.

[0157] In the embodiment of the present application, the application processor 8031 ​​in the processor 803 is used to execute Figures 1 to 2 The map drawing method in the corresponding embodiment. It should be noted that the specific manner in which the application processor 8031 ​​executes each step is different from the specific manner in which the application processor 8031 ​​executes each step. Figures 1 to 2 The corresponding method embodiments are based on the same concept, and the technical effects they bring are the same as those in this application. Figures 1 to 2 The corresponding method embodiments are the same. For specific contents, please refer to the description in the method embodiments shown above in this application, which will not be repeated here.

[0158] An embodiment of the present application provides a computer-readable storage medium, which includes computer instructions. When the computer instructions are executed by a processor, they are used to implement the technical solution of any one of the map drawing methods in the embodiments of the present application.

[0159] The present application also provides a computer program product which, when executed on a computer, enables the computer to execute the aforementioned Figures 1 to 2 The illustrated embodiments describe steps in a method.

[0160] The client server provided in the embodiment of the present application may be a chip, which includes: a processing unit and a communication unit. The processing unit may be, for example, a processor, and the communication unit may be, for example, an input / output interface, a pin, or a circuit. The processing unit may execute the computer execution instructions stored in the storage unit to enable the chip to execute the above Figures 1 to 2 The method described in the illustrated embodiment. Optionally, the storage unit is a storage unit within the chip, such as a register, a cache, etc. The storage unit may also be a storage unit located outside the chip within the wireless access device, such as a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM), etc.

[0161] Although the present application is disclosed as above with the preferred embodiments, it is not intended to limit the present application. Any person skilled in the art may make possible changes and modifications without departing from the spirit and scope of the present application. Therefore, the scope of protection of the present application shall be based on the scope defined by the claims of the present application.

[0162] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0163] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0164] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0165] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0166] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, read-only memory), random access memory (RAM, random access memory), disk or optical disk, and other media that can store program code.

Claims

1. A method for drawing a game map, characterized in that: The game map drawing method includes: The client obtains the user's geographical location information; The client determines, based on the geographical location information, that the user terminal is in a predetermined geographical area; The client obtains map data of the predetermined geographical area according to the determination result; The client draws a game map of the predetermined geographical area according to the map data of the predetermined geographical area; The client displays the game map to the user terminal; The map data of the predetermined geographical area includes data information of at least one type of map element; The client draws a game map of the predetermined geographical area according to the map data of the predetermined geographical area, including: The client determines, based on the data information of the at least one type of map element type, a vertex list corresponding to each type of map element and a vertex connection order corresponding to the vertex list; The client determines the longitude and latitude information corresponding to each vertex in the vertex list; The client determines the relative distance between each vertex and the default location based on the longitude and latitude information corresponding to each vertex and the longitude and latitude information of the default location of the predetermined geographical area; The client determines the coordinates corresponding to each vertex according to the coordinates of the default position and the relative distance; The client determines and draws the area range corresponding to each type of map element in the game map according to the coordinates corresponding to each vertex and the order in which the vertices are connected.

2. The method according to claim 1, characterized in that There is at least one task object on the game map; The game map drawing method further includes: The client receives an operation instruction from the user terminal for the at least one task object; The client displays a task interface corresponding to the at least one task object according to the operation instruction.

3. The method according to claim 1, characterized in that The geographical location information of the user terminal includes the latitude and longitude information of the user terminal; The client determines, based on the geographic location information, that the user terminal is in a predetermined geographic area, including: The client obtains the latitude and longitude information of the default location of the predetermined geographical area; The client determines, based on the latitude and longitude information of the user terminal and the latitude and longitude information of the default location, that the distance between the user terminal and the default location is less than a preset distance threshold; The client determines that the user terminal is in a predetermined geographical area according to the determination result.

4. The method according to claim 1, wherein The client determines the coordinates corresponding to each vertex according to the coordinates of the default position in the game map and the relative distance, including: The client determines a scaling factor; The client determines the relative coordinate distance between each vertex and the default position according to the scaling factor and the relative distance; The client determines the coordinates of each vertex according to the coordinates of the default position and the relative coordinate distance.

5. The method according to claim 1, wherein The method further comprises: Determining a name identifier of at least one target object in each type of map element; The name identification of the at least one target object is marked in the game map.

6. The method according to any one of claims 1 to 5, characterized in that The method further comprises: The client determines a rendering mode; The client processes the game map according to the rendering mode; The client displays the game map to the user terminal, including: The client displays the processed game map to the user terminal.

7. The method according to claim 6, characterized in that The rendering mode includes color rendering, animation rendering or special effect rendering.

8. A client device, characterized in that: The device comprises: An acquisition unit, used to acquire geographic location information of a user terminal; a determining unit, configured to determine, based on the geographic location information, that the user terminal is in a predetermined geographic area; The determining unit is further configured to obtain map data of the predetermined geographical area according to the determination result; a processing unit, configured to draw a game map of the predetermined geographical area based on the map data of the predetermined geographical area; A display unit, configured to display the game map to the user terminal; The map data of the predetermined geographical area includes data information of at least one type of map element; The client draws a game map of the predetermined geographical area according to the map data of the predetermined geographical area, including: The client determines, based on the data information of the at least one type of map element type, a vertex list corresponding to each type of map element and a vertex connection order corresponding to the vertex list; The client determines the longitude and latitude information corresponding to each vertex in the vertex list; The client determines the relative distance between each vertex and the default location based on the longitude and latitude information corresponding to each vertex and the longitude and latitude information of the default location of the predetermined geographical area; The client determines the coordinates corresponding to each vertex according to the coordinates of the default position and the relative distance; The client determines and draws the area range corresponding to each type of map element in the game map according to the coordinates corresponding to each vertex and the order in which the vertices are connected.

9. A client server, characterized in that: include: A memory and a processor, wherein the memory and the processor are coupled; The memory is used to store one or more computer instructions; The processor is used to execute the one or more computer instructions to implement the game map drawing method as described in any one of the technical solutions of claims 1-7.

10. A computer-readable storage medium having one or more computer instructions stored thereon, characterized in that: The instruction is executed by the processor to implement the game map drawing method as described in any one of the technical solutions of claims 1-7.

Citation Information

Patent Citations

  • Game map generation method, system, server and terminal

    CN102567642A

  • Three-dimensional game map display method and three-dimensional game map display system

    CN105957144A

  • Map rendering method and system, terminal and storage medium

    CN114064826A