Configuration Method and Device for Game Skills, Storage Medium, Computer Device
By receiving target skill data and configuring attribute formula templates, skill codes are automatically generated, which solves the problem of low efficiency in game characters or card skills development in the existing technology, and achieves efficient skill configuration and code generation.
Patent Information
- Application Number
- CN202111603018.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-24
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2041-12-24
AI Technical Summary
In the prior art, the development of game characters or card skills requires manual code writing, resulting in large workload, low efficiency and error-prone.
By receiving the target skill data, obtaining the attribute formula template and configuring it into the corresponding template, and finally converting it into skill code according to the preset code format, and automatically generating skill code using the skill editor and code generation tool.
Reduces repetitive labor for manual compilation, saves game development costs, improves development efficiency, and reduces the occurrence of compilation errors.
Smart Images

Figure CN114272610B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of electronic games, and particularly to a method and device for configuring game skills, a storage medium, and a computer device. Background Art
[0002] In games, many skills of characters / cards are often similar. For example, the skill effects of S-level character skills and A-level character skills are of the same nature, and the difference lies in the specific numerical values. S-level characters can cause more damage or provide more healing. Another example is that both Card 1 and Card 2 can have a sealing effect on enemies, and the difference lies in the sealing duration.
[0003] In the prior art, for different skills of different characters or different cards, even if the skill / card effects are similar, corresponding codes need to be manually written separately, which results in a large workload for developers, low game development efficiency, and is prone to errors. Summary of the Invention
[0004] In view of this, this application provides a method and device for configuring game skills, a storage medium, and a computer device, which helps to improve the efficiency and accuracy of skill configuration.
[0005] According to one aspect of this application, a method for configuring game skills is provided, including:
[0006] Receiving target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute;
[0007] Obtaining an attribute formula template corresponding to each target skill attribute, and respectively configuring each attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each target skill attribute;
[0008] Converting the skill attribute formula into a skill code of the target skill according to a preset code format.
[0009] Optionally, the receiving the target skill data to be configured specifically includes:
[0010] Displaying a skill editing interface in a skill editor, where the skill editing interface includes multiple attribute data configuration windows for editable skill attributes, and the editable skill attributes include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill execution times, and skill effective rounds;
[0011] Receiving skill editing data input in the attribute data configuration window;
[0012] Based on the confirmation operation of the skill editing data, the skill editor determines the target skill data to be configured according to the skill editing data.
[0013] Optionally, obtaining the attribute formula template corresponding to each target skill attribute, and respectively configuring each attribute configuration data into the corresponding attribute formula template to obtain the skill attribute formula of each target skill attribute specifically includes:
[0014] Through the skill editor, in the pre-configured attribute formula template library, obtain the attribute formula template corresponding to each target skill attribute, and respectively configure each attribute configuration data into the corresponding attribute formula template to obtain the skill attribute formula of each target skill attribute;
[0015] Correspondingly, converting the skill attribute formula into the skill code of the target skill according to the preset code format specifically includes:
[0016] Write the skill attribute formula into the code generation tool; through the code generation tool, convert the skill attribute formula into the skill code of the target skill according to the preset code format.
[0017] Optionally, before the skill editing interface is displayed in the skill editor, the method further includes:
[0018] Determine the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to each editable skill attribute;
[0019] According to the attribute identifier, editing rule, and attribute formula template of the editable skill attribute, configure the attribute data configuration window and the attribute formula template library of each editable skill attribute in the skill editor, so that the skill attribute formula is attached with the corresponding attribute identifier;
[0020] Configure the code generation tool according to the attribute identifier and attribute code template of the editable skill attribute.
[0021] Optionally, the method further includes:
[0022] Receive new skill attribute data, where the new skill attribute data includes the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to the new skill attribute;
[0023] According to the attribute identifier and editing rule of the new skill attribute, configure the attribute data configuration window of the new skill attribute in the skill editor, and configure the attribute formula template library according to the attribute formula template of the new skill attribute;
[0024] Configure the code generation tool according to the attribute identifier and attribute code template of the newly added skill attribute.
[0025] Optionally, after converting the skill attribute formula into the skill code of the target skill according to the preset code format, the method further includes:
[0026] Configure the skill index of the target skill;
[0027] Add the skill code of the target skill to the game skill set for the target skill to be executed by calling the skill code in the game skill set during game operation.
[0028] Optionally, the adding the skill code of the target skill to the game skill set specifically includes:
[0029] Generate the skill description information of the target skill according to the target skill data, and add the skill code and the skill description information of the target skill to the game skill set.
[0030] According to another aspect of the present application, there is provided a configuration device for game skills, including:
[0031] A data receiving module, configured to receive target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute;
[0032] A formula configuration module, configured to obtain the attribute formula template corresponding to each target skill attribute, and configure each attribute configuration data into the corresponding attribute formula template to obtain the skill attribute formula of each target skill attribute;
[0033] A code generation module, configured to convert the skill attribute formula into the skill code of the target skill according to the preset code format.
[0034] Optionally, the data receiving module is specifically configured to:
[0035] Display a skill editing interface in a skill editor, where the skill editing interface includes multiple attribute data configuration windows for editable skill attributes, and the editable skill attributes include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill execution times, and skill effective rounds;
[0036] Receive the skill editing data input in the attribute data configuration window;
[0037] Based on the confirmation operation of the skill editing data, the skill editor determines the target skill data to be configured according to the skill editing data.
[0038] Optionally, the formula configuration module is specifically configured to: through the skill editor, obtain the attribute formula template corresponding to each target skill attribute in the pre-configured attribute formula template library, and configure each attribute configuration data into the corresponding attribute formula template respectively to obtain the skill attribute formula of each target skill attribute;
[0039] Correspondingly, the code generation module is specifically configured to: write the skill attribute formula into the code generation tool; and convert the skill attribute formula into the skill code of the target skill by the code generation tool according to the preset code format.
[0040] Optionally, the device further includes:
[0041] The editing data determination module is used to determine the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to each editable skill attribute;
[0042] The skill editor configuration module is used to configure the attribute data configuration window and the attribute formula template library of each editable skill attribute in the skill editor according to the attribute identifier, editing rule, and attribute formula template of the editable skill attribute, so that the skill attribute formula is attached with the corresponding attribute identifier;
[0043] The code generation tool configuration module is used to configure the code generation tool according to the attribute identifier and attribute code template of the editable skill attribute.
[0044] Optionally, the editing data determination module is further used to: receive new skill attribute data, where the new skill attribute data includes the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to the new skill attribute;
[0045] The skill editor configuration module is further used to: configure the attribute data configuration window of the new skill attribute in the skill editor according to the attribute identifier and editing rule of the new skill attribute, and configure the attribute formula template library according to the attribute formula template of the new skill attribute;
[0046] The code generation tool configuration module is further used to: configure the code generation tool according to the attribute identifier and attribute code template of the new skill attribute.
[0047] Optionally, the device further includes:
[0048] A skill set addition module, which is used to configure the skill index of the target skill after converting the skill attribute formula into the skill code of the target skill according to the preset code format; add the skill code of the target skill to the game skill set for executing the target skill by calling the skill code in the game skill set during the game operation.
[0049] Optionally, the skill set addition module is further used to: generate the skill description information of the target skill according to the target skill data, and add the skill code of the target skill and the skill description information to the game skill set.
[0050] According to another aspect of the present application, there is provided a storage medium on which a computer program is stored, and when the program is executed by a processor, the above-mentioned configuration method of game skills is implemented.
[0051] According to still another aspect of the present application, there is provided a computer device, including a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor. When the processor executes the program, the above-mentioned configuration method of game skills is implemented.
[0052] By means of the above technical solutions, a configuration method and device for game skills, a storage medium, and a computer device provided by the present application obtain the corresponding attribute formula template according to the target skill attributes corresponding to the target skills to be configured, and configure the attribute configuration data of the target skills into the corresponding attribute formula template to obtain the skill attribute formulas of each target skill attribute. Finally, according to the preset code format, the skill attribute formulas are encoded and compiled into the skill codes of the target skills. Compared with the method of manually compiling the skill codes of each skill in the prior art, the embodiments of the present application only need to prepare a small number of attribute formula templates. One attribute formula template can adapt to multiple skills of the same type. By configuring the attribute configuration data of the new skill in the formula template, the skill attribute formula of the new skill can be obtained, and then the formula is converted into a skill code according to the preset code format, reducing a large amount of repetitive labor of manual compilation, saving the game development cost, improving the game development efficiency, and helping to reduce compilation errors.
[0053] The above description is only an overview of the technical solutions of the present application. In order to be able to understand the technical means of the present application more clearly, it can be implemented according to the content of the specification. And in order to make the above and other purposes, features, and advantages of the present application more obvious and understandable, the specific embodiments of the present application are hereinafter specifically exemplified. Description of the Drawings
[0054] The accompanying drawings described herein are used to provide a further understanding of the present application and form a part of the present application. The schematic embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation of the present application. In the drawings:
[0055] Figure 1 A flowchart showing a method for configuring a game skill provided by an embodiment of the present application is shown;
[0056] Figure 2 A flowchart showing another method for configuring a game skill provided by an embodiment of the present application is shown;
[0057] Figure 3 A schematic diagram of an editing interface of a skill editor provided by an embodiment of the present application is shown;
[0058] Figure 4 A schematic diagram of the structure of a game skill configuration device provided by an embodiment of the present application is shown. Detailed Embodiments
[0059] The present application will be described in detail below with reference to the accompanying drawings and in conjunction with embodiments. It should be noted that, without conflict, the embodiments in the present application and the features in the embodiments can be combined with each other.
[0060] In this embodiment, a method for configuring a game skill is provided. As Figure 1 shown, the method includes:
[0061] Step 101: Receive target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute;
[0062] Step 102: Obtain an attribute formula template corresponding to each target skill attribute, and configure each attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each target skill attribute;
[0063] Step 103: Convert the skill attribute formula into a skill code of the target skill according to a preset code format.
[0064] Embodiments of the present application can be used to generate skill codes for game character skills and game card skills. After the skill codes are configured in the game, when the target skill of the game character is called or the game card is used, the target skill can be released in the game by calling the skill code. Specifically, it can be applied to various types of games, such as turn-based games.
[0065] In this embodiment, before code generation, it is necessary to first determine the attribute formula templates for each of the multiple skill attributes. Specifically, the attribute formula templates can be determined by direct editing, or by analyzing the skill formulas of existing skills. For example, the skill formulas of existing skills can be analyzed first, and the skill formulas of existing skills can be disassembled into different formula segments according to the skill attributes, with each attribute corresponding to a formula segment. For example, an existing skill can be disassembled as follows: effective rounds: the first four rounds after entering the battle; target range: two random targets; skill effects: effect 1, reduce the target's health by 1000 points, effect 2, reduce the target's healing effect by 50%. The corresponding formula segments can specifically implement the following functions: determine the first four rounds after entering the battle; select two random targets; reduce the target's health by 1000 points; reduce the target's healing effect by 50%. Further summarize the formula segment templates to implement: determine a certain number of rounds after entering the battle; select a certain number of random targets; reduce the target's health by a certain number of points; reduce the target's healing effect by a certain percentage. Then, by filling in the specific values into the template, the skill formula for implementing the specific function can be generated.
[0066] Furthermore, when new target skills need to be generated with code, the planners can set various target skill attributes of the target skills and the attribute configuration data for each target skill attribute according to their needs. Among them, the target skills can be game character skills, such as the professional skills of characters of different professions in the game, and the target skills can also be game card skills. The attribute configuration data is specifically the value or value range of a certain target skill attribute. For example, if the target skill attribute is to reduce the target's health, the attribute configuration data is the specific value of reducing the target's health, or the value range of the reduced health. In a specific application scenario, the target skill attributes can include several of the skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill effect sequences, skill execution times, and skill effective rounds. Generally speaking, the target skill attributes all include skill effects, and there can be multiple skill effects. The multiple skill effects can be unordered or ordered.
[0067] Next, according to the pre-determined formula template, obtain the attribute formula template that matches the target skill attribute, and then fill the attribute configuration data into the corresponding attribute formula template respectively to obtain the skill attribute formula for each target skill attribute. Finally, convert the skill attribute formula into a skill code according to the pre-agreed preset code format, and the code editing of the target skill can be realized. In the embodiment of the present application, the skill code can be generated through the freeMaker template engine. The skill code templates of different attribute formula templates are pre-configured in the engine, and the engine outputs the skill code based on the skill code template and the data to be changed. For the target skill with the same skill attribute as the existing skill, there is no need to re-edit the skill code for the new target skill. Use the attribute formula template of the existing skill for numerical filling to obtain the skill attribute formula of the new target skill. Only a small number of attribute formula templates are required, and the skill attribute formula of the new target skill can be obtained by simple configuration. One attribute formula template can adapt to multiple skills of the same type. Only the required values in the template need to be modified, so as to perform code conversion on the skill attribute formula of the target skill, automatically compile the code of the target skill, reduce a large amount of manual formula and code writing work, help improve the game development efficiency, and reduce compilation errors.
[0068] By applying the technical solution of this embodiment, according to the target skill attribute corresponding to the target skill to be configured, obtain the corresponding attribute formula template, and configure the attribute configuration data of the target skill into the corresponding attribute formula template to obtain the skill attribute formula of each target skill attribute. Finally, according to the preset code format, encode the skill attribute formula and compile it into the skill code of the target skill. Compared with the method of manually compiling the skill code of each skill in the prior art, only a small number of attribute formula templates need to be prepared. One attribute formula template can adapt to multiple skills of the same type. By configuring the attribute configuration data of the new skill in the formula template, the skill attribute formula of the new skill can be obtained, and then the formula is converted into a skill code according to the preset code format, reducing a large amount of repetitive labor of manual compilation, saving the game development cost, improving the game development efficiency, and helping to reduce compilation errors.
[0069] In the embodiment of the present application, the target skill data can be edited through a skill editor, and further, the formula compilation and code conversion can be performed on the target skill data edited in the skill editor through a code generation tool, and finally the skill code of the target skill can be obtained. Optionally, the configuration method for the skill editor and the code generation tool may include the following steps:
[0070] S1, determine the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to each editable skill attribute;
[0071] S2. According to the attribute identifier, editing rules, and attribute formula template of the editable skill attribute, configure the attribute data configuration window and the attribute formula template library for each editable skill attribute in the skill editor, so that the skill attribute formula is attached with the corresponding attribute identifier;
[0072] S3. According to the attribute identifier and attribute code template of the editable skill attribute, configure the code generation tool.
[0073] In the above embodiment, the attribute formula template and attribute code template of multiple editable skill attributes can be determined in advance by means of manual editing or analyzing the skill formulas and skill codes of existing skills, and the corresponding attribute identifiers and editing rules are set for the editable skill attributes. Among them, the editable skill attributes can specifically include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill effect sequences, skill execution times, and skill effective rounds. Taking the skill effect as an example, it can specifically include multiple types such as causing damage to the target, slowing down the target, reducing the target's physical defense, reducing the target's spell defense, and so on. The skill effect of the target skill can be one of them, or can include multiple ones. Multiple skill effects can occur simultaneously, or some or all of the effects can occur in a certain order. Taking the skill effective object as an example, it can specifically include randomly selecting several targets within a certain range nearby, taking all objects within a certain range as targets, and so on. Taking the skill execution times as an example, it can specifically include an infinite number of rounds, all of the several rounds after execution are effective, a specific round is effective, and so on. The editing rules are used to limit the fillable range of the skill configuration data that can be filled in the skill editor. For example, if the editable skill attribute is "reducing the target's physical defense" in the skill effect, the corresponding editing rule can be an integer or a percentage data between 0% and 100%.
[0074] Further, after determining the attribute identifier, editing rules, attribute formula template, and attribute code template of the editable skill attributes, the attribute identifier, editing rules, and attribute formula template can be configured into the skill editor so that in the editing interface of the skill editor, the editing rules of each editable skill attribute can be prompted to the user, or a prompt can be given when the data entered by the user does not conform to the corresponding editing rules, avoiding situations such as invalid filled data, resulting in editing failures, or unreasonable editing. Moreover, when the user is editing a skill, the skill attributes edited by the user can also be distinguished through the attribute identifier, so as to identify what attribute the user has edited through the identifier. To facilitate the code generation tool to identify the content edited by the user, the skill editing data entered by the user in the skill editor can be appended with the corresponding attribute identifier. Furthermore, the skill editor can determine the corresponding attribute code template through the attribute identifier and fill the attribute configuration data entered by the user for the target skill attribute into the template to obtain the skill attribute formula of the target skill attribute. Additionally, the attribute identifier and attribute code template of the editable skill attributes can be configured into the code generation tool so that the code generation tool can quickly identify which target skill attributes are included in the target skill through the attribute identifier, find the corresponding attribute code template, and convert the skill attribute formula of the target skill attribute into the corresponding code. Finally, the codes of each target skill attribute are combined according to the preset code format to obtain the skill code of the target skill. In a specific application scenario, the code generation tool FreeMaker can be used. After obtaining the skill attribute formula, based on the skill attribute code template and the skill attribute formula to be changed, the skill attribute code is output, and then the skill attribute codes corresponding to each target skill attribute are combined into the complete skill code of the target skill.
[0075] In an actual game, taking a turn-based game as an example, most skills are related to information such as the attributes of both combatants, the combat scenario, the number of turns, and the unit level. When designing editable skill attributes and formula templates, these can be pre-agreed and configured into the skill editor, as Figure 2 shown, which is a schematic diagram of the editing interface of a skill editor.
[0076] Through the above-mentioned skill editor and code generation tool, the design formulas for each attribute of the skill can be stored in the skill editor. One attribute formula template can be adapted to multiple skills of the same type. As long as the specific values in the formula are modified through the skill editor, the formula for the new skill can be generated. And by generating the configuration through the skill editor, the probability of user configuration errors can be reduced. Furthermore, by encoding the formula generated by the skill editor through the code generation tool, the number of manual modifications to the encoding module is reduced, which helps to improve the skill encoding efficiency.
[0077] The embodiments of the present application can separate skill design from coding. When there are changes in skill design requirements and new editable skill attributes appear, the skill editor and code generation tool can be updated and configured. The formula template in the skill editor can be modified, and then the corresponding skill code can be generated through the code generation tool. Optionally, it further includes:
[0078] S4. Receive new skill attribute data, where the new skill attribute data includes the attribute identifier, editing rule, attribute formula template, and attribute code template corresponding to the new skill attribute;
[0079] S5. According to the attribute identifier and editing rule of the new skill attribute, configure the attribute data configuration window of the new skill attribute in the skill editor, and configure the attribute formula template library according to the attribute formula template of the new skill attribute;
[0080] S6. Configure the code generation tool according to the attribute identifier and attribute code template of the new skill attribute.
[0081] In the above embodiment, when there is a new editable skill attribute, receive the new skill attribute data, and configure the skill editor and code generation tool in a similar manner to S1 - S3. Use the attribute identifier, editing rule, and attribute formula template of the new skill attribute to configure the skill editor to add the attribute data configuration window of the new skill attribute in the skill editing interface of the skill editor and add the new skill attribute to the attribute formula target library. And configure the attribute identifier and attribute code target of the new skill attribute into the code generation tool.
[0082] Further, as a refinement and extension of the specific implementation manner of the above embodiment, to fully illustrate the specific implementation process of this embodiment, another method for configuring game skills is provided, as Figure 3 shown. This method includes:
[0083] Step 201. Display a skill editing interface in the skill editor, where the skill editing interface includes attribute data configuration windows for multiple editable skill attributes, and the editable skill attributes include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill execution times, and skill effective rounds.
[0084] Step 202. Receive the skill editing data input in the attribute data configuration window.
[0085] Step 203. Based on the confirmation operation of the skill editing data, the skill editor determines the target skill data to be configured according to the skill editing data.
[0086] In the embodiments of the present application, a pre-configured skill editor can be used to provide a visual skill editing interface. The interface includes property data configuration windows corresponding to multiple pre-configured editable skill properties. Users can directly input or select skill editing data in different windows to achieve the editing of a target skill with multiple skill properties. For example, if the target skill to be configured includes two skill effects, reducing the target's health by 1000 points and reducing the target's spell defense by 10%, the user can input 1000 in the window corresponding to the skill effect of "reducing the target's health" and input 10% in the window corresponding to the skill effect of "reducing the target's spell defense". By simply inputting these two data, the editing of the skill effect can be achieved. Subsequently, the skill code can be automatically generated through the skill editor and the code generator, eliminating the need for cumbersome formula editing and code editing. After the user has completed the configuration of all target skill properties of the target skill, the user can click the "confirm" or "submit" button to confirm the input skill editing data. After user confirmation, the skill editor can generate target skill data based on the skill editing data input by the user in each window. The target skill data includes the property identifiers corresponding to the selected target skill properties of the user and the input property configuration data.
[0087] Step 204: Through the skill editor, in the pre-configured property formula template library, obtain the property formula template corresponding to each target skill property, and configure each property configuration data into the corresponding property formula template to obtain the skill property formula of each target skill property.
[0088] In the above embodiment, the skill editor obtains the property formula template of the target skill property in the pre-configured property formula template library according to the mapping relationship between the property identifier and the property formula template, and fills the target skill data into the corresponding property formula template to obtain the skill property formula.
[0089] In a specific application scenario, the skill property formula can be exported as an Excel table. By agreeing on the header format or the row and column coordinates in the table, the formula with specific properties can be written into the table, facilitating the code generation tool to identify the editable properties corresponding to the data in the table. After generating an Excel data through the skill editor, the remaining work is completed by the code automatic generation tool.
[0090] Step 205: Write the skill property formula into the code generation tool; through the code generation tool, convert the skill property formula into the skill code of the target skill according to the preset code format.
[0091] In this embodiment, the skill attribute formula is written into the code generation tool, and the formula is automatically converted into the corresponding skill code by the code generation tool. In practical applications, the code generation tool can be understood as a mapping that generates a skill code class file from the data in Excel through the code generation tool freeMaker.
[0092] Step 206: Configure the skill index of the target skill; add the skill code of the target skill to the game skill set so that the target skill can be executed by calling the skill code in the game skill set during the game operation.
[0093] In the embodiment of the present application, a corresponding skill index can also be configured for the target skill to quickly query the skill code corresponding to the target skill through the skill index. In an actual game, when the game server is started or hot updated, the skill code of the target skill can be loaded into the game skill set according to the index, so that when the target skill is called during the game operation, the skill code can be quickly read from the game skill set according to the skill index, and then the skill code can be run to release and use the target skill in the game.
[0094] In the embodiment of the present application, optionally, it further includes: generating skill description information of the target skill according to the target skill data, and adding the skill code of the target skill and the skill description information to the game skill set.
[0095] In the above embodiment, skill description information of the target skill can also be generated according to the target skill data, and the actual effect of the target skill in the game is described in the form of text. For example, the skill description information of a certain skill is "When entering the battle, XX intimidates the enemy, causes damage to 2 enemies and reduces their active attributes (attack, healing, sealing), lasting for 4 rounds". Then, the skill description information and the skill code of the target skill are both added to the game skill set.
[0096] Optionally, the game skill set can be updated to the game client in the following ways:
[0097] Way 1: When a player logs in to the game server or the game server is hot updated, the game client loads the game skill set. When the target skill is called during the game operation, the skill code and skill description information of the target skill are read from the game skill set, the skill code of the target skill is executed, and the skill effect of the target skill is displayed in the game according to the skill description information.
[0098] When a player logs in to the game server or the game server performs a hot update, the game skill set is loaded. When the player calls a target skill during the game, the skill code and skill description information of the target skill can be read from the game skill set through the skill index of the target skill, so as to execute the skill code to release the skill, and at the same time, display the skill effect of the target skill in the skill description information display area in the game according to the skill description information. For example, in the above skill description information, XX can be replaced with the game ID of the player character who calls the target skill, so that the player can more clearly understand the effect brought by the target skill and improve the game experience.
[0099] Method 2: The skill polling module of the game client polls the game skill set in the game server, and loads the game skill set when the polling result indicates that the game skill set has been updated.
[0100] The skill polling module in the game client can perform regular polling on the game skill set in the game server. The specific polling results include two types: 0 or 1. 0 indicates that the game skill set has not changed, and 1 indicates that the game skill set has changed. Among them, when the polling result is 1, the game client requests a new game skill set from the game server and loads the new game skill set to achieve the hot update of the game skill set on the client side.
[0101] Further, as Figure 1 a specific implementation of the method, an embodiment of the present application provides a configuration device for game skills, as Figure 4 shown. The device includes:
[0102] A data receiving module, configured to receive target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute;
[0103] A formula configuration module, configured to obtain an attribute formula template corresponding to each target skill attribute, and configure each attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each target skill attribute;
[0104] A code generation module, configured to convert the skill attribute formula into a skill code of the target skill according to a preset code format.
[0105] Optionally, the data receiving module is specifically configured to:
[0106] Display a skill editing interface in the skill editor, where the skill editing interface includes multiple property data configuration windows for editable skill properties, and the editable skill properties include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill execution times, and skill effective rounds;
[0107] Receive the skill editing data input in the property data configuration window;
[0108] Based on the confirmation operation of the skill editing data, the skill editor determines the target skill data to be configured according to the skill editing data.
[0109] Optionally, the formula configuration module is specifically used for: through the skill editor, obtain the property formula template corresponding to each target skill property in the pre-configured property formula template library, and configure each property configuration data into the corresponding property formula template respectively to obtain the skill property formula of each target skill property;
[0110] Correspondingly, the code generation module is specifically used for: write the skill property formula into the code generation tool; through the code generation tool, convert the skill property formula into the skill code of the target skill according to the preset code format.
[0111] Optionally, the device further includes:
[0112] An editing data determination module, which is used to determine the property identifier, editing rule, property formula template, and property code template corresponding to each editable skill property;
[0113] A skill editor configuration module, which is used to configure the property data configuration window and the property formula template library of each editable skill property in the skill editor according to the property identifier, editing rule, and property formula template of the editable skill property, so that the skill property formula is attached with the corresponding property identifier;
[0114] A code generation tool configuration module, which is used to configure the code generation tool according to the property identifier and property code template of the editable skill property.
[0115] Optionally, the editing data determination module is further used for: receiving new skill property data, where the new skill property data includes the property identifier, editing rule, property formula template, and property code template corresponding to the new skill property;
[0116] The skill editor configuration module is further configured to: configure an attribute data configuration window for the newly added skill attribute in the skill editor according to the attribute identifier and editing rule of the newly added skill attribute, and configure the attribute formula template library according to the attribute formula template of the newly added skill attribute;
[0117] The code generation tool configuration module is further configured to: configure the code generation tool according to the attribute identifier of the newly added skill attribute and the attribute code template.
[0118] Optionally, the apparatus further includes:
[0119] A skill set addition module, configured to convert the skill attribute formula into a skill code of a target skill according to a preset code format, and then configure a skill index of the target skill; add the skill code of the target skill to a game skill set for the target skill to be executed by calling the skill code in the game skill set during game operation.
[0120] Optionally, the skill set addition module is further configured to: generate skill description information of the target skill according to the target skill data, and add the skill code of the target skill and the skill description information to the game skill set.
[0121] It should be noted that other corresponding descriptions of each functional unit involved in the game skill configuration device provided in the embodiments of the present application can be referred to Figures 1 to 3 the corresponding description in the method, which will not be elaborated here.
[0122] Based on the above method as Figures 1 to 3 shown, correspondingly, the embodiments of the present application further provide a storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the game skill configuration method as Figures 1 to 3 shown is implemented.
[0123] Based on such an understanding, the technical solution of the present application can be embodied in the form of a software product, and the software product can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.), including several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in various implementation scenarios of the present application.
[0124] Based on the above method as Figures 1 to 3 shown, and Figure 4The virtual device embodiment shown. To achieve the above object, an embodiment of the present application further provides a computer device, which may specifically be a personal computer, a server, a network device, etc. The computer device includes a storage medium and a processor; the storage medium is used to store a computer program; the processor is used to execute the computer program to implement the above-mentioned as Figures 1 to 3 the configuration method of the game skills shown.
[0125] Optionally, the computer device may further include a user interface, a network interface, a camera, a Radio Frequency (RF) circuit, sensors, an audio circuit, a WI-FI module, etc. The user interface may include a display screen (Display), an input unit such as a keyboard (Keyboard), etc. Optionally, the user interface may further include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (such as a Bluetooth interface, a WI-FI interface), etc.
[0126] Those skilled in the art can understand that the structure of a computer device provided in this embodiment does not constitute a limitation on the computer device, and it may include more or fewer components, or combine some components, or have different component arrangements.
[0127] The storage medium may further include an operating system and a network communication module. The operating system is a program for managing and saving the hardware and software resources of the computer device, and supports the operation of information processing programs and other software and / or programs. The network communication module is used to implement the communication between the components inside the storage medium, as well as the communication between the storage medium and other hardware and software in the entity device.
[0128] Through the description of the above embodiments, those skilled in the art can clearly understand that the present application can be implemented by means of software plus a necessary general hardware platform, or can be implemented by hardware. According to the target skill attributes corresponding to the target skills to be configured, obtain the corresponding attribute formula template, and configure the attribute configuration data of the target skills into the corresponding attribute formula template to obtain the skill attribute formulas of each target skill. Finally, encode the skill attribute formulas in a preset code format and compile them into the skill codes of the target skills. Compared with the method of manually compiling the skill codes of each skill in the prior art, the present application embodiment only needs to prepare a small number of attribute formula templates. One attribute formula template can be adapted to multiple repeated type skills. By configuring the attribute configuration data of the new skill in the formula template, the skill attribute formula of the new skill can be obtained, and then the formula can be converted into a skill code according to the preset code format, reducing a large amount of repetitive labor of manual compilation, saving the game development cost, improving the game development efficiency, and helping to reduce compilation errors.
[0129] Those skilled in the art can understand that the attached drawings are only schematic diagrams of a preferred implementation scenario, and the modules or processes in the attached drawings are not necessarily essential for implementing the present application. Those skilled in the art can understand that the modules in the devices in the implementation scenario can be distributed in the devices in the implementation scenario according to the description of the implementation scenario, or can be correspondingly changed and located in one or more devices different from this implementation scenario. The modules in the above implementation scenario can be combined into one module, or can be further split into multiple sub-modules.
[0130] The above serial numbers of the present application are only for description and do not represent the advantages or disadvantages of the implementation scenario. The above disclosure is only several specific implementation scenarios of the present application. However, the present application is not limited thereto, and any changes that can be conceived by those skilled in the art should fall within the protection scope of the present application.
Claims
1. A configuration method for game skills, characterized in that, Including: Receiving target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute; Obtaining an attribute formula template corresponding to each of the target skill attributes, and respectively configuring each of the attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each of the target skill attributes, including: through a skill editor, obtaining an attribute formula template corresponding to each of the target skill attributes in a pre-configured attribute formula template library, and respectively configuring each of the attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each of the target skill attributes; Converting the skill attribute formula into a skill code of the target skill according to a preset code format, including: writing the skill attribute formula into a code generation tool; and converting the skill attribute formula into the skill code of the target skill by the code generation tool according to the preset code format.
2. The method according to claim 1, characterized in that, The receiving of the target skill data to be configured specifically includes: Displaying a skill editing interface in the skill editor, where the skill editing interface includes a plurality of attribute data configuration windows for editable skill attributes, and the editable skill attributes include skill execution conditions, skill usage scenarios, skill effective ranges, skill effective objects, skill effects, skill effect sequences, skill execution times, and skill effective rounds; Receiving skill editing data input in the attribute data configuration window; Based on a confirmation operation on the skill editing data, the skill editor determines the target skill data to be configured according to the skill editing data.
3. The method according to claim 2, wherein Before the skill editing interface is displayed in the skill editor, the method further includes: Determining an attribute identifier, an editing rule, an attribute formula template, and an attribute code template corresponding to each of the editable skill attributes; Configuring the attribute data configuration window and the attribute formula template library for each of the editable skill attributes in the skill editor according to the attribute identifier, the editing rule, and the attribute formula template of the editable skill attribute, so that the skill attribute formula is attached with the corresponding attribute identifier; Configuring the code generation tool according to the attribute identifier and the attribute code template of the editable skill attribute.
4. The method according to claim 3, wherein The method further includes: Receiving new skill attribute data, where the new skill attribute data includes an attribute identifier, an editing rule, an attribute formula template, and an attribute code template corresponding to the new skill attribute; Configuring an attribute data configuration window for the new skill attribute in the skill editor according to the attribute identifier and the editing rule of the new skill attribute, and configuring the attribute formula template library according to the attribute formula template of the new skill attribute; Configuring the code generation tool according to the attribute identifier and the attribute code template of the new skill attribute.
5. The method according to any one of claims 1 to 4, characterized in that After converting the skill attribute formula into a skill code of the target skill according to the preset code format, the method further includes: Configuring a skill index of the target skill; Add the skill code of the target skill to the game skill set so that the target skill can be executed by calling the skill code in the game skill set during game operation.
6. The method according to claim 5, wherein The adding the skill code of the target skill to the game skill set specifically includes: Generate the skill description information of the target skill according to the target skill data, and add the skill code of the target skill and the skill description information to the game skill set.
7. A configuration device for game skills, characterized in that It includes: A data receiving module, configured to receive target skill data to be configured, where the target skill is a game character skill or a game card skill, and the target skill data includes attribute configuration data of at least one target skill attribute; A formula configuration module, configured to obtain an attribute formula template corresponding to each target skill attribute, and respectively configure each attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each target skill attribute, including: through a skill editor, in a pre-configured attribute formula template library, obtain an attribute formula template corresponding to each target skill attribute, and respectively configure each attribute configuration data into the corresponding attribute formula template to obtain a skill attribute formula for each target skill attribute; A code generation module, configured to convert the skill attribute formula into the skill code of the target skill according to a preset code format, including: writing the skill attribute formula into a code generation tool; through the code generation tool, converting the skill attribute formula into the skill code of the target skill according to the preset code format.
8. A storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
9. A computer device, comprising a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, characterized in that, When the processor executes the computer program, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Code generation method and device, storage medium and electronic equipment
CN110580158A