Game display control method, non-volatile storage medium and electronic device

By setting the mounting point on the virtual 3D model and adjusting the camera angle of view, the anchor point coordinates of the 2D UI control are determined, thereby simulating the effect of the 3D UI control on the virtual 3D model, solving the lack of expressiveness of the 2D UI control and the lack of functionality of the 3D UI control. It solves the problem of high power consumption, improves game screen performance and reduces system power consumption.

CN113318428BActive Publication Date: 2024-09-20NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110574121.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-05-25
Publication Date
2024-09-20
Estimated Expiration
2041-05-25

AI Technical Summary

Technical Problem

In the existing technology, the combination of 2D UI controls and background images lacks the expressiveness of the interface effect, and the combination of virtual 3D models and 3D UI controls will increase the system power consumption of the mobile terminal, leading to a decrease in operating efficiency.

Method used

Set a mounting point on the target virtual 3D model, adjust the virtual camera perspective in response to user operations, and update the mounting point coordinates to determine the anchor point coordinates of the 2D UI control, thereby displaying the 2D UI control in the graphical user interface and simulating a 3D UI Control effects while controlling system power consumption.

Benefits of technology

On the premise of ensuring the operating efficiency of the electronic device, it enhances the expressiveness of the game screen and reduces the system power consumption, solving the problem of insufficient expressiveness when combining 2D UI controls and high power consumption when combining 3D UI controls.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113318428B
    Figure CN113318428B
Patent Text Reader

Abstract

The present invention discloses a display control method, a non-volatile storage medium and an electronic device for a game. The method comprises: setting a hook point on a target virtual three-dimensional model; in response to a first touch operation on a graphical user interface, adjusting the default viewing angle of a virtual camera shooting a three-dimensional game scene to the current viewing angle, and updating the first coordinate of the hook point in the camera space of the virtual camera; determining the second coordinate of the hook point in the screen space according to the updated first coordinate; determining the anchor point coordinates of the anchor point of a two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinate; and displaying the two-dimensional UI control in the graphical user interface according to the anchor point coordinates. The present invention solves the technical problem that the processing method of combining 2D UI controls with background images provided in the related art lacks the expressiveness of interface effects, and the processing method of combining virtual 3D models with 3D UI controls will increase the system power consumption of mobile terminals.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computers, and in particular to a game display control method, a non-volatile storage medium and an electronic device. Background Art

[0002] At present, the two-dimensional (2D) UI controls provided in the related art usually display 2D images according to specific layers, and usually do not produce a three-dimensional (3D) stereoscopic effect. The virtual camera used is an orthogonal camera. Figure 1 is a schematic diagram of a 2D UI control in a game scene according to the related art, such as Figure 1 As shown, in a graphical user interface of a strategy game, 2D UI controls are combined with background images, such as "Tax" 2D UI controls, "Government Affairs" 2D UI controls, "Market" 2D UI controls, "Technology" 2D UI controls, "Details" 2D UI controls, etc. Since the perspective of the background image is fixed, the perspective of the 2D UI controls is also relatively fixed. However, the static interface effect used by the 2D UI controls is weak and stiff. Unlike 2D UI controls, 3D UI controls are usually created in a three-dimensional space, and the virtual camera used is a perspective camera. Figure 2 is a schematic diagram of a 3D UI control in a game scene according to the related art, such as Figure 2 As shown, in a graphical user interface of a simulated city game, a virtual 3D model (for example, a virtual 3D building such as an apartment, office building, shopping mall, etc.) is combined with a 3D UI control, which can configure the 3D UI control as a face of the 3D model. When the viewing angle of the virtual camera to shoot the three-dimensional game scene is adjusted, the face where the 3D UI control is located moves synchronously with the virtual 3D model visually. However, this visual change will significantly increase the system power consumption of the mobile terminal, and low-end mobile terminals may freeze during actual operation, which is not conducive to the backward compatibility of electronic products.

