Skip to content

Commit 8b75c74

Browse files
committed
v1.0.1 Overwriting Removed
-The CustomDeathMessages.json file no longer gets overwritten when the mod is unable to load the messages properly. It will still use the default messages, but without updating the file. -Fixed a typo
1 parent 54a2f87 commit 8b75c74

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

CustomDeathMessages/Plugin.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public sealed class Mod : BaseUnityPlugin
1616
//Mod Details
1717
private const string modGUID = "Distance.CustomDeathMessages";
1818
private const string modName = "Custom Death Messages";
19-
private const string modVersion = "1.0.0";
19+
private const string modVersion = "1.0.1";
2020

2121
//Config Entry Strings
2222

@@ -42,8 +42,6 @@ void Awake()
4242

4343
LoadMessages();
4444

45-
SaveMessages();
46-
4745
//Apply Patches
4846
Logger.LogInfo("Loading...");
4947
harmony.PatchAll();
@@ -101,6 +99,7 @@ private void LoadMessages()
10199
{
102100
Log.LogWarning("CustomDeathMessages.json doesn't exist. Using Defaults, generating a new file");
103101
AddDefaultsToDicationary();
102+
SaveMessages();
104103
}
105104
}
106105

@@ -167,7 +166,7 @@ private void AddDefaultsToDicationary()
167166

168167
string[] NotReady = new string[]
169168
{
170-
"{0} is a little busy, try agains later"
169+
"{0} is a little busy, try again later"
171170
};
172171
MessagesDictionary.Add("NotReady", NotReady);
173172

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Do note that you'll have to edit the json file yourself to add more messages. Wh
3838
"[FFFFFF]{0}[-] [00FF00]f[-][00FFFF]i[-][0000FF]n[-][FF00FF]i[-][FF0000]s[-][FFFF00]h[-][00FF00]e[-][00FFFF]d[-]"
3939
],
4040
"NotReady" : [
41-
"{0} is a little busy, try agains later"
41+
"{0} is a little busy, try again later"
4242
],
4343
"Spectate" : [
4444
"[-]This map is too hard, {0} gave up"

0 commit comments

Comments
 (0)