예제 #1
0
 private static void Prefix(ref ModuleItemHolderBeam __instance)
 {
     if (ItemHolderQuads.ContainsKey(__instance))
     {
         m_BeamQuadPrefab.SetValue(__instance, ItemHolderQuads[__instance]);
         ItemHolderQuads.Remove(__instance);
     }
 }
예제 #2
0
                    private static void Prefix(ref ModuleItemHolderBeam __instance)
                    {
                        var prefab = (GameObject)m_BeamQuadPrefab.GetValue(__instance);

                        if (!ItemHolderQuads.ContainsKey(__instance))
                        {
                            ItemHolderQuads.Add(__instance, prefab);
                        }

                        if (displayHolderBeamsBool)
                        {
                            if (ItemHolderQuads[__instance] != prefab)
                            {
                                m_BeamQuadPrefab.SetValue(__instance, ItemHolderQuads[__instance]);
                            }
                        }
                        else if (prefab != null)
                        {
                            m_BeamQuadPrefab.SetValue(__instance, null);
                        }
                    }