[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention

[0004] At least some embodiments of the present invention provide a game display control method, a non-volatile storage medium and an electronic device, so as to at least solve the technical problems that the processing method of combining 2D UI controls with background images provided in the related art lacks the expressiveness of interface effects, while the processing method of combining virtual 3D models with 3D UI controls will increase the system power consumption of the mobile terminal.

[0005] According to one embodiment of the present invention, a game display control method is provided, wherein a graphical user interface is provided by an electronic device, and the content displayed by the graphical user interface includes a game scene screen obtained by shooting a three-dimensional game scene by a virtual camera, wherein the game scene screen includes a target virtual three-dimensional model, and the game display control method includes:

[0006] A hanging point is set on the target virtual three-dimensional model; in response to a first touch operation on the graphical user interface, the default viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted to the current viewing angle, and the first coordinate of the hanging point in the camera space of the virtual camera is updated; according to the updated first coordinate of the hanging point in the camera space, the second coordinate of the hanging point in the screen space is determined; according to the second coordinate of the hanging point in the screen space, the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space are determined; and the two-dimensional UI control is displayed in the graphical user interface according to the anchor point coordinates.

[0007] Optionally, in response to a first touch operation on the graphical user interface, adjusting the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle includes: in response to a first touch operation on the graphical user interface, adjusting the default viewing angle of the virtual camera shooting the target virtual three-dimensional model to the current viewing angle.

[0008] Optionally, the display control method of the above game also includes: in response to a second touch operation on the graphical user interface, adjusting the first screen content obtained by the virtual camera shooting the three-dimensional game scene to the second screen content; when the second screen content includes the target virtual three-dimensional model, in response to a third touch operation on the target virtual three-dimensional model, determining the default viewing angle of the virtual camera to shoot the target virtual three-dimensional model.

[0009] Optionally, the two-dimensional UI control is a two-dimensional map generated based on a preset two-dimensional UI template. The preset two-dimensional UI template is configured in a two-dimensional UI editor. The preset two-dimensional UI template is used to determine the style of the two-dimensional UI control. The display content of the two-dimensional UI control includes at least one of the following: picture logo, text logo.

[0010] Optionally, updating the first coordinate of the attachment point in the camera space of the virtual camera includes: determining the coordinate offset of the attachment point in the camera space based on the difference in perspective change between a default perspective and a current perspective; and updating the first coordinate of the attachment point in the camera space of the virtual camera based on the coordinate offset.

[0011] Optionally, adjusting the default viewing angle of the virtual camera for shooting the three-dimensional game scene to the current viewing angle includes: adjusting the default viewing angle of the virtual camera for shooting the three-dimensional game scene to the current viewing angle within the viewing angle change range of the virtual camera, wherein the viewing angle change range is used to limit the upper limit value and the lower limit value of the viewing angle change of the current viewing angle relative to the default viewing angle.

[0012] Optionally, the anchor point coordinates are any vertex coordinates or center coordinates of the two-dimensional UI control.

[0013] According to one embodiment of the present invention, there is also provided a display control device for a game, comprising: providing a graphical user interface through an electronic device, the content displayed by the graphical user interface comprising a game scene screen obtained by shooting a three-dimensional game scene with a virtual camera, wherein the game scene screen comprises a target virtual three-dimensional model, and the display control device for the game comprises: a setting module, used to set a hanging point on the target virtual three-dimensional model; a processing module, used to adjust the default viewing angle of the three-dimensional game scene shot by the virtual camera to the current viewing angle in response to a first touch operation on the graphical user interface, and update the first coordinate of the hanging point in the camera space of the virtual camera; a first determination module, used to determine the second coordinate of the hanging point in the screen space according to the updated first coordinate of the hanging point in the camera space; a second determination module, used to determine the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinate of the hanging point in the screen space; and a display module, used to display the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

[0014] Optionally, the processing module is used to adjust a default viewing angle of the virtual camera shooting the target virtual three-dimensional model to a current viewing angle in response to a first touch operation on the graphical user interface.

[0015] Optionally, the processing module is also used to adjust the first screen content obtained by the virtual camera shooting the three-dimensional game scene to the second screen content in response to a second touch operation on the graphical user interface; when the second screen content includes the target virtual three-dimensional model, in response to a third touch operation on the target virtual three-dimensional model, determine the default viewing angle of the virtual camera to shoot the target virtual three-dimensional model.

[0016] Optionally, the two-dimensional UI control is a two-dimensional map generated based on a preset two-dimensional UI template. The preset two-dimensional UI template is configured in a two-dimensional UI editor. The preset two-dimensional UI template is used to determine the style of the two-dimensional UI control. The display content of the two-dimensional UI control includes at least one of the following: picture logo, text logo.

[0017] Optionally, the processing module is used to determine the coordinate offset of the attachment point in the camera space according to the difference in perspective change between the default perspective and the current perspective; and update the first coordinate of the attachment point in the camera space of the virtual camera according to the coordinate offset.

[0018] Optionally, the processing module is used to adjust the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle within the viewing angle change range of the virtual camera, wherein the viewing angle change range is used to limit the upper limit value and the lower limit value of the viewing angle change of the current viewing angle relative to the default viewing angle.

[0019] Optionally, the anchor point coordinates are any vertex coordinates or center coordinates of the two-dimensional UI control.

[0020] According to one embodiment of the present invention, a non-volatile storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute any of the above-mentioned game display control methods when running.

[0021] According to one embodiment of the present invention, a processor is further provided, the processor being used to run a program, wherein the program is configured to execute any of the above-mentioned game display control methods when running.

[0022] According to one embodiment of the present invention, there is further provided an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute any of the above-mentioned game display control methods.

[0023] In at least some embodiments of the present invention, a hook point is set on the target virtual three-dimensional model, and in response to a first touch operation on the graphical user interface, the default viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted to the current viewing angle and the first coordinate of the hook point in the camera space of the virtual camera is updated, the second coordinate of the hook point in the screen space is determined by the updated first coordinate of the hook point in the camera space, the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space are determined according to the second coordinate of the hook point in the screen space, and the two-dimensional UI control is displayed in the graphical user interface according to the anchor point coordinates, so as to achieve the purpose of simulating the 3D UI control effect by using the 2D UI control on the virtual 3D model in the game scene, so that when the viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted, the 2D UI control can visually follow the movement, thereby achieving the technical effect of effectively reducing the system power consumption and enhancing the expressiveness of the game screen under the premise of ensuring the operating efficiency of the electronic device, thereby solving the problem that the processing method of combining the 2D UI control with the background image provided in the related art lacks the expressiveness of the interface effect, and combining the virtual 3D model with the 3D The processing method of combining UI controls with each other will increase the technical problem of system power consumption of the mobile terminal. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0025] Figure 1 is a schematic diagram of a 2D UI control in a game scene according to the related art;

