// ReSharper disable once InconsistentNaming
            private static bool Prefix(Chat __instance, InputField ___m_input)
            {
                string text = ___m_input.text;

                if (text.ToLower().Equals("/convertpins ignorelocaldupes"))
                {
                    UtilityPin.UploadAllPins(true);
                    return(false);
                }
                if (text.ToLower().Equals("/convertpins"))
                {
                    UtilityPin.UploadAllPins();
                    return(false);
                }
                if (text.ToLower().Equals("/deletealllocalpins"))
                {
                    UtilityPin.DeleteLocalPins();
                    return(false);
                }
                if (text.ToLower().Equals("/downloadpins"))
                {
                    UtilityPin.DownloadPins();
                    return(false);
                }
                return(true);
            }
Esempio n. 2
0
            // ReSharper disable once InconsistentNaming
            private static void Postfix(Player __instance)
            {
                if (Store.HasKeyConvertAll() && Input.GetKeyDown(Store.GetKeyConvertAll()))
                {
                    Utility.Log("Hotkey: GetKeyConvertAll");
                    UtilityPin.UploadAllPins(false);
                }

                if (Store.HasKeyConvertIgnoreDupes() && Input.GetKeyDown(Store.GetKeyConvertIgnoreDupes()))
                {
                    Utility.Log("Hotkey: GetKeyConvertIgnoreDupes");
                    UtilityPin.UploadAllPins(true);
                }
            }