Пример #1
0
        internal void LoadItems()
        {
            if (itemTypes.Count == 0)
            {
                Logger.Log("No items to load\n");
                return;
            }

            Logger.Log($"Loading {itemTypes.Count} item type(s)\n");

            foreach (Type itemType in itemTypes)
            {
                Logger.Log($"Loading item {itemType.FullName}");

                Item item = (Item)Activator.CreateInstance(itemType);
                item.ID = Lizard.GetID(itemType);

                Sprite sprite = LoadItemSprite(item);

                ModManager.AddModItem(item, sprite);
            }

            Logger.Log("");
        }
Пример #2
0
 private static void OnReloadMods(TitleScreen titleScreen)
 {
     // unloads mods before loading them
     ModManager.UnloadMods();
     GameController.LoadLevel("TitleScreen");
 }