[0026] Figure 2 is a schematic diagram of a 3D UI control in a game scene according to the related art;

[0027] Figure 3 It is a hardware structure block diagram of a mobile terminal of a game display control method according to an embodiment of the present invention;

[0028] Figure 4 is a flow chart of a display control method for a game according to one embodiment of the present invention;

[0029] Figure 5 is a schematic diagram of a display control process of a game according to one optional embodiment of the present invention;

[0030] Figure 6 is a structural block diagram of a game display control device according to one embodiment of the present invention. DETAILED DESCRIPTION

[0031] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0032] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof 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 that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0033] According to one embodiment of the present invention, an embodiment of a display control method of a game is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0034] The method embodiment can be executed in a mobile terminal, a computer terminal or a similar computing device. Taking running on a mobile terminal as an example, the mobile terminal can be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (MID for short), a PAD, a game console and other terminal devices. Figure 3 is a hardware structure block diagram of a mobile terminal of a game display control method according to an embodiment of the present invention, such as Figure 3 As shown, the mobile terminal may include one or more ( Figure 3Only one is shown in the figure) processor 102 (processor 102 may include but is not limited to a central processing unit (CPU), a graphics processing unit (GPU), a digital signal processing (DSP) chip, a microprocessor (MCU), a programmable logic device (FPGA), a neural network processor (NPU), a tensor processor (TPU), an artificial intelligence (AI) type processor, etc.) and a memory 104 for storing data. Optionally, the mobile terminal may also include a transmission device 106 for communication functions, an input and output device 108, and a display device 110. It can be understood by those skilled in the art that Figure 3 The structure shown is only for illustration and does not limit the structure of the mobile terminal. Figure 3 More or fewer components as shown, or with Figure 3 Different configurations are shown.

[0035] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the display control method of the game in the embodiment of the present invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, the display control method of the game described above is realized. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the mobile terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0036] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0037] The inputs in the input / output device 108 may come from a plurality of human interface devices (HIDs), such as keyboards and mice, game controllers, and other dedicated game controllers (such as steering wheels, fishing rods, dance mats, remote controls, etc.). In addition to providing input functions, some human interface devices may also provide output functions, such as force feedback and vibration of game controllers, audio output of controllers, etc.

