示例#1
0
        public static string ASIPath(GameTarget target)
        {
            switch (target.Game)
            {
            case Mod.MEGame.ME1:
                return(ME1Directory.ASIPath(target));

            case Mod.MEGame.ME2:
                return(ME2Directory.ASIPath(target));

            case Mod.MEGame.ME3:
                return(ME3Directory.ASIPath(target));

            default:
                throw new ArgumentOutOfRangeException(nameof(target.Game), target.Game, null);
            }
        }
示例#2
0
        public static string CookedPath(Mod.MEGame game, string forcedPath = null)
        {
            switch (game)
            {
            case Mod.MEGame.ME1:
                return(forcedPath != null?ME1Directory.CookedPath(forcedPath) : ME1Directory.cookedPath);

            case Mod.MEGame.ME2:
                return(forcedPath != null?ME2Directory.CookedPath(forcedPath) : ME2Directory.cookedPath);

            case Mod.MEGame.ME3:
                return(forcedPath != null?ME3Directory.CookedPath(forcedPath) : ME3Directory.cookedPath);

            default:
                throw new ArgumentOutOfRangeException(nameof(game), game, null);
            }
        }
示例#3
0
        /// <summary>
        /// Gets path to executable for the specified Game Target
        /// </summary>
        /// <param name="game"></param>
        /// <returns></returns>
        public static string ExecutablePath(GameTarget game)
        {
            switch (game.Game)
            {
            case Mod.MEGame.ME1:
                return(ME1Directory.ExecutablePath(game.TargetPath));

            case Mod.MEGame.ME2:
                return(ME2Directory.ExecutablePath(game.TargetPath));

            case Mod.MEGame.ME3:
                return(ME3Directory.ExecutablePath(game.TargetPath));

            default:
                throw new ArgumentOutOfRangeException(nameof(game), game, null);
            }
        }
示例#4
0
 /// <summary>
 /// Refreshes the registry active paths for all three games
 /// </summary>
 public static void ReloadGamePaths()
 {
     ME1Directory.ReloadActivePath();
     ME2Directory.ReloadActivePath();
     ME3Directory.ReloadActivePath();
 }