Various Fixes

Newly created drones now register their origin colony correctly
Hauling behavior fixed for multiple items
Buttons can't be dragged unless explicitly enabled
Inspecting a colony with lots of compound commodities no longer sets your computer on fire
This commit is contained in:
hyperion51 2020-07-03 01:33:42 +01:00
commit 1e2b474fc1
11 changed files with 133 additions and 47 deletions

View file

@ -344,6 +344,7 @@ public class TechTreeMsagl : MonoBehaviour
var ingredientData = Context.Cache.Get<ItemData>(ingredient.Key);
ingredientsList.AddProperty(ingredientData.Name, () => ingredient.Value.ToString());
}
ingredientsList.SetExpanded(true, true);
var dependenciesList = PropertiesPanel.AddList("Dependencies");
foreach (var dependency in blueprint.Dependencies)
@ -351,12 +352,14 @@ public class TechTreeMsagl : MonoBehaviour
var dependencyBlueprint = Context.Cache.Get<BlueprintData>(dependency);
dependenciesList.AddProperty(dependencyBlueprint.Name);
}
dependenciesList.SetExpanded(true, true);
var descendantsList = PropertiesPanel.AddList("Descendants");
foreach (var descendant in Blueprints.Where(bp => bp.Dependencies.Any(dep => blueprint.ID == dep)))
{
descendantsList.AddProperty(descendant.Name);
}
descendantsList.SetExpanded(true, true);
};
_techInstances.Add(tech.GetComponent<Prototype>());
}