[0038] The display device 110 may be, for example, a head-up display (HUD), a touch-screen liquid crystal display (LCD), and a touch display (also referred to as a "touch screen" or "touch display screen"). The liquid crystal display may enable a user to interact with a user interface of the mobile terminal. In some embodiments, the mobile terminal has a graphical user interface (GUI), and a user may interact with the GUI by finger contacts and / or gestures on a touch-sensitive surface, wherein the human-computer interaction functions here may optionally include the following interactions: creating web pages, drawing, word processing, making electronic documents, games, video conferencing, instant messaging, sending and receiving emails, call interfaces, playing digital videos, playing digital music, and / or web browsing, etc. The executable instructions for executing the above-mentioned human-computer interaction functions are configured / stored in a computer program product or a readable storage medium executable by one or more processors.

[0039] In this embodiment, a display control method for a game running on the mobile terminal is provided, wherein a graphical user interface is provided by an electronic device, and the content displayed by the graphical user interface includes a game scene screen obtained by shooting a three-dimensional game scene by a virtual camera, wherein the game scene screen includes a target virtual three-dimensional model, Figure 4 is a flow chart of a display control method for a game according to one embodiment of the present invention, such as Figure 4 As shown, the method comprises the following steps:

[0040] Step S40, setting a connection point on the target virtual three-dimensional model;

[0041] The target virtual 3D model may include, but is not limited to, a virtual 3D building model (e.g., a virtual city model, a virtual apartment model, a virtual office building model, etc.), a virtual 3D vehicle model (e.g., a virtual vehicle model, a virtual aircraft model), and a virtual 3D natural resource model (e.g., a virtual 3D mountain model, a virtual 3D jungle model, etc.). The attachment point is used to provide a reference position for attaching a 2D UI control on the target virtual 3D model.

[0042] Step S41, in response to a first touch operation on the graphical user interface, adjusting the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle, and updating the first coordinate of the attachment point in the camera space of the virtual camera;

[0043] The first touch operation may include, but is not limited to, a slide (drag) operation, a re-press operation, and a long press operation. Taking the first touch operation as a slide (drag) operation as an example, the virtual camera can usually determine the viewing angle used to render the game scene. By performing a slide (drag) operation on the graphical user interface, the default viewing angle of the virtual camera shooting the three-dimensional game scene can be adjusted to the current viewing angle. The default viewing angle corresponds to the starting position of the slide (drag) operation. The current viewing angle corresponds to the end position of the slide (drag) operation.

[0044] The camera space is a three-dimensional space. In the camera space, the virtual camera is usually located at the origin of the camera space, and the selection of its coordinate axes can be arbitrary. For example: the +x axis points to the right of the virtual camera, the +y axis points to the top of the virtual camera, and the +z axis points to the back of the virtual camera. Under the default viewing angle of the virtual camera shooting the three-dimensional game scene, the representation of the three coordinate axes of the camera space in the world space can be calculated, and then the transformation matrix from the world space to the camera space is obtained by constructing the transformation matrix from the camera space to the world space, and then the transformation matrix is ​​inverted to obtain the transformation matrix from the world space to the camera space, thereby determining the first coordinate of the attachment point in the camera space of the virtual camera. Similarly, under the current viewing angle of the virtual camera shooting the three-dimensional game scene, the representation of the three coordinate axes of the camera space in the world space can also be calculated, and then the transformation matrix from the world space to the camera space is obtained by constructing the transformation matrix from the camera space to the world space, and then the transformation matrix is ​​inverted to obtain the transformation matrix from the world space to the camera space, thereby updating the first coordinate of the attachment point in the camera space of the virtual camera.

[0045] Step S42, determining the second coordinate of the attachment point in the screen space according to the updated first coordinate of the attachment point in the camera space;

[0046] Screen space is a two-dimensional space. The projection matrix can be used to first convert the first coordinate of the updated attachment point in the camera space from the camera space to the clipping space, and then the first coordinate is projected from the clipping space to the screen space to generate the corresponding 2D coordinate, that is, the second coordinate of the attachment point in the screen space.

[0047] Step S43, determining the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinates of the attachment point in the screen space;

[0048] The above-mentioned anchor point coordinates can be any vertex coordinates or center coordinates of the two-dimensional UI control. For example: when the shape of the two-dimensional UI control is a pentagon, the anchor point of the two-dimensional UI control can be any vertex of the pentagon or the center point of the pentagon. The anchor point coordinates can be any vertex coordinates of the pentagon or the center coordinates of the pentagon. After determining the second coordinates of the attachment point in the screen space, the anchor point coordinates of the anchor point of the two-dimensional UI control in the screen space can be determined based on the second coordinates. The position of the anchor point coordinates can either coincide with the position of the second coordinates or have a certain offset with the position of the second coordinates.

