summaryrefslogtreecommitdiff
path: root/src/TrainerMod/TrainerMod.cs
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <github@jplamondonw.com>2017-01-16 16:10:57 -0500
committerJesse Plamondon-Willard <github@jplamondonw.com>2017-01-16 16:10:57 -0500
commit6adf199987a506f8a65f6c1ddfad5aa9fa2a6a9f (patch)
treefaa9155fae99533110853567003325486f208937 /src/TrainerMod/TrainerMod.cs
parente8825947ca82c8f28ad9bc8a225fb4fb749814cb (diff)
parent1f3d3c8c93c7a427486b60cf649b86cef140e88b (diff)
downloadSMAPI-6adf199987a506f8a65f6c1ddfad5aa9fa2a6a9f.tar.gz
SMAPI-6adf199987a506f8a65f6c1ddfad5aa9fa2a6a9f.tar.bz2
SMAPI-6adf199987a506f8a65f6c1ddfad5aa9fa2a6a9f.zip
Merge branch 'develop' into stable
Diffstat (limited to 'src/TrainerMod/TrainerMod.cs')
-rw-r--r--src/TrainerMod/TrainerMod.cs20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/TrainerMod/TrainerMod.cs b/src/TrainerMod/TrainerMod.cs
index f0c7549f..c76bb78c 100644
--- a/src/TrainerMod/TrainerMod.cs
+++ b/src/TrainerMod/TrainerMod.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Diagnostics;
using System.Linq;
using Microsoft.Xna.Framework;
using StardewModdingAPI;
@@ -108,6 +109,9 @@ namespace TrainerMod
Command.RegisterCommand("world_setseason", "Sets the season to the specified value | world_setseason <value>", new[] { "(winter, spring, summer, fall)<value> The target season" }).CommandFired += this.HandleWorldSetSeason;
Command.RegisterCommand("world_downminelevel", "Goes down one mine level? | world_downminelevel", new[] { "" }).CommandFired += this.HandleWorldDownMineLevel;
Command.RegisterCommand("world_setminelevel", "Sets mine level? | world_setminelevel", new[] { "(Int32)<value> The target level" }).CommandFired += this.HandleWorldSetMineLevel;
+
+ Command.RegisterCommand("show_game_files", "Opens the game folder. | show_game_files").CommandFired += this.HandleShowGameFiles;
+ Command.RegisterCommand("show_data_files", "Opens the folder containing the save and log files. | show_data_files").CommandFired += this.HandleShowDataFiles;
}
/****
@@ -695,6 +699,22 @@ namespace TrainerMod
this.LogValueNotSpecified();
}
+ /// <summary>The event raised when the 'show_game_files' command is triggered.</summary>
+ /// <param name="sender">The event sender.</param>
+ /// <param name="e">The event arguments.</param>
+ private void HandleShowGameFiles(object sender, EventArgsCommand e)
+ {
+ Process.Start(Constants.ExecutionPath);
+ }
+
+ /// <summary>The event raised when the 'show_data_files' command is triggered.</summary>
+ /// <param name="sender">The event sender.</param>
+ /// <param name="e">The event arguments.</param>
+ private void HandleShowDataFiles(object sender, EventArgsCommand e)
+ {
+ Process.Start(Constants.DataPath);
+ }
+
/****
** Helpers
****/