Skip to content

Commit fff8263

Browse files
authored
Fix a bug where resources were not being assigned the correct destination (#88)
1 parent 3fede2f commit fff8263

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

source/source/content/mob_type/resource_type.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ void ResourceType::loadCatProperties(DataNode* file) {
7373
carryingDestinationStr,
7474
(int*) &carryingDestination, {
7575
"ship",
76+
"",
77+
"",
7678
"linked_mob",
7779
"linked_mob_matching_type"
7880
},

source/source/core/misc_functions.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1197,6 +1197,8 @@ bool readEnumProp(
11971197
const string& valueStr, int* outInt, const vector<string> possibleValues,
11981198
const string& errorThing, DataNode* errorNode
11991199
) {
1200+
if(valueStr.empty()) return false;
1201+
12001202
for(size_t v = 0; v < possibleValues.size(); v++) {
12011203
if(valueStr == possibleValues[v]) {
12021204
*outInt = (int) v;

0 commit comments

Comments
 (0)