[0049] The above-mentioned two-dimensional UI control is a two-dimensional map generated based on a preset two-dimensional UI template. The preset two-dimensional UI template can be pre-configured in the two-dimensional UI editor. The preset two-dimensional UI template is used to determine the style of the two-dimensional UI control, such as: the outline of the two-dimensional UI control, the color of the two-dimensional UI control, the transparency of the two-dimensional UI control, etc. The display content of the two-dimensional UI control may include but is not limited to at least one of the following: picture logo, text logo. For example: when the two-dimensional UI control is a barracks UI control associated with the virtual main city model, the display content of the barracks UI control may include soldier pictures and barracks text.

[0050] Step S44: displaying the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

[0051] Compared with the processing method of combining 2D UI controls with background images, the processing method of combining 2D UI controls with virtual 3D models can significantly enhance the expressiveness of interface effects; and compared with the processing method of combining virtual 3D models with 3D UI controls, there is no need to regard UI controls as part of the 3D model, and the system power consumption of 2D UI controls (which are essentially 2D maps) will be significantly lower than that of 3D UI controls (which are essentially 3D models), thereby improving the backward compatibility of electronic products.

[0052] Through the above steps, a hook point can be set on the target virtual three-dimensional model, and in response to the first touch operation on the graphical user interface, the default viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted to the current viewing angle and the first coordinate of the hook point in the camera space of the virtual camera is updated. The second coordinate of the hook point in the screen space is determined by the updated first coordinate of the hook point in the camera space, the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space are determined according to the second coordinate of the hook point in the screen space, and the two-dimensional UI control is displayed in the graphical user interface according to the anchor point coordinates, so as to achieve the purpose of simulating the 3D UI control effect by using the 2D UI control on the virtual 3D model in the game scene, so that when the viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted, the 2D UI control can visually follow the movement, thereby achieving the technical effect of effectively reducing the system power consumption and enhancing the expressiveness of the game screen under the premise of ensuring the operating efficiency of the electronic device, thereby solving the technical problem that the processing method of combining the 2D UI control with the background picture provided in the related art lacks the expressiveness of the interface effect, and the processing method of combining the virtual 3D model with the 3D UI control will increase the system power consumption of the mobile terminal.

[0053] Optionally, in step S41, in response to the first touch operation on the graphical user interface, adjusting the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle may include the following execution steps:

[0054] Step S410 , in response to a first touch operation on the graphical user interface, adjusting a default viewing angle of a virtual camera shooting a target virtual three-dimensional model to a current viewing angle.

[0055] In an optional embodiment, the virtual camera may determine the viewing angle used to render the target virtual 3D model. By performing a sliding (dragging) operation on the graphical user interface, the default viewing angle of the virtual camera shooting the target virtual 3D model may be adjusted to the current viewing angle. The default viewing angle corresponds to the starting position of the sliding (dragging) operation. The current viewing angle corresponds to the ending position of the sliding (dragging) operation.

[0056] In addition, in order to ensure that the two-dimensional UI controls are displayed normally in the graphical user interface, it is necessary to set a viewing angle change range for the virtual camera so that the default viewing angle of the virtual camera shooting the three-dimensional game scene can be adjusted to the current viewing angle within the viewing angle change range of the virtual camera. The viewing angle change range is used to limit the upper and lower limits of the current viewing angle relative to the default viewing angle. For example: when the viewing angle change range is 0-120 degrees, the angle formed between the line of sight direction under the current viewing angle and the line of sight direction under the default viewing angle cannot exceed 120 degrees, otherwise the two-dimensional UI controls will be displayed abnormally.

[0057] Optionally, the game display control method may further include the following execution steps:

[0058] Step S45, in response to a second touch operation on the graphical user interface, adjusting the first screen content obtained by shooting the three-dimensional game scene with the virtual camera to the second screen content;

[0059] Step S46: when the second screen content includes the target virtual three-dimensional model, in response to a third touch operation on the target virtual three-dimensional model, determining a default viewing angle of the virtual camera to shoot the target virtual three-dimensional model.

[0060] The above-mentioned second touch operation may include but is not limited to: sliding (dragging) operation, re-pressing operation, and long pressing operation. By performing a sliding (dragging) operation on the graphical user interface, the first screen content obtained by the virtual camera shooting the three-dimensional game scene can be adjusted to the second screen content, and in the process of adjusting from the first screen content to the second screen content, the viewing angle of the virtual camera shooting the game scene screen remains unchanged. For example: by performing a sliding (dragging) operation on the graphical user interface, the position of the virtual main city model created by other game players in the game map can be displayed in the first screen content, or the minerals, trees and other natural resources searched by our game players for the development of the virtual main city model can be displayed in the first screen content. That is, the first screen content usually does not include the above-mentioned target virtual three-dimensional model. The second screen content is returned from the virtual three-dimensional model other than the above-mentioned target virtual three-dimensional model in the display game scene to the screen content containing the above-mentioned target virtual three-dimensional model.

