CN111124412B - Game page drawing method, device, equipment and storage medium - Google Patents

Game page drawing method, device, equipment and storage medium Download PDF

Info

Publication number
CN111124412B
CN111124412B CN202010001186.8A CN202010001186A CN111124412B CN 111124412 B CN111124412 B CN 111124412B CN 202010001186 A CN202010001186 A CN 202010001186A CN 111124412 B CN111124412 B CN 111124412B
Authority
CN
China
Prior art keywords
control
page
basic
target page
list information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010001186.8A
Other languages
Chinese (zh)
Other versions
CN111124412A (en
Inventor
户志明
邱旻峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202010001186.8A priority Critical patent/CN111124412B/en
Publication of CN111124412A publication Critical patent/CN111124412A/en
Application granted granted Critical
Publication of CN111124412B publication Critical patent/CN111124412B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/50Controlling the output signals based on the game progress
    • A63F13/52Controlling the output signals based on the game progress involving aspects of the displayed game scene
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F2300/00Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game
    • A63F2300/30Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game characterized by output arrangements for receiving control signals generated by the game device
    • A63F2300/308Details of the user interface

Abstract

The application discloses a game page drawing method, a device, equipment and a storage medium, wherein the method comprises the following steps: the method comprises the steps that the method is applied to an application terminal provided with an initial activity panel, a basic control is hidden in the initial activity panel, a configuration file of a target page is obtained in response to a page drawing request of the target page, the configuration file comprises control list information and control attribute information, and the control attribute information represents the style layout and the event function attribute of the control in the target page; copying a basic control corresponding to the control list information from the initial movable panel; drawing the basic control corresponding to the control list information in the initial activity panel based on the control attribute information, and generating the target page. By using the technical scheme provided by the embodiment of the application, the development difficulty can be greatly reduced, and the efficiency of drawing the game page is improved.

Description

Game page drawing method, device, equipment and storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a storage medium for rendering a game page.
Background
With the continuous development of computer technology, more and more application programs can be downloaded on terminal equipment by a user, and play different roles in the life of the user. Users must be involved in interacting with various activity pages during the use of various applications. Therefore, page rendering is also an important point in the application development process.
In the prior art, page development of different applications often needs to be combined with corresponding development tools, and the development tools often have certain specialties. For example, in the development process of a game page, an activity panel including controls required by different activity pages is often drawn in advance by combining tools such as Unity3d and the like, that is, the activity panel is drawn by a game development tool and then packaged and placed on a server. When the game application is loaded, the packaged file is pulled from the server, and the activity page is loaded and displayed. However, even though the activity panels of different activity pages are often different, the prior art needs to respectively draw the activity panels of different activities, the previously drawn activity panels cannot be reused by other activities after the activities are finished, and if the contents of the panels are adjusted, the contents of the activity panels need to be adjusted by a development tool, then updated into corresponding files, and then updated to the terminal. The whole development process is tedious and tedious, and much labor is consumed. Therefore, there is a need to provide a more efficient solution.
Disclosure of Invention
The application provides a game page drawing method, device, equipment and storage medium, which can greatly reduce development difficulty and improve game page drawing efficiency.
On one hand, the application provides a game page drawing method, which is applied to an application terminal provided with an initial movable panel, wherein the initial movable panel is hidden with a basic control, and the method comprises the following steps:
responding to a request of a target page, and acquiring a configuration file of the target page, wherein the configuration file comprises control list information and control attribute information, and the control attribute information represents the style layout and event function attribute of a control in the target page;
copying a basic control corresponding to the control list information from the initial movable panel;
drawing the basic control corresponding to the control list information in the initial activity panel based on the control attribute information, and generating the target page.
Another aspect provides a game page drawing apparatus, where the apparatus is provided with an initial movable panel, and the initial movable panel is hidden with a basic control, and the apparatus includes:
the first configuration file acquisition module is used for responding to a page drawing request of a target page and acquiring a configuration file of the target page, wherein the configuration file comprises control list information and control attribute information, and the control attribute information represents the style layout and the event function attribute of a control in the target page;
the first basic control copying module is used for copying basic controls corresponding to the control list information from the initial movable panel;
and the target page generating module is used for drawing the basic control corresponding to the control list information in the initial activity panel based on the control attribute information and generating the target page.
Another aspect provides a game page drawing device, the device has an initial active panel, the initial active panel is hidden and provided with a basic control, the device includes a processor and a memory, the memory stores at least one instruction or at least one program, and the at least one instruction or the at least one program is loaded and executed by the processor to implement the game page drawing method.
Another aspect provides a computer readable storage medium, in which at least one instruction or at least one program is stored, the at least one instruction or the at least one program being loaded and executed by a processor to implement the game page rendering method as described above.
The game page drawing method, the game page drawing device, the game page drawing equipment and the storage medium have the following technical effects:
according to the method and the device, the initial movable panel is preset on the terminal, the basic control used for drawing the page is only hidden in the initial movable panel, when the target page needs to be drawn, the configuration file comprising control list information and control attribute information in the target page is obtained, the style layout and the event function attribute of the control can be directly configured based on the control attribute information, the situation that a complex development tool is used for drawing the content of the panel is avoided, the knowledge storage requirement of developers is reduced, the development difficulty is greatly reduced, and the drawing efficiency of the game page is improved.
Drawings
In order to more clearly illustrate the technical solutions and advantages of the embodiments of the present application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative efforts.
FIG. 1 is a schematic diagram of an application environment provided by an embodiment of the present application;
FIG. 2 is a schematic diagram of an initial movable panel and a loaded initial movable panel according to an embodiment of the present disclosure;
FIG. 3 is a schematic flow chart of a method for rendering a game page according to an embodiment of the present disclosure;
FIG. 4 is a diagram illustrating control list information provided in an embodiment of the present application;
fig. 5 is a schematic flowchart illustrating a process of obtaining a configuration file of a target page in response to a page drawing request of the target page according to an embodiment of the present application;
fig. 6 is a schematic flowchart illustrating a process of copying a basic control corresponding to the control list information from the initial active panel according to an embodiment of the present application;
fig. 7 is a schematic flowchart of another process for copying a basic control corresponding to the control list information from the initial active panel according to the embodiment of the present application;
fig. 8 is a schematic flowchart of drawing a currently copied base control in the initial active panel based on control attribute information of the currently copied base control according to an embodiment of the present application;
FIG. 9 is a schematic diagram of a target page provided by an embodiment of the present application;
FIG. 10 is a schematic flow chart diagram illustrating another method for rendering a game page according to an embodiment of the present application;
fig. 11 is a schematic structural diagram of a game page drawing apparatus according to an embodiment of the present application;
fig. 12 is a schematic structural diagram of a client according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or server that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Referring to fig. 1, fig. 1 is a schematic diagram of an application environment according to an embodiment of the present disclosure, and as shown in fig. 1, the application environment may include a terminal 01 and a server 02.
In this embodiment, the terminal 01 may include a smart phone, a desktop computer, a tablet computer, a notebook computer, a smart speaker, a digital assistant, an Augmented Reality (AR)/Virtual Reality (VR) device, a smart wearable device, and other types of entity devices. It may also include software running in a physical device, such as a virtual machine. The operating system running on the terminal in the embodiment of the present application may include, but is not limited to, an android system, an IOS system, linux, windows, and the like.
In this embodiment, the server 02 may be an independent physical server, may also be a server cluster or a distributed system formed by a plurality of physical servers, and may also be a cloud server that provides basic cloud computing services such as a cloud service, a cloud database, cloud computing, a cloud function, cloud storage, a Network service, cloud communication, a middleware service, a domain name service, a security service, a CDN (Content Delivery Network), a big data and an artificial intelligence platform.
In the embodiment of the present specification, the terminal 01 and the server 02 may be directly or indirectly connected through wired or wireless communication, and the present application is not limited herein.
In this embodiment of the present specification, the terminal 01 may include an application terminal provided with an initial active panel, and specifically, the initial active panel may be hidden with a basic control. Specifically, the basic control may include a common control that is set in combination with the business requirements and eliminates the style layout and the event function attribute. In a specific embodiment, the base control may include: and a picture control, a text control, a list control, a button control, a panel control (a form control) and the like with style layout and event function attributes removed. Specifically, as shown in fig. 2, the basic control is hidden and set on the initial active panel, and a blank initial active panel can be directly loaded when a subsequent page is generated.
In the embodiment of the specification, the basic control is hidden on the initial movable panel, so that the basic control can be directly copied subsequently, and the initial movable panel can be reused in different movable pages.
In this embodiment of the present specification, the server 02 may provide a background service for the terminal 01, and specifically, may provide a configuration file of a terminal page for the terminal 01.
In the following description, a specific embodiment of a game page drawing method according to the present application is described with a terminal 01 as an execution subject, fig. 3 is a schematic flow chart of a game page drawing method according to the embodiment of the present application, and the present specification provides operation steps of the method according to the embodiment or the flow chart, but more or fewer operation steps may be included based on conventional or non-inventive labor. The order of steps recited in the embodiments is merely one manner of performing the steps in a multitude of orders and does not represent the only order of execution. In actual system or end product execution, sequential execution or parallel execution (e.g., parallel processor or multi-threaded environment) may be possible according to the embodiments or methods shown in the figures. Specifically, as shown in fig. 3, the method may include:
s301: and responding to a page drawing request of a target page, and acquiring a configuration file of the target page.
In this embodiment of the present specification, the target page may include any active page in a game application; the configuration file may include control list information and control attribute information; specifically, the control list information may include control identifications and control types of the controls in the target page, where each control identification corresponds to one control type. Specifically, because hierarchical relationships often exist between the controls (that is, a certain control B may be drawn on another control a), in this embodiment of the present specification, the control list information may include tree-structured control list information, and each node in the tree-structured control list information corresponds to a control identifier and a control type of a control. In some specific embodiments, as shown in fig. 4, fig. 4 is a schematic diagram of control list information provided in an embodiment of the present application, and as shown in fig. 4, a control may have a child control or may not have a child control. For example, the picture control at a certain position in the page may be an individual picture control, or may also be a picture control with a button function, and correspondingly, the picture control with the button function may be provided with a sub-control: button controls (where there is a hierarchical relationship between the button controls and the picture controls); correspondingly, the button control can also have a sub-control: text controls (where there is a hierarchical relationship between button controls and text controls), and the like.
In this embodiment of the present specification, the control attribute information may represent a style layout and an event function attribute of a control in the target page. Specifically, in practical application, the control in the page is a control that performs style layout and setting of event functional attributes on the basic control, and correspondingly, the control type of the basic control corresponding to the control in the page is the control type of the control in the page. For example, the basic control corresponding to the control in the page is a button control from which the style layout and the event function attribute are removed, and correspondingly, the control type of the control in the page may be a button control.
In this embodiment of the present specification, control attribute information of different controls is different. Specifically, when the control type of the control is a button control, the control attribute information may include a position (position), a display (display), a size (size), a picture address (imageUrl), and other style layout attributes, and an event function attribute of a click event (url for processing a click event request);
when the control type of the control is an img (picture) control, the control attribute information may include style layout attributes such as position (position), display (display), size (size), picture address (imageUrl), and the like.
When the control type of the control is a panel (window) control, the control attribute information may include style layout attributes such as a position (position), a size (size), whether to display (display), a child control list, and the like.
When the control type of the control is a text control, the control attribute information may include a position (position), a size (size), whether to display (display), a font, and other style layout attributes.
When the control type of the control is a list control, the control attribute information may include style layout attributes such as a position (position), a size (size), whether to display (display), and the like, and a gap between sub-controls (including a gap in the horizontal x direction and the vertical y direction).
In addition, in this embodiment of the present specification, a panel control, a list control, a text control, an img control, and the like do not have an event function attribute, and may be configured by adding a sub-control having an event function attribute to the control, for example, adding a button control to a texture control, and accordingly, when the control includes the sub-control, the control attribute information of the control may further include a hierarchical information parent between the controls.
In practical applications, the configuration file may be pre-configured and stored in the server. In the configuration interface, basic languages such as HTML (HyperText Markup Language) may be adopted to sequentially configure the control attribute information of each control in the target page. In a specific embodiment, the following is part of the configuration information for the HTML-based configuration file:
[{"name":"bg_img","type":"img","parent":"root","size":"800,500","position":"0,0","depth":1,"url":"http://down.game.qq.com/pandora/images/wmsj/20190918103122/B312C37565C4264FE38B2C431B13E11D_1568773882.png","subgo":[{"name":"button_get","type":"button","parent":"root","size":"146,54","position":"0,0","depth":2,"url":"http://down.game.qq.com/pandora/images/wmsj/20190920192519/63F044E92ED65726465364EEF1B8A7A5_1568978719.png","ctrl":"take","action":"query"},{"name":"button_got","type":"button","parent":"root","size":"146,54","position":"0,0","depth":3,"url":"http://down.game.qq.com/pandora/images/wmsj/20190920192535/42D02829857033A09C7A39B683CB1F6E_1568978735.png","ctrl":"","action":""},{"name":"button_got","type":"text","parent":"root","size":"146,24","position":"0,0","depth":4,"text":"This is at est","FontSize":20,"FontColor":"#ff33ff"}]}]
the above "subgo" represents a child control list, the "depth" represents the upper and lower layers of the in-game control, and the corresponding control list information can be constructed based on the upper and lower layer information and the "parent" layer information.
After the control attribute information of each control in the target page is configured, a configuration file of the target page can be generated based on the attribute information of each control in the target page and stored in the server.
In this embodiment of this specification, as shown in fig. 5, the acquiring a configuration file of a target page in response to a page drawing request of the target page includes:
s3011: receiving a page drawing request of the target page, and loading the initial movable panel;
s3013: sending a configuration file acquisition request of the target page to a server;
s3015: and receiving the configuration file of the target page returned by the server.
In practical applications, after receiving a page drawing request, a local initial active panel may be directly loaded, and a configuration file may be obtained from a server.
In the embodiment of the description, the control event function attribute is directly configured in the configuration file, and even if the use experience of a related application development tool is not available, the page drawing development can be realized by configuring the configuration file in a simple editing interface, so that the difficulty of the game page drawing development is greatly reduced.
S303: and copying a basic control corresponding to the control list information from the initial active panel.
In this embodiment of the present specification, as shown in fig. 6, the copying, from the initial active panel, a base control corresponding to the control list information may include:
s3031: and traversing nodes in the control list information of the tree structure based on a depth-first algorithm.
S3033: and when each node is traversed, acquiring the control type of the control corresponding to each node.
S3035: and copying the basic control corresponding to the control type from the initial movable panel.
In the embodiment of the present specification, it is considered that some controls have a hierarchical relationship (for example, a hierarchical relationship between a control a and a control B corresponding to fig. 4), and accordingly, when drawing, a parent control (control a) needs to be drawn first, and then a child control (control B) needs to be drawn; in this embodiment of the present specification, nodes in the control list information of the tree structure may be traversed based on a depth-first algorithm (when traversing data of a tree structure type, an algorithm that traverses a root node first and then traverses child nodes of the root node is referred to as a depth-first algorithm), and when traversing each node, a control type of a control corresponding to each node is obtained, and a base control corresponding to the control type is copied from an initial active panel. Correspondingly, after a basic control is copied, the drawing operation of the basic control is executed.
In this embodiment of this specification, the copying, from the initial active panel, the basic control corresponding to the control type may include: and copying a basic control corresponding to the control type from the initial movable panel based on a preset object copy function.
In an actual application, the different types of applications correspond to different development tools, and accordingly, the different development tools have different preset object copy functions, and in a specific embodiment, taking the development tool Unity3d of the game application as an example, the preset object copy function may be Unity engine.
In still other embodiments, as shown in fig. 7, said copying the base control corresponding to the control list information from the initial active panel further comprises:
s3037: and sequentially arranging the copied basic controls according to the copying sequence.
In the embodiment of the description, after nodes are traversed based on a depth-first algorithm, copied basic controls are sequentially arranged according to the copying sequence, so that the controls with hierarchical relationships can be directly and sequentially drawn during subsequent drawing, and the processing efficiency in the process of drawing a game page is greatly improved.
S305: drawing the basic control corresponding to the control list information in the initial activity panel based on the control attribute information, and generating the target page.
In this embodiment of the present specification, after a basic control is copied, a drawing operation of the basic control may be executed; or after all the basic controls of the target page are copied, executing the drawing operation of the basic controls.
In a specific embodiment, when a scheme is adopted in which after a basic control is copied, a rendering operation of the basic control is executed, rendering the basic control corresponding to the control list information in the initial activity panel based on the control attribute information, and generating the target page may include:
1) and drawing the currently copied basic control in the initial movable panel based on the control attribute information of the currently copied basic control.
2) And when the currently copied basic control drawn in the initial activity panel corresponds to the last traversed node in the control list information of the tree structure, generating the target page.
In the embodiment of the present specification, the control identifier of each control in the target page corresponds to the control attribute information of each control in the target page one by one; accordingly, as illustrated in fig. 8, the drawing the currently copied base control in the initial active panel based on the control attribute information of the currently copied base control may include:
s901: determining a control identification corresponding to the currently copied basic control;
s903: determining control attribute information of the currently copied basic control based on the corresponding control identification;
s905: and drawing the currently copied basic control in the initial movable panel according to the determined control attribute information.
In other embodiments, when a scheme of rendering operations of basic controls is executed after all basic controls of a target page are copied, the rendering the basic controls corresponding to the control list information in the initial active panel based on the control attribute information may include:
1) drawing the basic controls based on the control attribute information of the basic controls in the initial movable panel in sequence according to the arrangement sequence of the basic controls;
2) and when the last basic control in the sequentially arranged basic controls is drawn in the initial movable panel, generating the target page.
Specifically, the specific steps of sequentially drawing each basic control may refer to the embodiment corresponding to fig. 8, and are not described herein again.
In a specific embodiment, taking a target page as an example of a game activity page, as shown in fig. 9, fig. 9 is a schematic diagram of a target page provided in an embodiment of the present application. As can be seen from fig. 9, a corresponding initial activity panel may be set in conjunction with a scene in an actual application, and then page configuration may be performed in conjunction with a basic control and a configuration file in the initial activity panel in conjunction with a corresponding activity.
According to the technical scheme provided by the embodiment of the specification, the initial activity panel is preset on the application terminal, only basic controls used for drawing the page are hidden in the initial activity panel, when the target page needs to be drawn, the configuration file comprising the control list information and the control attribute information in the target page is obtained, the style layout and the event function attribute of the controls can be directly configured based on the control attribute information, the situation that complex development tools are used for drawing the panel content is avoided, the knowledge storage requirement of developers is reduced, the development difficulty is greatly reduced, and the efficiency of drawing the game page is improved.
In other embodiments, as shown in fig. 10, the method further comprises:
s307: responding to a page refreshing instruction triggered based on the target page, and acquiring a configuration file of a refreshing page corresponding to the page refreshing instruction, wherein the configuration file of the refreshing page comprises a change configuration between the refreshing page and the target page, and the change configuration comprises change control list information and change control attribute information;
s309: copying a basic control corresponding to the change control list information from the initial movable panel;
s311: and drawing the basic control corresponding to the change control list information in the target page based on the change control attribute information, and generating the refresh page.
In this embodiment of the present specification, different active pages in the same application may share one initial active panel, and accordingly, when updating from one active page to another active page, a configuration file of a change portion between the two active pages may be obtained, and the pages are refreshed based on the configuration file of the change portion.
The embodiment of the present application further provides a game page drawing device, as shown in fig. 11, the device is provided with an initial movable panel, the initial movable panel is hidden and is provided with a basic control, the device includes:
a first configuration file obtaining module 1110, configured to obtain a configuration file of a target page in response to a page drawing request of the target page, where the configuration file includes control list information and control attribute information, and the control attribute information represents a style layout and an event function attribute of a control in the target page;
a first base control copy module 1120, configured to copy a base control corresponding to the control list information from the initial active panel;
the target page generating module 1130 may be configured to draw the basic control corresponding to the control list information in the initial activity panel based on the control attribute information, and generate the target page.
In some embodiments, the control list information includes tree-structured control list information, and each node in the tree-structured control list information corresponds to a control identifier and a control type of a control;
the first base control copy module 1120 can include:
the traversal unit is used for traversing the nodes in the control list information of the tree structure based on a depth-first algorithm;
the control type acquisition unit is used for acquiring the control type of the control corresponding to each node when traversing to each node;
a basic control copying unit, configured to copy a basic control corresponding to the control type from the initial active panel;
accordingly, after copying a basic control, the target page generating module may include:
a first basic control drawing unit, configured to draw the currently copied basic control in the initial active panel based on control attribute information of the currently copied basic control;
and the first target page generating unit is used for generating the target page when the currently copied basic control drawn in the initial active panel corresponds to the last traversed node in the control list information of the tree structure.
In some embodiments, the basic control copying unit is specifically configured to copy the basic control corresponding to the control type from the initial active panel based on a preset object copy function.
In some embodiments, the control identification of each control in the target page corresponds to the control attribute information of each control in the target page one to one;
the first base control drawing unit includes:
a control identification determining unit, configured to determine a control identification corresponding to the currently copied basic control;
a control attribute information determining unit, configured to determine control attribute information of the currently copied basic control based on the corresponding control identifier;
and the second basic control drawing unit is used for drawing the currently copied basic control in the initial movable panel according to the determined control attribute information.
In some embodiments, the first base control replication module further comprises:
the basic control sorting unit is used for sequentially sorting the copied basic controls according to the copying sequence;
correspondingly, the target page generating module comprises:
the third basic control drawing unit is used for drawing basic controls based on the control attribute information of the basic controls in the initial movable panel in sequence according to the arrangement sequence of the basic controls;
and the second target page generating unit is used for generating the target page when the last basic control in the basic controls arranged in sequence is drawn in the initial movable panel.
In some embodiments, the first profile acquisition module comprises:
a page drawing request receiving unit, configured to receive a page drawing request of the target page;
an initial movable panel loading unit for loading the initial movable panel;
a configuration file acquisition request generation unit, configured to send a configuration file acquisition request of the target page to a server;
and the configuration file receiving unit is used for receiving the configuration file of the target page returned by the server.
In some embodiments, the method further comprises:
a second configuration file obtaining module, configured to, in response to a page refresh instruction triggered based on the target page, obtain a configuration file of a refresh page corresponding to the page refresh instruction, where the configuration file of the refresh page includes a change configuration between the refresh page and the target page, and the change configuration includes change control list information and change control attribute information;
the second basic control copying module is used for copying the basic control corresponding to the change control list information from the initial movable panel;
and the refreshing page generating module is used for drawing the basic control corresponding to the change control list information in the target page based on the change control attribute information and generating the refreshing page.
The device and method embodiments in the device embodiment are based on the same application concept.
The embodiment of the application provides game page drawing equipment, which is provided with an initial movable panel, wherein a basic control is hidden in the initial movable panel, the game page drawing equipment comprises a processor and a memory, at least one instruction or at least one section of program is stored in the memory, and the at least one instruction or the at least one section of program is loaded and executed by the processor to realize the game page drawing method provided by the embodiment of the method.
The memory may be used to store software programs and modules, and the processor may execute various functional applications and data processing by operating the software programs and modules stored in the memory. The memory can mainly comprise a program storage area and a data storage area, wherein the program storage area can store an operating system, application programs needed by functions and the like; the storage data area may store data created according to use of the apparatus, and the like. Further, the memory may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory may also include a memory controller to provide the processor access to the memory.
The method provided by the embodiment of the application can be executed in a client (a mobile terminal, a computer terminal), a server or a similar operation device. Taking the operation on the client as an example, fig. 12 is a schematic structural diagram of a client provided in the embodiment of the present application, and as shown in fig. 12, the client may be used to implement the information interaction method provided in the foregoing embodiment. Specifically, the method comprises the following steps:
the client may include components such as RF (Radio Frequency) circuitry 1210, memory 1220 including one or more computer-readable storage media, input unit 1230, display unit 1240, sensors 1250, audio circuitry 1260, WiFi (wireless fidelity) module 1270, processor 1280 including one or more processing cores, and power supply 1290. Those skilled in the art will appreciate that the client architecture shown in fig. 12 does not constitute a limitation on the client, and may include more or fewer components than shown, or some components in combination, or a different arrangement of components. Wherein:
the RF circuit 1210 is configured to receive and transmit signals during a message transmission or communication process, and in particular, receive downlink information of a base station and then send the received downlink information to one or more processors 1280 for processing; in addition, data relating to uplink is transmitted to the base station. In general, RF circuit 1210 includes, but is not limited to, an antenna, at least one Amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, an LNA (Low Noise Amplifier), a duplexer, and the like. In addition, the RF circuit 1210 may also communicate with networks and other clients through wireless communication. The wireless communication may use any communication standard or protocol, including but not limited to GSM (Global System for Mobile communications), GPRS (General Packet Radio Service), CDMA (Code Division Multiple Access), WCDMA (Wideband Code Division Multiple Access), LTE (Long Term Evolution), email, SMS (Short Messaging Service), and the like.
The memory 1220 may be used to store software programs and modules, and the processor 1280 executes various functional applications and data processing by operating the software programs and modules stored in the memory 1220. The memory 1220 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, application programs required for functions, and the like; the storage data area may store data created according to the use of the client, and the like. Further, the memory 1220 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 1220 may also include a memory controller to provide the processor 1280 and the input unit 1230 access to the memory 1220.
The input unit 1230 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control. In particular, the input unit 1230 may include a touch-sensitive surface 1231 and other input devices 1232. The touch-sensitive surface 1231, also referred to as a touch display screen or a touch pad, may collect touch operations by a user on or near the touch-sensitive surface 1231 (e.g., operations by a user on or near the touch-sensitive surface 1231 using a finger, a stylus, or any other suitable object or attachment), and drive the corresponding connection device according to a predetermined program. Alternatively, the touch-sensitive surface 1231 may comprise both touch detection means and touch controller portions. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, and sends the touch point coordinates to the processor 1280, and can receive and execute commands sent by the processor 1280. Additionally, the touch-sensitive surface 1231 can be implemented in a variety of types, including resistive, capacitive, infrared, and surface acoustic wave. The input unit 1230 may include other input devices 1232 in addition to the touch-sensitive surface 1231. In particular, other input devices 1232 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 1240 may be used to display information input by or provided to the user as well as various graphical user interfaces of the client, which may be made up of graphics, text, icons, video, and any combination thereof. The Display unit 1240 may include a Display panel 1241, and optionally, the Display panel 1241 may be configured in the form of an LCD (Liquid Crystal Display), an OLED (Organic Light-Emitting Diode), or the like. Further, touch-sensitive surface 1231 may overlay display panel 1241, and when touch-sensitive surface 1231 detects a touch operation thereon or thereabout, processor 1280 may determine the type of touch event, and processor 1280 may then provide a corresponding visual output on display panel 1241 based on the type of touch event. Touch-sensitive surface 1231 and display panel 1241 may be implemented as two separate components for input and output functions, although touch-sensitive surface 1231 may be integrated with display panel 1241 for input and output functions in some embodiments.
The client may also include at least one sensor 1250, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that adjusts the brightness of the display panel 1241 according to the brightness of ambient light, and a proximity sensor that turns off the display panel 1241 and/or the backlight when the client moves to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when the device is stationary, and can be used for applications (such as horizontal and vertical screen switching, related games, magnetometer attitude calibration) for identifying client gestures, and related functions (such as pedometer and tapping) for vibration identification; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which may be further configured at the client, detailed description is omitted here.
Audio circuit 1260, speaker 1261, microphone 1262 may provide an audio interface between a user and the client. The audio circuit 1260 can transmit the received electrical signal converted from the audio data to the speaker 1261, and the audio signal is converted into a sound signal by the speaker 1261 and output; on the other hand, the microphone 1262 converts the collected sound signal into an electric signal, which is received by the audio circuit 1260 and converted into audio data, which is then processed by the audio data output processor 1280 and then transmitted to, for example, another client via the RF circuit 1210, or the audio data is output to the memory 1220 for further processing. The audio circuit 1260 may also include an earbud jack to provide communication of peripheral headphones with the client.
WiFi belongs to short distance wireless transmission technology, and the client can help the user send and receive e-mail, browse web page and access streaming media, etc. through the WiFi module 1270, which provides wireless broadband internet access for the user. Although fig. 12 shows the WiFi module 1270, it is understood that it does not belong to the essential constitution of the client and can be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 1280 is a control center of the client, connects various parts of the entire client by using various interfaces and lines, and performs various functions of the client and processes data by running or executing software programs and/or modules stored in the memory 1220 and calling data stored in the memory 1220, thereby performing overall monitoring of the client. Optionally, processor 1280 may include one or more processing cores; preferably, the processor 1280 may integrate an application processor, which mainly handles operating systems, user interfaces, application programs, etc., and a modem processor, which mainly handles wireless communications. It is to be appreciated that the modem processor described above may not be integrated into the processor 1280.
The client further includes a power supply 1290 (e.g., a battery) for supplying power to each component, and preferably, the power supply may be logically connected to the processor 1280 through a power management system, so that functions of managing charging, discharging, and power consumption are implemented through the power management system. Power supply 1290 may also include any component or components of one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
Although not shown, the client may further include a camera, a bluetooth module, and the like, which are not described herein again. Specifically, in this embodiment, the display unit of the client is a touch screen display, the client further includes a memory and one or more programs, where the one or more programs are stored in the memory and configured to be executed by the one or more processors according to the instructions of the method embodiments of the present invention.
Embodiments of the present application further provide a storage medium, where the storage medium may be disposed in a device to store at least one instruction or at least one program for implementing a game page drawing method in the method embodiments, and the at least one instruction or the at least one program is loaded and executed by the processor to implement the game page drawing method provided in the method embodiments.
Alternatively, in this embodiment, the storage medium may be located in at least one network server of a plurality of network servers of a computer network. Optionally, in this embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
According to the game page drawing method, the game page drawing device, the server or the storage medium, the initial activity panel is preset on the application terminal, and only the basic control used for drawing the page is hidden in the initial activity panel, when the target page needs to be drawn, the configuration file comprising the control list information and the control attribute information in the target page is obtained, based on the control attribute information, the style layout and the event function attribute of the control can be directly configured, the situation that a complex development tool is used for drawing the content of the panel is avoided, the knowledge reserve requirement of developers is reduced, the development difficulty is greatly reduced, and the game page drawing efficiency is improved.
It should be noted that: the sequence of the embodiments of the present application is only for description, and does not represent the advantages and disadvantages of the embodiments. And specific embodiments thereof have been described above. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, as for the device and server embodiments, since they are substantially similar to the method embodiments, the description is simple, and the relevant points can be referred to the partial description of the method embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware to implement the above embodiments, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk, an optical disk, or the like.
The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (9)

