Пример #1
0
        //Init the API Hooks
        internal static void APIAwake()
        {
            //set up the hookable object

            fetch = HaystackResourceLoader.fetch;

            //set up any events we need from the core code

            //flag it ready
            APIReady = true;
        }
Пример #2
0
        private void APIDestroy()
        {
            //tear it down
            fetch = null;

            //Tear down any events we need to remove
            //try {

            //} catch (Exception) { }

            APIReady = false;
        }
Пример #3
0
        /// <summary>
        /// Awake Event - when the DLL is loaded
        /// </summary>
        public void Awake()
        {
            fetch = this;
            API.APIAwake();
            DontDestroyOnLoad(this);

            Resources.LoadTextures();

            Resources.PopulateVesselTypes(ref Resources.vesselTypesList);
            Resources.vesselTypesList.Sort(new HSUtils.SortByWeight());

            this.Settings = new Settings();
        }
Пример #4
0
 public void OnDestroy()
 {
     toolbarControl.OnDestroy();
     Destroy(toolbarControl);
     fetch = null;
 }