diff --git a/src/tool/csv2yaml.cpp b/src/tool/csv2yaml.cpp index 5ab7829a04..56d2b93493 100644 --- a/src/tool/csv2yaml.cpp +++ b/src/tool/csv2yaml.cpp @@ -970,6 +970,7 @@ static bool mob_readdb_mobavail(char* str[], int columns, int current) { return false; } + body << YAML::BeginMap; body << YAML::Key << "Mob" << YAML::Value << *mob_name; uint16 sprite_id = atoi(str[1]); @@ -982,15 +983,15 @@ static bool mob_readdb_mobavail(char* str[], int columns, int current) { sprite = const_cast(constant_lookup(sprite_id, "JT_")); if (sprite == nullptr) { - ShowError("Sprite name %s is not known.\n", sprite); + ShowError("Sprite name for id %d is not known.\n", sprite_id); return false; } sprite += 3; // Strip JT_ here because the script engine doesn't send this prefix for NPC. - body << YAML::Key << "Sprite" << YAML::Value << *sprite; + body << YAML::Key << "Sprite" << YAML::Value << sprite; } else - body << YAML::Key << "Sprite" << YAML::Value << *sprite; + body << YAML::Key << "Sprite" << YAML::Value << sprite; } else body << YAML::Key << "Sprite" << YAML::Value << *sprite_name;