Fix incorrectly saving and loading item and terrain abilities

(as well as a few other enumerated types)
This commit is contained in:
2015-06-27 16:14:58 -04:00
parent cfd46f8924
commit ef9fc69bb4

View File

@@ -46,9 +46,11 @@ class cEnumLookup {
public:
cEnumLookup(const std::initializer_list<const char*> strings) : root(0) {
size_t i = 0;
for(std::string str : strings)
for(std::string str : strings) {
if(!str.empty())
insert(str, i++);
insert(str, i);
i++;
}
}
void insert(const std::string& str, unsigned long val) {
size_t i = 0;