Editor generation method and processing method for processing game template data
By generating model files and view files for game template data and generating corresponding editors, the problem of unintuitive processing of game template data in game development is solved, and efficient and accurate data processing and game development efficiency is achieved.
Patent Information
- Application Number
- CN202011492313.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-16
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2040-12-16
AI Technical Summary
During game development, a large amount of game template data is usually stored in plain text or table form, resulting in the data display being not intuitive enough, and developers are time-consuming and labor-intensive when processing data and are prone to errors.
By generating model files and view files for game template data and generating corresponding editors based on these files, the editor can visually display the content of game template data on the editor page, allowing users to process the data according to page operations.
The intuitive display of game template data is realized, which improves the efficiency of users in processing game template data, reduces the error rate of data processing, and improves game development efficiency.
Smart Images

Figure CN112597266B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer application technology, and in particular to an editor generation method and a processing method for processing game template data. Background Art
[0002] During the game development process, a game usually involves a large number of game elements, each of which can be described by pre-configured game template data.
[0003] However, a large amount of game template data is usually stored in plain text or table format, and the data display is not intuitive enough, which makes it very time-consuming and labor-intensive for developers to process the data, and it is very error-prone. Summary of the invention
[0004] In order to solve the above technical problems or at least partially solve the above technical problems, the embodiments of the present disclosure provide an editor generation method and a processing method for processing game template data.
[0005] In a first aspect, an embodiment of the present disclosure provides an editor generation method for processing game template data, comprising:
[0006] Obtaining a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data;
[0007] Generate a model file for the game template data according to the business processing rules of the game template data and a preset model template file;
[0008] Generate a view file for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines a page layout corresponding to each field and a page operation response function corresponding to each field;
[0009] An editor corresponding to the game template data is generated according to the view file and the model file, so that the game template data is processed according to the user's operation on the editor page.
[0010] In a second aspect, the embodiments of the present disclosure further provide a method for processing game template data, which is implemented based on an editor. The editor is obtained by using any editor generation method for processing game template data provided by the embodiments of the present disclosure. The processing method includes:
[0011] Generate a data processing request according to the user's operation on the editor page of the game template data;
[0012] Determining a business processing rule corresponding to the data processing request using a model file of the editor;
[0013] The fields and data carried in the data processing request are processed according to the business processing rules.
[0014] In a third aspect, the embodiment of the present disclosure further provides an editor generation device for processing game template data, comprising:
[0015] A configuration file acquisition module, used to acquire a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data;
[0016] A model file generation module, used to generate a model file for the game template data according to the business processing rules of the game template data and a preset model template file;
[0017] A view file generation module, used to generate a view file for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines a page layout corresponding to each field and a page operation response function corresponding to each field;
[0018] The editor generation module is used to generate an editor corresponding to the game template data based on the view file and the model file, so that the game template data can be processed according to the user's operation on the editor page.
[0019] In a fourth aspect, the embodiments of the present disclosure further provide a game template data processing device, which is implemented based on an editor, and the editor is obtained by using any editor generation method for processing game template data provided by the embodiments of the present disclosure, and the processing device includes:
[0020] A request generation module, used to generate a data processing request according to the user's operation on the editor page of the game template data;
[0021] A processing rule determination module, used to determine a business processing rule corresponding to the data processing request using a model file of the editor;
[0022] The request processing module is used to process the fields and data carried in the data processing request according to the business processing rules.
[0023] In a fifth aspect, an embodiment of the present disclosure further provides an electronic device, comprising a memory and a processor, wherein: a computer program is stored in the memory, and when the computer program is executed by the processor, the electronic device implements any editor generation method or game template data processing method provided in an embodiment of the present disclosure.
[0024] In a sixth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a computing device, the computing device implements any editor generation method or game template data processing method provided in an embodiment of the present disclosure.
[0025] The technical solution provided by the disclosed embodiment has at least the following advantages over the prior art: in the disclosed embodiment, by generating a model file and a view file for the game template data, and generating a corresponding editor for the game template data based on the model file and the view file, the editor can visualize the content of the game template data on the editor page, so that the game template data can be processed according to the user's operations on the editor page, which not only realizes the intuitive display of the game template data, but also improves the efficiency of the user in processing the game template data, reduces the error rate of data processing, and improves the efficiency of game development. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0027] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0028] Figure 1 A flowchart of an editor generation method for processing game template data provided by an embodiment of the present disclosure;
[0029] Figure 2 A schematic diagram of an editor page provided in an embodiment of the present disclosure;
[0030] Figure 3 A flowchart of a method for processing game template data provided by an embodiment of the present disclosure;
[0031] Figure 4 A schematic diagram of the structure of an editor generating device for processing game template data provided by an embodiment of the present disclosure;
[0032] Figure 5 A schematic diagram of the structure of a game template data processing device provided by an embodiment of the present disclosure;
[0033] Figure 6A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0034] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.
[0035] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.
[0036] Figure 1 A flowchart of an editor generation method for processing game template data provided in an embodiment of the present disclosure. The editor generation method can be executed by an editor generation device for processing game template data. The device can be implemented in software and / or hardware and can be integrated on any electronic device with computing capability.
[0037] In the disclosed embodiment, based on the MVC (Model View Controller) architecture, a corresponding editor is generated for the game template data. In the MVC architecture, the model is responsible for storing the central data of the system; the view is used to display information to the user (multiple views can be defined); the controller is used to process the information input by the user, is responsible for reading data from the view, controlling user input, and sending data to the model. It is the part of the application that handles user interaction and is responsible for managing interaction control with the user. The view and the controller together constitute the user interface, and each view has an associated controller component.
[0038] like Figure 1 As shown, the editor generation method for processing game template data provided by the embodiment of the present disclosure may include:
[0039] S101. Obtain a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data.
[0040] Among them, the game template data is used to describe the attributes of the game elements. Game elements can be any object required in the process of building a game scene (or game screen), such as player characters, animal characters, buildings, props, etc. These game elements can all be described using pre-set game template data, and each field in the game template data is used to refine the specific attribute characteristics of the game elements. For example, for a player character, the corresponding game template data may include but is not limited to fields such as name, character ID, equipment, game level, attack ability, and defense ability.
[0041] During the game development process, users (ie, developers) can use the editor provided by the embodiment of the present disclosure to define specific data of fields in the game template data corresponding to the game elements (ie, data entry or data editing) to construct different game elements.
[0042] S102: Generate a model file for the game template data according to the business processing rules of the game template data and the preset model template file.
[0043] Business processing rules are used to define the specific implementation methods of data processing supported by game template data. The preset model template file is a general preset template file, which not only defines the generation format of the model file (model file), but also defines a variety of processing logics, such as processing logic including at least one of the following: data filtering, data preservation, data deletion and data import, so that the editor finally generated supports a variety of data processing for the game template data. Among them, data filtering refers to filtering data according to conditions such as data ID, data number or name; data preservation refers to saving data in the database; data deletion refers to deleting specified data from the database; data import refers to saving the data corresponding to the field in the database. If there is duplicate data in the database, the previously stored historical data can be deleted according to the data ID before storing new data.
[0044] The processing logic defined in the preset model template file can be dynamically set according to the game template data processing requirements during the game development process, and the embodiments of the present disclosure do not make specific limitations.
[0045] S103. Generate a view file for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines a page layout corresponding to each field and a page operation response function corresponding to each field.
[0046] The preset view template file is also a general preset template file. The page layout defined in the preset view template file may include the page layout of different fields determined based on the field classification, such as the display position and display style of each type of field in the page, and the display position and display style of the data input box corresponding to the field. The field classification can be determined according to the attributes of different game elements. For example, the field classification may include basic attribute class fields, action attribute class fields, or list data class fields. The page operation response function corresponding to each field may include a response function corresponding to the user's data entry (or input), modification, deletion, and saving operations.
[0047] In addition, the configuration file may also include the data format corresponding to each field, so that the user can enter data that conforms to the data format on the editor page. Correspondingly, the preset view template file may also include the logic for generating data input prompt information corresponding to the data format, so that the data input prompt information can be displayed on the final generated editor page, increasing the friendliness of page interaction.
[0048] Generally, the fields included in different game template data may be different, but the data processing supported by the game template data is the same. By utilizing preset model template files and preset view template files to generate model files and view files for the game template data, it helps to improve the generation efficiency of the editor corresponding to the game template data.
[0049] S104. Generate an editor corresponding to the game template data based on the view file and the model file, so that the game template data can be processed according to the user's operation on the editor page.
[0050] The editor can be implemented in the form of a web application, that is, the editor page can be a web page. The electronic device displays the content of the game template data on the editor page, and processes the game template data according to the user's operation on the editor page. For example, the user operation may include data entry, query, modification, deletion or import, and then the processing result can be stored in any available database, such as a mongodb database (a database based on distributed file storage), or the processing result can be displayed on a page.
[0051] On the basis of the above technical solution, further, the preset view template file also defines global controls corresponding to the game template data and response functions corresponding to each global control; the global controls include at least one of the following: data creation control, data copy control, data deletion control, data filter, data save control, data reset control and data import control. Among them, the data creation control is used to create a data object, which means packaging the game template data into an object and defining the get, set, and show functions of each field; the data deletion control is used to delete the specified data; the data reset control is used to reset the data, which means re-modifying or re-entering the data; the data import control is used to import data and submit it to the background for saving (i.e. saving to the database). Data import supports the simultaneous import of multiple data for multiple fields.
[0052] That is, the above-mentioned global controls can be displayed on the final generated editor page, so as to facilitate users to perform various data processing on the game template data. Global controls refer to operation controls corresponding to the entire game template data. For example, when a user clicks on the data save control in the global control on the editor page, it can trigger a request to save the data of each field in a game template data displayed on the current page; or, for example, when a user clicks on the data filter, it can trigger a filter request for the game template data corresponding to the data number or data name entered by the user. The specific display position and display style of each global control on the page are not specifically limited in the embodiment of the present disclosure and can be flexibly set in the preset view template file.
[0053] Optionally, the preset view template file also defines control adding events corresponding to preset fields and response functions corresponding to each control to be added; control adding events include at least one of the following: data saving control adding events, data adding control adding events, data deleting control adding events, data modifying control adding events, and data position moving control adding events. Among them, data adding refers to saving the data entered by the user into the database; data position moving includes moving up, down, left, or right, etc.
[0054] That is, in the disclosed example, for some preset fields displayed on the editor page, operation controls for these preset fields can be added separately and displayed on the editor page, so as to facilitate the user to edit each field in the game template data in a fine-grained manner. The preset field can be pre-defined by the user in the preset view template file according to data processing requirements, for example, a list data class field is set as the preset field.
[0055] Figure 2 The schematic diagram of an editor page provided in the embodiment of the present disclosure is used to exemplify the embodiment of the present disclosure, but should not be understood as a specific limitation of the embodiment of the present disclosure. Figure 2As shown, the upper part of the game editor page displays the game template data list control, data creation control, data copy control, data deletion control and data filter. In the lower display box corresponding to the game template data list control, multiple game template data can be displayed according to the game template data name. In the filter, users can search for the required template data according to the number or name of the game template data, and the data search results can be displayed on the editor page. In the middle part of the game editor page, the fields of the basic attribute class are displayed, and multiple fields and the input boxes corresponding to the fields are specifically displayed. Users can enter the specific data corresponding to each field in the input box. In the lower part of the game editor page, the list data class field is displayed, and the data up control, data down control, and data deletion control for the field are also displayed. In addition, for other individual fields, data addition controls and data modification controls can also be displayed, so as to achieve fine-grained processing of each field.
[0056] also, Figure 2 The game editor page shown also displays three global controls: data save control, data reset control, and data import control. In addition, the game editor page supports separating strings for multiple fields according to predefined characters to form multiple data and submit them to the background for saving.
[0057] In the disclosed embodiment, by generating a model file and a view file for the game template data, and generating a corresponding editor for the game template data based on the model file and the view file, the editor can visualize the content of the game template data on the editor page, so that the game template data can be processed according to the user's operations on the editor page, which not only realizes the intuitive display of the game template data, but also improves the efficiency of the user in processing the game template data, reduces the error rate of data processing, and improves the efficiency of game development.
[0058] Figure 3 A flowchart of a method for processing game template data provided by an embodiment of the present disclosure, the method for processing game template data is implemented based on a pre-generated editor, and the editor is obtained by using any editor generation method for processing game template data provided by an embodiment of the present disclosure. For the contents not explained in detail in the following embodiments, reference can be made to the description in the above embodiments.
[0059] The game template data processing method provided by the embodiment of the present disclosure may be executed by a game template data processing device, which may be implemented using software and / or hardware and may be integrated on any electronic device with computing capabilities.
[0060] like Figure 3 As shown, the game template data processing method provided by the embodiment of the present disclosure includes:
[0061] S301. Generate a data processing request according to the user's operation on the editor page of the game template data.
[0062] For example, the editor page is as follows Figure 2 As shown, the user can perform operations such as data entry, query, modification, deletion, and import on the editor page. After the electronic device detects the user's page operation, it generates a data processing request corresponding to the user's page operation. The processing request may include the field that the user requests to process and the data corresponding to the field, and the data may be the data currently input by the user. For example, the data processing request is used to request to modify the data (such as text data) corresponding to the "description" field in the game template data, and the data processing request may include the field "description" and the modified data corresponding to the field.
[0063] S302: Determine the business processing rules corresponding to the data processing request using the model file of the editor.
[0064] Business processing rules are used to define the specific implementation methods of data processing supported by game template data, for example, the specific implementation methods corresponding to operations such as data entry, query, modification, deletion, and import.
[0065] S303: Process the fields and data carried in the data processing request according to the business processing rules.
[0066] The results of processing the game template data can be stored in any available database or displayed on the editor page.
[0067] In the disclosed embodiment, the game template data is visualized using a pre-generated editor, and the user can process the game template data conveniently and efficiently, thereby improving the efficiency of game development.
[0068] Figure 4 A schematic diagram of the structure of an editor generation device for processing game template data provided in an embodiment of the present disclosure; the device may be implemented using software and / or hardware and may be integrated on any electronic device with computing capabilities.
[0069] like Figure 4 As shown, the editor generation device 400 for processing game template data provided by the embodiment of the present disclosure may include a configuration file acquisition module 401, a model file generation module 402, a view file generation module 403 and an editor generation module 404, wherein:
[0070] Configuration file acquisition module 401, used to acquire the configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data;
[0071] A model file generation module 402, for generating a model file for the game template data according to the business processing rules of the game template data and a preset model template file;
[0072] The view file generation module 403 is used to generate a view file for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines the page layout corresponding to each field and the page operation response function corresponding to each field;
[0073] The editor generation module 404 is used to generate an editor corresponding to the game template data based on the view file and the model file, so that the game template data can be processed according to the user's operation on the editor page.
[0074] Among them, the game template data is used to describe the properties of game elements.
[0075] Optionally, the processing logic defined in the preset model template file includes at least one of the following:
[0076] Data filtering, data saving, data deletion and data import.
[0077] Optionally, the preset view template file also defines global controls corresponding to the game template data and response functions corresponding to each global control;
[0078] The global control includes at least one of the following: a data creation control, a data copy control, a data deletion control, a data filter, a data save control, a data reset control, and a data import control.
[0079] Optionally, the preset view template file also defines a control adding event corresponding to the preset field and a response function corresponding to each control to be added;
[0080] The control adding event includes at least one of the following: a data saving control adding event, a data adding control adding event, a data deleting control adding event, a data modifying control adding event and a data position moving control adding event.
[0081] The editor generation device for processing game template data provided in the embodiments of the present disclosure can execute any editor generation method for processing game template data provided in the embodiments of the present disclosure, and has the corresponding functional modules and beneficial effects of the execution method. Contents not described in detail in the embodiments of the present disclosure device can refer to the description in any method embodiment of the present disclosure.
[0082] Figure 5A schematic diagram of the structure of a game template data processing device provided in an embodiment of the present disclosure. The device can be implemented using software and / or hardware and can be integrated on any electronic device with computing capabilities.
[0083] The game template data processing device provided in the embodiment of the present disclosure is implemented based on a pre-generated editor, and the editor is obtained using any editor generation method for processing game template data provided in the embodiment of the present disclosure. For details, please refer to the explanation in the above method embodiment.
[0084] like Figure 5 As shown, the game template data processing device 500 provided in the embodiment of the present disclosure may include a request generating module 501, a processing rule determining module 502 and a request processing module 503, wherein:
[0085] The request generation module 501 is used to generate a data processing request according to the user's operation on the editor page of the game template data;
[0086] A processing rule determination module 502, used to determine a business processing rule corresponding to a data processing request using a model file of an editor;
[0087] The request processing module 503 is used to process the fields and data carried in the data processing request according to the business processing rules.
[0088] The game template data processing device provided in the embodiment of the present disclosure can execute any game template data processing method provided in the embodiment of the present disclosure, and has the corresponding functional modules and beneficial effects of the execution method. The contents not described in detail in the embodiment of the device of the present disclosure can refer to the description in any method embodiment of the present disclosure.
[0089] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure is used to exemplify an electronic device that implements an editor generation method or a game template data processing method for processing game template data provided in an embodiment of the present disclosure. The electronic device in the embodiment of the present disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, smart home devices, wearable electronic devices, servers, etc. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and occupation scope of the embodiments of the present disclosure.
[0090] like Figure 6 As shown, the electronic device 600 includes one or more processors 601 and a memory 602 .
[0091] The processor 601 may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device 600 to perform desired functions.
[0092] The memory 602 may include one or more computer program products, and the computer program product may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and / or cache memory (cache), etc. Non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on a computer-readable storage medium, and the processor 601 may run the program instructions to implement the editor generation method or game template data processing method for processing game template data provided in the embodiment of the present disclosure, and other desired functions may also be implemented. Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.
[0093] On the one hand, the editor generation method for processing game template data provided by the embodiment of the present disclosure may include: obtaining a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data; generating a model file for the game template data based on the business processing rules of the game template data and a preset model template file; generating a view file for the game template data based on the configuration file and a preset view template file; wherein the preset view template file defines a page layout corresponding to the various fields and a page operation response function corresponding to the various fields; generating an editor corresponding to the game template data based on the view file and the model file, so that the game template data is processed according to the user's operations on the editor page.
[0094] On the other hand, the game template data processing method provided by the embodiment of the present disclosure may include: generating a data processing request based on the user's operation on the editor page of the game template data; using the model file of the editor to determine the business processing rules corresponding to the data processing request; and processing the fields and data carried by the data processing request according to the business processing rules.
[0095] It should be understood that the electronic device 600 can also execute other optional implementation schemes provided by the method embodiment of the present disclosure.
[0096] In one example, the electronic device 600 may further include: an input device 603 and an output device 604 , and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).
[0097] In addition, the input device 603 may also include, for example, a keyboard, a mouse, and the like.
[0098] The output device 604 can output various information to the outside, including the determined distance information, direction information, etc. The output device 604 can include, for example, a display, a speaker, a printer, a communication network and a remote output device connected thereto, and the like.
[0099] Of course, to simplify, Figure 6 Only some of the components related to the present disclosure in the electronic device 600 are shown, and components such as a bus, an input / output interface, etc. are omitted. In addition, according to specific application situations, the electronic device 600 may also include any other appropriate components.
[0100] In addition to the above-mentioned methods and devices, the embodiments of the present disclosure may also be a computer program product, which includes computer program instructions, which, when executed by a processor, enable a computing device to implement any editor generation method or game template data processing method provided by the embodiments of the present disclosure for processing game template data.
[0101] The computer program product may be written in any combination of one or more programming languages to write program code for performing the operations of the disclosed embodiments, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user electronic device, partially on the user electronic device, as a separate software package, partially on the user electronic device and partially on a remote electronic device, or entirely on a remote electronic device.
[0102] In addition, the embodiments of the present disclosure may also provide a computer-readable storage medium having computer program instructions stored thereon. When the computer program instructions are executed by a processor, the computing device implements any editor generation method or game template data processing method provided by the embodiments of the present disclosure for processing game template data.
[0103] On the one hand, the editor generation method for processing game template data provided by the embodiment of the present disclosure may include: obtaining a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data; generating a model file for the game template data based on the business processing rules of the game template data and a preset model template file; generating a view file for the game template data based on the configuration file and a preset view template file; wherein the preset view template file defines a page layout corresponding to the various fields and a page operation response function corresponding to the various fields; generating an editor corresponding to the game template data based on the view file and the model file, so that the game template data is processed according to the user's operations on the editor page.
[0104] On the other hand, the game template data processing method provided by the embodiment of the present disclosure may include: generating a data processing request based on the user's operation on the editor page of the game template data; using the model file of the editor to determine the business processing rules corresponding to the data processing request; and processing the fields and data carried by the data processing request according to the business processing rules.
[0105] It should be understood that when the computer program instructions are executed by the processor, they can also enable the processor to execute other optional implementation schemes provided by the method embodiment of the present disclosure.
[0106] Computer readable storage media can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0107] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0108] The above are only specific embodiments of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to these embodiments herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for generating an editor for processing game template data, characterized in that: include: Obtaining a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data; Generate a model file for the game template data according to the business processing rules of the game template data and a preset model template file; A view file is generated for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines a page layout corresponding to each field and a page operation response function corresponding to each field, and the preset view template file also defines a global control corresponding to the game template data and a response function corresponding to each global control; the preset view template file also defines a control addition event corresponding to the preset field and a response function corresponding to each control to be added; the page layout defined in the preset view template file is a page layout of different fields determined based on field classification, and the field classification is determined according to the attributes of different game elements, the configuration file includes a data format corresponding to each field, so that the user inputs data that conforms to the data format on the editor page, and the preset view template file includes a generation logic of data input prompt information corresponding to the data format, so that the data input prompt information is displayed on the editor page; An editor corresponding to the game template data is generated based on the view file and the model file, so that the game template data is processed according to the user's operation on the editor page.
2. The method according to claim 1, characterized in that The game template data is used to describe the attributes of game elements.
3. The method according to claim 1, characterized in that The processing logic defined in the preset model template file includes at least one of the following: Data filtering, data saving, data deletion and data import.
4. The method according to claim 1, characterized in that: The global control includes at least one of the following: a data creation control, a data copy control, a data deletion control, a data filter, a data save control, a data reset control, and a data import control.
5. The method according to claim 1, characterized in that The control adding event includes at least one of the following: a data saving control adding event, a data adding control adding event, a data deleting control adding event, a data modifying control adding event and a data position moving control adding event.
6. A method for processing game template data, characterized in that: Based on the editor implementation, the editor is obtained by using the editor generation method for processing game template data described in any one of claims 1 to 5, and the processing method includes: Generate a data processing request according to the user's operation on the editor page of the game template data; Determining a business processing rule corresponding to the data processing request using a model file of the editor; The fields and data carried in the data processing request are processed according to the business processing rules.
7. An editor generation device for processing game template data, characterized in that: include: A configuration file acquisition module, used to acquire a configuration file corresponding to the game template data; wherein the configuration file includes various fields included in the game template data; A model file generation module, used to generate a model file for the game template data according to the business processing rules of the game template data and a preset model template file; A view file generation module, used to generate a view file for the game template data according to the configuration file and the preset view template file; wherein the preset view template file defines a page layout corresponding to the various fields and a page operation response function corresponding to the various fields, and the preset view template file also defines a global control corresponding to the game template data and a response function corresponding to each global control; the preset view template file also defines a control addition event corresponding to the preset field and a response function corresponding to each control to be added; the page layout defined in the preset view template file is a page layout of different fields determined based on field classification, and the field classification is determined according to the attributes of different game elements, the configuration file includes a data format corresponding to each field, so that the user inputs data that conforms to the data format on the editor page, and the preset view template file includes a generation logic of data input prompt information corresponding to the data format, so that the data input prompt information is displayed on the editor page; The editor generation module is used to generate an editor corresponding to the game template data based on the view file and the model file, so that the game template data can be processed according to the user's operation on the editor page.
8. A game template data processing device, characterized in that: Based on the editor implementation, the editor is obtained by using the editor generation method for processing game template data described in any one of claims 1 to 5, and the processing device includes: A request generation module, used to generate a data processing request according to the user's operation on the editor page of the game template data; A processing rule determination module, used to determine a business processing rule corresponding to the data processing request using a model file of the editor; The request processing module is used to process the fields and data carried in the data processing request according to the business processing rules.
9. An electronic device, characterized in that: comprising a memory and a processor, wherein: A computer program is stored in the memory. When the computer program is executed by the processor, the electronic device implements the editor generation method for processing game template data described in any one of claims 1-5, or implements the game template data processing method described in claim 6.
10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a computing device, the computing device implements the editor generation method for processing game template data described in any one of claims 1-5, or implements the game template data processing method described in claim 6.
Citation Information
Patent Citations
Rapid development platform method based on module plant
CN105242928A
Game display data generation method and device
CN106682014A
Page editing method and device, page output method and device, computer equipment and medium
CN110083790A