Adds option to remember leave positions. Change to true in config.json
This commit is contained in:
parent
f790d9378c
commit
df1cbab1f5
6 changed files with 162 additions and 3 deletions
|
|
@ -54,6 +54,7 @@ namespace TShockAPI
|
|||
public static bool DisableBuild = false;
|
||||
public static float[] AdminChatRGB = {255, 0, 0};
|
||||
public static string AdminChatPrefix = "(Admin) ";
|
||||
public static bool RememberLeavePos = false;
|
||||
|
||||
/// <summary>
|
||||
/// Don't allow pvp changing for x seconds.
|
||||
|
|
@ -112,6 +113,7 @@ namespace TShockAPI
|
|||
ListServer = cfg.ListServer;
|
||||
Main.spawnTileX = cfg.spawnTileX;
|
||||
Main.spawnTileY = cfg.spawnTileY;
|
||||
RememberLeavePos = cfg.RememberLeavePos;
|
||||
}
|
||||
|
||||
public static void WriteJsonConfiguration()
|
||||
|
|
@ -146,6 +148,7 @@ namespace TShockAPI
|
|||
cfg.ListServer = ListServer;
|
||||
cfg.spawnTileX = Main.spawnTileX;
|
||||
cfg.spawnTileY = Main.spawnTileY;
|
||||
cfg.RememberLeavePos = RememberLeavePos;
|
||||
|
||||
string json = JsonConvert.SerializeObject(cfg, Formatting.Indented);
|
||||
TextWriter tr = new StreamWriter(FileTools.ConfigPath);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue