summaryrefslogtreecommitdiff
path: root/src/map/skill.h
diff options
context:
space:
mode:
authorSmokexyz <sagunxp@gmail.com>2016-04-23 01:21:26 +0800
committerSmokexyz <sagunxp@gmail.com>2016-07-09 21:36:45 +0800
commitd2a04ea3158792e2fa30b69a903ea6cf2d349289 (patch)
treec54f32bbd7ff3550bc2b47cc8ab0abe60c4c7ac5 /src/map/skill.h
parente35bdc6974663ad11317892ba757dcb35b34be6d (diff)
downloadhercules-d2a04ea3158792e2fa30b69a903ea6cf2d349289.tar.gz
hercules-d2a04ea3158792e2fa30b69a903ea6cf2d349289.tar.bz2
hercules-d2a04ea3158792e2fa30b69a903ea6cf2d349289.tar.xz
hercules-d2a04ea3158792e2fa30b69a903ea6cf2d349289.zip
SkillDB TXT to Libconfig + converter
The conversion of 5 skill database files - skill_require_db.txt skill_unit_db.txt skill_cast_db.txt skill_castnodex_db.txt and skill_db.txt to Libconfig file skill_db.conf a PHP CLI converter is included to read from the above mentioned files and create a skill_db.conf in the same directory.
Diffstat (limited to 'src/map/skill.h')
-rw-r--r--src/map/skill.h25
1 files changed, 19 insertions, 6 deletions
diff --git a/src/map/skill.h b/src/map/skill.h
index 35fddafa4..9bb3eae13 100644
--- a/src/map/skill.h
+++ b/src/map/skill.h
@@ -58,7 +58,7 @@ struct status_change_entry;
#define MAX_SKILLUNITGROUP 25
#define MAX_SKILL_ITEM_REQUIRE 10
#define MAX_SKILLUNITGROUPTICKSET 25
-#define MAX_SKILL_NAME_LENGTH 30
+#define MAX_SKILL_NAME_LENGTH 32
// (Epoque:) To-do: replace this macro with some sort of skill tree check (rather than hard-coded skill names)
#define skill_ischangesex(id) ( \
@@ -2033,11 +2033,24 @@ struct skill_interface {
int (*unit_timer) (int tid, int64 tick, int id, intptr_t data);
int (*unit_timer_sub) (union DBKey key, struct DBData *data, va_list ap);
void (*init_unit_layout) (void);
- bool (*parse_row_skilldb) (char* split[], int columns, int current);
- bool (*parse_row_requiredb) (char* split[], int columns, int current);
- bool (*parse_row_castdb) (char* split[], int columns, int current);
- bool (*parse_row_castnodexdb) (char* split[], int columns, int current);
- bool (*parse_row_unitdb) (char* split[], int columns, int current);
+ void (*validate_hittype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_skilltype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_attacktype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_element) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_skillinfo) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_damagetype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_castnodex) (struct config_setting_t *conf, struct s_skill_db *skill, bool delay);
+ void (*validate_weapontype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_ammotype) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_state) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_item_requirements) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_unit_target) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_unit_flag) (struct config_setting_t *conf, struct s_skill_db *skill);
+ void (*validate_additional_fields) (struct config_setting_t *conf, struct s_skill_db *skill);
+ bool (*validate_skilldb) (struct s_skill_db *skt, const char *source);
+ bool (*read_skilldb) (const char *filename);
+ void (*config_set_level) (struct config_setting_t *conf, int *arr);
+ void (*level_set_value) (int *arr, int value);
bool (*parse_row_producedb) (char* split[], int columns, int current);
bool (*parse_row_createarrowdb) (char* split[], int columns, int current);
bool (*parse_row_abradb) (char* split[], int columns, int current);