1. A game page drawing method is applied to an application terminal provided with an initial movable panel, wherein the initial movable panel is hidden with a basic control, and the method comprises the following steps:
responding to a page drawing request of a target page, acquiring a configuration file of the target page, wherein the configuration file comprises control list information and control attribute information, the control attribute information represents the style layout and the event function attribute of a control in the target page, the control list information comprises control list information of a tree structure, and each node in the control list information of the tree structure corresponds to a control identifier and a control type of one control;
copying a base control corresponding to the control list information from the initial active panel, wherein copying the base control corresponding to the control list information from the initial active panel comprises: traversing nodes in the control list information of the tree structure based on a depth-first algorithm; when traversing to each node, acquiring a control type of a control corresponding to each node; copying a basic control corresponding to the control type from the initial movable panel based on a preset object copy function;
and drawing a copied basic control corresponding to the control type in the initial movable panel based on the control attribute information, generating the target page, and loading the initial movable panel with the hidden basic control in a blank panel mode when the page is generated.
2. The method of claim 1, wherein the rendering of the copied base control corresponding to the control type in the initial active panel based on the control property information, and wherein the generating of the target page comprises:
after a basic control is copied, drawing the currently copied basic control in the initial movable panel based on control attribute information of the currently copied basic control;
and when the currently copied basic control drawn in the initial activity panel corresponds to the last traversed node in the control list information of the tree structure, generating the target page.
3. The method according to claim 1, wherein the control identification of each control in the target page corresponds to the control attribute information of each control in the target page in a one-to-one manner;
the drawing the currently copied base control in the initial active panel based on the control attribute information of the currently copied base control comprises:
determining a control identification corresponding to the currently copied basic control;
determining control attribute information of the currently copied basic control based on the corresponding control identification;
and drawing the currently copied basic control in the initial movable panel according to the determined control attribute information.
4. The method of claim 1, wherein copying the base control corresponding to the control list information from the initial active panel further comprises:
sequentially arranging the copied basic controls according to the copying sequence;
correspondingly, drawing the copied basic control corresponding to the control type in the initial active panel based on the control attribute information, and generating the target page includes:
drawing the basic controls based on the control attribute information of the basic controls in the initial movable panel in sequence according to the arrangement sequence of the basic controls;
and when the last basic control in the sequentially arranged basic controls is drawn in the initial movable panel, generating the target page.
5. The method of claim 1, wherein the obtaining the configuration file of the target page in response to the page drawing request of the target page comprises:
receiving a page drawing request of the target page, and loading the initial movable panel;
sending a configuration file acquisition request of the target page to a server;
and receiving the configuration file of the target page returned by the server.
6. The method of claim 1, further comprising:
responding to a page refreshing instruction triggered based on the target page, and acquiring a configuration file of a refreshing page corresponding to the page refreshing instruction, wherein the configuration file of the refreshing page comprises a change configuration between the refreshing page and the target page, and the change configuration comprises change control list information and change control attribute information;
copying a basic control corresponding to the change control list information from the initial movable panel;
and drawing the basic control corresponding to the change control list information in the target page based on the change control attribute information, and generating the refresh page.
7. A game page drawing device is characterized in that the device is provided with an initial movable panel, the initial movable panel is hidden and provided with a basic control, and the device comprises:
the first configuration file acquisition module is used for responding to a page drawing request of a target page and acquiring a configuration file of the target page, wherein the configuration file comprises control list information and control attribute information, the control attribute information represents the style layout and the event function attribute of a control in the target page, the control list information comprises control list information of a tree structure, and each node in the control list information of the tree structure corresponds to a control identifier and a control type of one control;
the first base control copy module includes: the traversal unit is used for traversing the nodes in the control list information of the tree structure based on a depth-first algorithm; the control type acquisition unit is used for acquiring the control type of the control corresponding to each node when traversing to each node; a basic control copying unit, configured to copy a basic control corresponding to the control type from the initial active panel based on a preset object copy function;
and the target page generation module is used for drawing a copied basic control corresponding to the control type in the initial movable panel based on the control attribute information, generating the target page, and loading the initial movable panel with the basic control in a blank panel mode when the page is generated in a hidden mode.
8. A game page rendering device, characterized in that the device has an initial active panel hidden with underlying controls, the device comprising a processor and a memory, wherein at least one instruction or at least one program is stored in the memory, and wherein the at least one instruction or the at least one program is loaded and executed by the processor to implement the game page rendering method according to any one of claims 1 to 6.
9. A computer-readable storage medium, in which at least one instruction or at least one program is stored, the at least one instruction or the at least one program being loaded and executed by a processor to implement the game page rendering method according to any one of claims 1 to 6.
CN202010001186.8A 2020-01-02 2020-01-02 Game page drawing method, device, equipment and storage medium Active CN111124412B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010001186.8A CN111124412B (en) 2020-01-02 2020-01-02 Game page drawing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010001186.8A CN111124412B (en) 2020-01-02 2020-01-02 Game page drawing method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111124412A CN111124412A (en) 2020-05-08
CN111124412B true CN111124412B (en) 2021-08-17

