Skip to content

Commit

Permalink
1.0.7
Browse files Browse the repository at this point in the history
  • Loading branch information
oqyh authored Apr 30, 2024
1 parent 04416f9 commit d22c891
Show file tree
Hide file tree
Showing 4 changed files with 1,386 additions and 678 deletions.
28 changes: 19 additions & 9 deletions Config/Configs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,20 @@ public class ConfigData
{
public bool KS_EnableQuakeSounds { get; set; }
public bool KS_DisableQuakeSoundsOnWarmUp { get; set; }
public bool KS_ResetKillStreakOnEveryRound { get; set; }

public string empty { get; set; }
public string KS_HeadShotKillSoundPath { get; set; }
public bool KS_AddMenu_FreezeOnOpenMenu { get; set; }
public string KS_AddMenu_HeadShotKillSoundPath { get; set; }

public string KS_BodyKillSoundPath { get; set; }
public string KS_AddMenu_BodyKillSoundPath { get; set; }

public string KS_HeadShotHitSoundPath { get; set; }
public string KS_AddMenu_HeadShotHitSoundPath { get; set; }

public string KS_BodyHitSoundPath { get; set; }
public string KS_AddMenu_BodyHitSoundPath { get; set; }
public bool KS_AddMenu_QuakeSoundsToggle { get; set; }
public bool KS_AddMenu_QuakeCenterMessageToggle { get; set; }
public bool KS_AddMenu_QuakeChatMessageToggle { get; set; }

public string empty2 { get; set; }
public bool KS_FreezeOnOpenMenuDefaultValue { get; set; }
Expand All @@ -114,18 +119,23 @@ public ConfigData()
{
KS_EnableQuakeSounds = false;
KS_DisableQuakeSoundsOnWarmUp = true;
KS_ResetKillStreakOnEveryRound = true;
empty = "-----------------------------------------------------------------------------------";
KS_HeadShotKillSoundPath = "sounds/GoldKingZ/Training/bell_normal.vsnd_c";
KS_BodyKillSoundPath = "sounds/GoldKingZ/Training/timer_bell.vsnd_c";
KS_HeadShotHitSoundPath = "sounds/GoldKingZ/Training/bell_impact.vsnd_c";
KS_BodyHitSoundPath = "sounds/GoldKingZ/Training/timer_bell.vsnd_c";
KS_AddMenu_FreezeOnOpenMenu = true;
KS_AddMenu_HeadShotKillSoundPath = "sounds/GoldKingZ/Training/bell_normal.vsnd_c";
KS_AddMenu_BodyKillSoundPath = "sounds/GoldKingZ/Training/timer_bell.vsnd_c";
KS_AddMenu_HeadShotHitSoundPath = "sounds/GoldKingZ/Training/bell_impact.vsnd_c";
KS_AddMenu_BodyHitSoundPath = "sounds/GoldKingZ/Training/timer_bell.vsnd_c";
KS_AddMenu_QuakeSoundsToggle = true;
KS_AddMenu_QuakeCenterMessageToggle = true;
KS_AddMenu_QuakeChatMessageToggle = true;
empty2 = "-----------------------------------------------------------------------------------";
KS_FreezeOnOpenMenuDefaultValue = true;
KS_HeadShotKillSoundDefaultValue = true;
KS_BodyKillSoundDefaultValue = false;
KS_HeadShotHitSoundDefaultValue = false;
KS_BodyHitSoundDefaultValue = false;
KS_InGameMenu = "!soundmenu,!soundsmenu,!menusound,!menusounds";
KS_InGameMenu = "!quake,!quakesounds,!soundmenu,!soundsmenu,!menusound,!menusounds,!soundsettings,!soundsetting";
KS_OnlyAllowTheseGroupsToToggle = "";
empty3 = "-----------------------------------------------------------------------------------";
Information_For_You_Dont_Delete_it = " Vist [https://github.com/oqyh/cs2-Kill-Sound-GoldKingZ/tree/main?tab=readme-ov-file#-configuration-] To Understand All Above";
Expand Down
13 changes: 11 additions & 2 deletions Config/Helper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ public static void CreateDefaultWeaponsJson(string jsonFilePath)

string json = System.Text.Json.JsonSerializer.Serialize(configData, options);

json = "// Note: To Use These You Need To Enable KS_EnableQuakeSounds First In config.json \n// Then Download https://github.com/Source2ZE/MultiAddonManager With Gold KingZ WorkShop \n// https://steamcommunity.com/sharedfiles/filedetails/?id=3230015783\n// mm_extra_addons 3230015783 \n\n" + json;
json = "// Note: To Use These You Need To Enable KS_EnableQuakeSounds First In config.json \n// Then Download https://github.com/Source2ZE/MultiAddonManager With Gold KingZ WorkShop \n// https://steamcommunity.com/sharedfiles/filedetails/?id=3230015783\n// mm_extra_addons 3230015783\n// You Can Find WorkShop Path Sound In https://github.com/oqyh/cs2-Kill-Sound-GoldKingZ/blob/main/sounds/Gold%20KingZ%20WorkShop%20Sounds.txt \n\n" + json;

File.WriteAllText(jsonFilePath, json);
}
Expand Down Expand Up @@ -383,9 +383,12 @@ public class PersonData
public bool headshothit { get; set; }
public bool bodyshotkill { get; set; }
public bool bodyshothit { get; set; }
public bool quakesounds { get; set; }
public bool quakehmessages { get; set; }
public bool quakecmessages { get; set; }
public DateTime DateAndTime { get; set; }
}
public static void SaveToJsonFile(ulong PlayerSteamID, bool freezemenu, bool headshotkill, bool headshothit, bool bodyshotkill, bool bodyshothit, DateTime DateAndTime)
public static void SaveToJsonFile(ulong PlayerSteamID, bool freezemenu, bool headshotkill, bool headshothit, bool bodyshotkill, bool bodyshothit, bool quakesounds, bool quakehmessages, bool quakecmessages, DateTime DateAndTime)
{
string Fpath = Path.Combine(Configs.Shared.CookiesModule!, "../../plugins/Kill-Sound-GoldKingZ/Cookies/");
string Fpathc = Path.Combine(Configs.Shared.CookiesModule!, "../../plugins/Kill-Sound-GoldKingZ/Cookies/Kill_Sound_Cookies.json");
Expand Down Expand Up @@ -414,6 +417,9 @@ public static void SaveToJsonFile(ulong PlayerSteamID, bool freezemenu, bool hea
existingPerson.headshothit = headshothit;
existingPerson.bodyshotkill = bodyshotkill;
existingPerson.bodyshothit = bodyshothit;
existingPerson.quakesounds = quakesounds;
existingPerson.quakehmessages = quakehmessages;
existingPerson.quakecmessages = quakecmessages;
existingPerson.DateAndTime = DateAndTime;
}
else
Expand All @@ -425,6 +431,9 @@ public static void SaveToJsonFile(ulong PlayerSteamID, bool freezemenu, bool hea
headshothit = headshothit,
bodyshotkill = bodyshotkill,
bodyshothit = bodyshothit,
quakesounds = quakesounds,
quakehmessages = quakehmessages,
quakecmessages = quakecmessages,
DateAndTime = DateAndTime
};
allPersonsData.Add(newPerson);
Expand Down
Loading

0 comments on commit d22c891

Please sign in to comment.