Fixed variable cast times

Thanks to @mazvi again.
This commit is contained in:
Lemongrass3110
2020-02-02 17:58:44 +01:00
parent 5cf7aceb2a
commit 0105116338
2 changed files with 353 additions and 2 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -1939,14 +1939,14 @@ static bool skill_parse_row_skilldb(char* split[], int columns, int current) {
#ifdef RENEWAL_CAST #ifdef RENEWAL_CAST
if (!isMultiLevel(it_cast->second.fixed_cast)) { if (!isMultiLevel(it_cast->second.fixed_cast)) {
if (it_cast->second.fixed_cast[0] > 0) if (it_cast->second.fixed_cast[0] != 0)
body << YAML::Key << "FixedCastTime" << YAML::Value << it_cast->second.fixed_cast[0]; body << YAML::Key << "FixedCastTime" << YAML::Value << it_cast->second.fixed_cast[0];
} else { } else {
body << YAML::Key << "FixedCastTime"; body << YAML::Key << "FixedCastTime";
body << YAML::BeginSeq; body << YAML::BeginSeq;
for (size_t i = 0; i < ARRAYLENGTH(it_cast->second.fixed_cast); i++) { for (size_t i = 0; i < ARRAYLENGTH(it_cast->second.fixed_cast); i++) {
if (it_cast->second.fixed_cast[i] > 0) { if (it_cast->second.fixed_cast[i] != 0) {
body << YAML::BeginMap; body << YAML::BeginMap;
body << YAML::Key << "Level" << YAML::Value << i + 1; body << YAML::Key << "Level" << YAML::Value << i + 1;
body << YAML::Key << "Time" << YAML::Value << it_cast->second.fixed_cast[i]; body << YAML::Key << "Time" << YAML::Value << it_cast->second.fixed_cast[i];