Family

ID=70507377

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010001186.8A Active CN111124412B (en) 2020-01-02 2020-01-02 Game page drawing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111124412B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111610972B (en) * 2020-05-22 2023-10-13 北京百度网讯科技有限公司 Page generation method, device, equipment and storage medium
CN111708535A (en) * 2020-06-17 2020-09-25 网易(杭州)网络有限公司 Image-text display control method and device and electronic equipment
CN112163174B (en) * 2020-09-29 2024-01-09 广州博冠信息科技有限公司 Message display method and device, storage medium and computer equipment
CN112256346A (en) * 2020-10-14 2021-01-22 北京字跳网络技术有限公司 Control display method and device and electronic equipment
CN112799669B (en) * 2021-04-06 2021-07-06 武汉元光科技有限公司 Method and device for generating application program interface layout code and electronic equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104239044A (en) * 2014-09-05 2014-12-24 北京航天自动控制研究所 Dynamic generation method for graphical user interface
CN106406832A (en) * 2015-07-30 2017-02-15 中兴通讯股份有限公司 Generation control method and device of web interface
CN107977203A (en) * 2017-10-20 2018-05-01 捷开通讯(深圳)有限公司 The creation method of storage device, application program control and user interface

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8250477B1 (en) * 2008-11-04 2012-08-21 Sensei, Inc. Mobile client application for managing user interface components
CN108427557A (en) * 2017-05-10 2018-08-21 平安科技(深圳)有限公司 A kind of control layout display control method, device and computer readable storage medium
CN107870798A (en) * 2017-09-26 2018-04-03 五八有限公司 The page layout processing method and terminal of application program

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104239044A (en) * 2014-09-05 2014-12-24 北京航天自动控制研究所 Dynamic generation method for graphical user interface
CN106406832A (en) * 2015-07-30 2017-02-15 中兴通讯股份有限公司 Generation control method and device of web interface
CN107977203A (en) * 2017-10-20 2018-05-01 捷开通讯(深圳)有限公司 The creation method of storage device, application program control and user interface

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
【Unity3D入门教程】游戏开发利器UG;雁回晴空;《https://blog.csdn.net/zzlyw/article/details/54235357》;20170108;第1-5页 *
unity3d通过代码在canvas中添加UI控件;小草的趣味生活;《https://jingyan.baidu.com/article/e5c39bf5f279de39d760330d.html》;20180123;第3页 *