[0061] The third touch operation may include but is not limited to: a click operation, a re-press operation, and a long press operation. When the second screen content includes a target virtual three-dimensional model, the default viewing angle of the target virtual three-dimensional model shot by the virtual camera may be determined by performing a click operation on the target virtual three-dimensional model. Under the default viewing angle of the target virtual three-dimensional model shot by the virtual camera, the two-dimensional UI control will be displayed in the graphical user interface according to the anchor point coordinates of the two-dimensional UI control in the screen space.

[0062] In an optional embodiment, in response to the second touch operation, the first screen content and the second screen content are both displayed using a first scale (e.g., a scale of 1:800). In response to the third touch operation, the game scene screen obtained by shooting the three-dimensional game scene with a virtual camera at a default viewing angle and the game scene screen obtained by shooting the three-dimensional game scene with a virtual camera at a current viewing angle in response to the first touch operation are both displayed using a second scale (e.g., a scale of 1:100). That is, the second scale is larger than the first scale.

[0063] Figure 5 is a schematic diagram of a display control process of a game according to one optional embodiment of the present invention, such as Figure 5 As shown, when the graphical user interface includes a virtual 3D model, by performing a click operation on the virtual 3D model, an "enter" control pops up to facilitate the game player to confirm whether to enter the 2D UI control display interface. When the game player clicks the "enter" control, the default viewing angle of the virtual camera shooting the virtual 3D model can be determined. Under the default viewing angle of the virtual camera shooting the virtual 3D model, the 2D UI control will be displayed in the graphical user interface according to the anchor point coordinates of the 2D UI control in the screen space, such as: barracks 2D UI control, council hall 2D UI control, gold coin finance 2D UI control, etc. By performing a left sliding (dragging) operation on the graphical user interface, the default viewing angle of the virtual camera shooting the virtual 3D model can be adjusted to the current viewing angle and the coordinates of the attachment point in the camera space of the virtual camera can be updated. The default viewing angle corresponds to the starting position of the sliding (dragging) operation. The current viewing angle corresponds to the end position of the sliding (dragging) operation. Taking the Barracks 2D UI control as an example, the anchor point of the Barracks 2D UI control is the bottom vertex of the pentagon, and the coordinates of the anchor point coincide with the coordinates of the attachment point in the screen space. Therefore, the coordinates of the attachment point in the screen space can be determined based on the updated coordinates of the attachment point in the camera space, and then the anchor point coordinates of the Barracks 2D UI control in the screen space can be determined based on the coordinates of the attachment point in the screen space, and then the Barracks 2D UI control can be displayed in the graphical user interface based on the anchor point coordinates.

[0064] Optionally, in step S41, updating the first coordinate of the attachment point in the camera space of the virtual camera may include the following execution steps:

[0065] Step S411, determining the coordinate offset of the attachment point in the camera space according to the difference in the view angle change between the default view angle and the current view angle;

[0066] Step S412, updating the first coordinate of the attachment point in the camera space of the virtual camera according to the coordinate offset.

[0067] By performing a sliding (dragging) operation on the graphical user interface, the default viewing angle of the virtual camera shooting the three-dimensional game scene can be adjusted to the current viewing angle. At this time, it is necessary to determine the coordinate offset of the attachment point in the camera space from the default viewing angle to the current viewing angle based on the difference in viewing angle change between the default viewing angle and the current viewing angle, so as to update the first coordinate of the attachment point in the camera space of the virtual camera according to the coordinate offset. For example: under the default viewing angle of the virtual camera shooting the three-dimensional game scene, the representation of the three coordinate axes of the camera space in the world space can be calculated, and then the transformation matrix from the camera space to the world space is constructed, and then the transformation matrix from the world space to the camera space is obtained by inverting the transformation matrix, thereby determining the first coordinate of the attachment point in the camera space of the virtual camera as (X1, Y1, Z1). Under the current viewing angle of the virtual camera shooting the three-dimensional game scene, the representation of the three coordinate axes of the camera space in the world space can be calculated, and then the transformation matrix from the camera space to the world space is constructed, and then the transformation matrix from the world space to the camera space is obtained by inverting the transformation matrix, thereby determining the first coordinate of the attachment point in the camera space of the virtual camera as (X2, Y2, Z2). Therefore, based on (X1, Y1, Z1) and (X2, Y2, Z2), it can be determined that the difference in viewing angle change between the default viewing angle and the current viewing angle is angle A. Then, through the mapping relationship between the preset viewing angle change difference and the coordinate offset, angle A is used to determine the coordinate offset of the attachment point in the camera space as F. Finally, according to the coordinate offset F, the first coordinate of the attachment point in the camera space of the virtual camera is updated to (X3, Y3, Z3).

