From 896a8272c9dd08dc55919299b2ef85fa41e77491 Mon Sep 17 00:00:00 2001 From: Zack Piispanen Date: Fri, 1 Jun 2012 13:12:56 -0400 Subject: [PATCH] Removed old rememberleavepos variable and added docs. --- TShockAPI/FileTools.cs | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/TShockAPI/FileTools.cs b/TShockAPI/FileTools.cs index b353bf9a..59072016 100644 --- a/TShockAPI/FileTools.cs +++ b/TShockAPI/FileTools.cs @@ -22,36 +22,52 @@ namespace TShockAPI { public class FileTools { + /// + /// Path to the file containing the rules. + /// internal static string RulesPath { get { return Path.Combine(TShock.SavePath, "rules.txt"); } } + /// + /// Path to the file containing the message of the day. + /// internal static string MotdPath { get { return Path.Combine(TShock.SavePath, "motd.txt"); } } + /// + /// Path to the file containing the whitelist. + /// internal static string WhitelistPath { get { return Path.Combine(TShock.SavePath, "whitelist.txt"); } } - internal static string RememberedPosPath - { - get { return Path.Combine(TShock.SavePath, "oldpos.xml"); } - } - + /// + /// Path to the file containing the config. + /// internal static string ConfigPath { get { return Path.Combine(TShock.SavePath, "config.json"); } } + /// + /// Creates an empty file at the given path. + /// + /// The path to the file. public static void CreateFile(string file) { File.Create(file).Close(); } + /// + /// Creates a file if the files doesn't already exist. + /// + /// The path to the files + /// The data to write to the file. public static void CreateIfNot(string file, string data = "") { if (!File.Exists(file))