Also Published As

Publication number Publication date
CN111124412A (en) 2020-05-08

Similar Documents

Publication Publication Date Title
CN111124412B (en) Game page drawing method, device, equipment and storage medium
CN110582017B (en) Video playing method, device, terminal and storage medium
CN110795666B (en) Webpage generation method, device, terminal and storage medium
CN106775637B (en) Page display method and device for application program
KR102084977B1 (en) Multimedia poster generation method and terminal
CN111178012A (en) Form rendering method, device and equipment and storage medium
CN108345543B (en) Data processing method, device, equipment and storage medium
CN111338646B (en) Management method of micro-service architecture and related device
CN111408136A (en) Game interaction control method, device and storage medium
CN108039963B (en) Container configuration method and device and storage medium
CN110399583B (en) Page display method and device, electronic equipment and storage medium
CN107666406B (en) Intelligent card display method and device
CN107368298B (en) Text control simulation touch method, terminal and computer readable storage medium
CN108900407B (en) Method and device for managing session record and storage medium
CN112347545A (en) Building model processing method and device, computer equipment and storage medium
CN112233211A (en) Animation production method and device, storage medium and computer equipment
CN110020293A (en) Multi-medium data methods of exhibiting, device and storage medium
CN113377469A (en) Business interface display method and device for mobile application, terminal and storage medium
CN110300047B (en) Animation playing method and device and storage medium
CN111359210B (en) Data processing method and device, electronic equipment and storage medium
US20160283047A1 (en) Login interface displaying method and apparatus
CN110196662B (en) Method, device, terminal and storage medium for displaying synchronization state
CN105320532B (en) Method, device and terminal for displaying interactive interface
CN114510417A (en) Image rendering effect testing method and device, electronic equipment and storage medium
CN112486567A (en) Code merging request sending method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant