示例#1
0
 public static void Node_SetRects_Prefix(object __instance)
 {
     if (nodeSizeHacked)
     {
         NodeSizeInfo.SetValue(__instance, oldNodeSize);
     }
 }
示例#2
0
 public static void TreeRect_Prefix(object __instance)
 {
     if (!nodeSizeHacked)
     {
         oldNodeSize = (Vector2)NodeSizeInfo.GetValue(__instance);
         newNodeSize = oldNodeSize + push;
         NodeSizeInfo.SetValue(__instance, newNodeSize);
         nodeSizeHacked = true;
     }
 }
示例#3
0
 public static void Node_SetRects_Postfix(object __instance)
 {
     if (nodeSizeHacked)
     {
         NodeSizeInfo.SetValue(__instance, newNodeSize);
         Vector2 rightedge = (Vector2)_rightInfo.GetValue(__instance);
         rightedge += push;
         _rightInfo.SetValue(__instance, rightedge);
     }
 }
示例#4
0
 public static void Close_Postfix(object __instance)
 {
     if (__instance.GetType() == MainTabType())
     {
         Extension_Research.currentPawnsCache?.Clear();
     }
     if (nodeSizeHacked)
     {
         NodeSizeInfo.SetValue(__instance, oldNodeSize);
         nodeSizeHacked = false;
     }
     MainTabInstance = null;
 }