/// <summary> /// Load Plugin Images /// </summary> public static void LoadPluginImages() { foreach (var plugin in GameData.GameConfiguration.Plugins.Plugins) { string _PluginImageDirectory = GameData.PluginDirectory + plugin.SourceName + "\\Images\\"; var _AllImageFiles = Helper.IO.GetDirectoryFiles(_PluginImageDirectory, Helper.IO.FileTypes.Bmp | Helper.IO.FileTypes.Jpg | Helper.IO.FileTypes.Png); int _count = _AllImageFiles.Count(); foreach (var img in _AllImageFiles) { AddImage(plugin.Name, img.GetFileNameFromFullPath(false), img, true); OnProcessingUpdate?.Invoke(1, _count); } } }
/// <summary> /// Load all the Game Specific Images /// </summary> public static void LoadGameImages() { foreach (var game in GameData.GameConfiguration.Games.Games) { string _TmpDirectory = GameData.GamesDirectory + game.SourceName + "\\Images\\"; var _AllImageFiles = Helper.IO.GetDirectoryFiles(_TmpDirectory, Helper.IO.FileTypes.Png | Helper.IO.FileTypes.Jpg | Helper.IO.FileTypes.Bmp); int _count = _AllImageFiles.Count(); foreach (var img in _AllImageFiles) { AddImage(game.SourceName, img.GetFileNameFromFullPath(false), img, true); OnProcessingUpdate?.Invoke(1, _count); } } }