Ejemplo n.º 1
0
        static void Postfix(SlotGroup sg, ListerHaulables __instance)
        {
            Map map = MapFieldInfo.GetValue(__instance) as Map;

            if (map == null)
            {
                throw new Exception($"Could not get map to change {sg.parent.SlotYielderLabel()} on...");
            }

            map.listerStackables().Update(sg);
        }
Ejemplo n.º 2
0
        static void Postfix(Thing t, ListerHaulables __instance)
        {
            Map map = MapFieldInfo.GetValue(__instance) as Map;

            if (map == null)
            {
                throw new Exception($"Could not get map to despawn {t.Label} from...");
            }

            map.listerStackables().TryRemove(t);
        }