[0068] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.

[0069] In this embodiment, a display control device for a game is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0070] Figure 6 1 is a structural block diagram of a display control device for a game according to one embodiment of the present invention, wherein a graphical user interface is provided by an electronic device, and the content displayed by the graphical user interface includes a game scene screen obtained by shooting a three-dimensional game scene by a virtual camera, wherein the game scene screen includes a target virtual three-dimensional model, such as Figure 6 As shown, the device includes: a setting module 10, used to set a hanging point on the target virtual three-dimensional model; a processing module 20, used to adjust the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle in response to a first touch operation on the graphical user interface, and update the first coordinate of the hanging point in the camera space of the virtual camera; a first determination module 30, used to determine the second coordinate of the hanging point in the screen space according to the updated first coordinate of the hanging point in the camera space; a second determination module 40, used to determine the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinate of the hanging point in the screen space; a display module 50, used to display the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

[0071] Optionally, the processing module 20 is configured to adjust a default viewing angle of the virtual camera shooting the target virtual three-dimensional model to a current viewing angle in response to a first touch operation on the graphical user interface.

[0072] Optionally, the processing module 20 is also used to adjust the first screen content obtained by the virtual camera shooting the three-dimensional game scene to the second screen content in response to a second touch operation on the graphical user interface; when the second screen content includes the target virtual three-dimensional model, in response to a third touch operation on the target virtual three-dimensional model, determine the default viewing angle of the virtual camera to shoot the target virtual three-dimensional model.

[0073] Optionally, the two-dimensional UI control is a two-dimensional map generated based on a preset two-dimensional UI template. The preset two-dimensional UI template is configured in a two-dimensional UI editor. The preset two-dimensional UI template is used to determine the style of the two-dimensional UI control. The display content of the two-dimensional UI control includes at least one of the following: picture logo, text logo.

[0074] Optionally, the processing module 20 is used to determine the coordinate offset of the attachment point in the camera space according to the difference in perspective change between the default perspective and the current perspective; and update the first coordinate of the attachment point in the camera space of the virtual camera according to the coordinate offset.

[0075] Optionally, the processing module 20 is used to adjust the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle within the viewing angle change range of the virtual camera, wherein the viewing angle change range is used to limit the upper limit value and the lower limit value of the viewing angle change of the current viewing angle relative to the default viewing angle.

[0076] Optionally, the anchor point coordinates are any vertex coordinates or center coordinates of the two-dimensional UI control.

[0077] It should be noted that the above modules can be implemented by software or hardware. For the latter, it can be implemented in the following ways, but not limited to: the above modules are all located in the same processor; or the above modules are located in different processors in any combination.

[0078] An embodiment of the present invention further provides a non-volatile storage medium, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when running.

[0079] Optionally, in this embodiment, the non-volatile storage medium may be configured to store a computer program for performing the following steps:

[0080] S1, setting a connection point on the target virtual three-dimensional model;

[0081] S2, in response to a first touch operation on the graphical user interface, adjusting a default viewing angle of the virtual camera shooting the three-dimensional game scene to a current viewing angle, and updating a first coordinate of the attachment point in the camera space of the virtual camera;

[0082] S3, determining a second coordinate of the attachment point in the screen space according to the updated first coordinate of the attachment point in the camera space;

[0083] S4, determining the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinates of the attachment point in the screen space;

[0084] S5, displaying the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

[0085] Optionally, in this embodiment, the above-mentioned non-volatile storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store computer programs.

[0086] An embodiment of the present invention further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0087] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0088] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:

[0089] S1, setting a connection point on the target virtual three-dimensional model;

[0090] S2, in response to a first touch operation on the graphical user interface, adjusting a default viewing angle of the virtual camera shooting the three-dimensional game scene to a current viewing angle, and updating a first coordinate of the attachment point in the camera space of the virtual camera;

[0091] S3, determining a second coordinate of the attachment point in the screen space according to the updated first coordinate of the attachment point in the camera space;

[0092] S4, determining the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinates of the attachment point in the screen space;

[0093] S5, displaying the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

[0094] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.

[0095] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0096] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0097] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, 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 through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

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

[0099] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0100] 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 invention, in essence, 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 a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.

[0101] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A game display control method, characterized in that: A graphical user interface is provided by an electronic device, wherein the content displayed by the graphical user interface includes a game scene screen obtained by shooting a three-dimensional game scene by a virtual camera, wherein the game scene screen includes a target virtual three-dimensional model, and the display control method of the game includes: Setting a mounting point on the target virtual three-dimensional model; In response to a first touch operation on the graphical user interface, adjusting a default viewing angle of the virtual camera shooting the three-dimensional game scene to a current viewing angle, and updating a first coordinate of the attachment point in the camera space of the virtual camera; Determine a second coordinate of the attachment point in the screen space according to the updated first coordinate of the attachment point in the camera space; Determining, according to the second coordinates of the attachment point in the screen space, the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space; The two-dimensional UI control is displayed in the graphical user interface according to the anchor point coordinates.

2. The game display control method according to claim 1, characterized in that: In response to the first touch operation on the graphical user interface, adjusting the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle includes: In response to the first touch operation on the graphical user interface, a default viewing angle of the virtual camera shooting the target virtual three-dimensional model is adjusted to a current viewing angle.

3. The game display control method according to claim 1, characterized in that: The game display control method also includes: In response to a second touch operation on the graphical user interface, adjusting a first screen content obtained by photographing the three-dimensional game scene with the virtual camera to a second screen content; When the second screen content includes the target virtual three-dimensional model, in response to a third touch operation on the target virtual three-dimensional model, a default viewing angle of the virtual camera for photographing the target virtual three-dimensional model is determined.

4. The game display control method according to claim 1, characterized in that: The two-dimensional UI control is a two-dimensional map generated based on a preset two-dimensional UI template. The preset two-dimensional UI template is configured in a two-dimensional UI editor. The preset two-dimensional UI template is used to determine the style of the two-dimensional UI control. The display content of the two-dimensional UI control includes at least one of the following: a picture logo and a text logo.

5. The game display control method according to claim 1, characterized in that: Updating the first coordinate of the attachment point in the camera space of the virtual camera includes: Determining a coordinate offset of the attachment point in the camera space according to a difference in perspective change between the default perspective and the current perspective; The first coordinate of the attachment point in the camera space of the virtual camera is updated according to the coordinate offset.

6. The game display control method according to claim 1, characterized in that: Adjusting the default viewing angle of the virtual camera shooting the three-dimensional game scene to the current viewing angle comprises: The default viewing angle of the virtual camera shooting the three-dimensional game scene is adjusted to the current viewing angle within the viewing angle change range of the virtual camera, wherein the viewing angle change range is used to limit the upper limit value and the lower limit value of the viewing angle change of the current viewing angle relative to the default viewing angle.

7. The game display control method according to claim 1, characterized in that: The anchor point coordinates are any vertex coordinates or center coordinates of the two-dimensional UI control.

8. A game display control device, characterized in that: A graphical user interface is provided by an electronic device, wherein the content displayed by the graphical user interface includes a game scene screen obtained by shooting a three-dimensional game scene by a virtual camera, wherein the game scene screen includes a target virtual three-dimensional model, and the display control device of the game includes: A setting module, used for setting a hanging point on the target virtual three-dimensional model; A processing module, configured to, in response to a first touch operation on the graphical user interface, adjust a default viewing angle of the virtual camera shooting the three-dimensional game scene to a current viewing angle, and update a first coordinate of the attachment point in the camera space of the virtual camera; A first determining module, used to determine a second coordinate of the attachment point in the screen space according to the updated first coordinate of the attachment point in the camera space; A second determination module, configured to determine the anchor point coordinates of the anchor point of the two-dimensional UI control associated with the target virtual three-dimensional model in the screen space according to the second coordinates of the attachment point in the screen space; A display module is used to display the two-dimensional UI control in the graphical user interface according to the anchor point coordinates.

9. A non-volatile storage medium, characterized in that: The storage medium stores a computer program, wherein the computer program is configured to execute the game display control method described in any one of claims 1 to 7 when running.

10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to run the computer program to execute the game display control method described in any one of claims 1 to 7.