public void RegisterLoggedInUser(string email) { Registration registration = Registration.Create().WithEmail(email); Intercom.Client().RegisterIdentifiedUser(registration); Intercom.Client().SetLauncherVisibility(Intercom.Visibility.Visible); }
private static void InitializeLibs() { try { // For linker only MultiGestureViewRenderer multiGestureViewRenderer = new MultiGestureViewRenderer(); ImageCircleRenderer.Init(); FormsMaterial.Init(); SharpnadoInitializer.Initialize(enableInternalLogger: true); Instabug.StartWithToken(instabugToken, IBGInvocationEvent.Shake | IBGInvocationEvent.TwoFingersSwipeLeft | IBGInvocationEvent.Screenshot); Instabug.ShouldCaptureViewHierarchy = true; Instabug.TintColor = UIColor.FromHSB(257, 81, 84); Instabug.SetLocale(IBGLocale.French); Instabug.SetWelcomeMessageMode(IBGWelcomeMessageMode.WelcomeMessageModeDisabled); // Disable welcome message // Disable the Replies. If disabled, the chats list button is removed from Instabug's prompt, the in-app notifications are disabled, and manually showing the chats list doesn't have an effect. IBGReplies.Enabled = false; // Intercom Intercom.SetApiKey(intercomApiKey, intercomToken); } catch (Exception exception) { Console.WriteLine($"Exception while initializing app: {exception.Message}"); throw; } }
private void GiveStuff(IPlayer player) { if (player is Player2) { switch (desc.ItemType.ToUpper()) { case "WEAPON": GiveWeapon(player); Intercom.GiveWeapon(); break; case "AMMO": GiveAmmo(player); Intercom.GiveAmmo(); break; case "PLAYER": GivePlayerItem(player); break; default: break; } } game.GameStates.Hud.DisplayScrollingText(desc.ItemType.ToUpper() + System.Environment.NewLine + desc.NameValue, time); ISound powerup = game.Sounds.CreateSound("Ammo"); powerup.Play(); game.World.RemoveObject(this); this.Dispose(); }
public static bool Prefix(Intercom __instance, GameObject spk) { if (spk != null) { return(true); } if (Intercom.host.speaker == null) { return(true); } CharacterClassManager ccm = Intercom.host.speaker.GetComponent <CharacterClassManager>(); if (!ccm.CurClass.Is939()) { return(true); } Scp939PlayerScript script = Intercom.host.speaker.GetComponent <Scp939PlayerScript>(); if (!script.NetworkusingHumanChat) { __instance.Networkspeaker = null; } return(false); }
private void GivePlayerItem(IPlayer player) { switch (desc.NameValue.ToUpper()) { case "HEALTH": ((Player2)player).AddHealth(desc.Value); Intercom.GiveHealth(); break; case "SHIELD": ((Player2)player).AddShield(desc.Value); Intercom.GiveShield(); break; case "EXTRALIFE": //TODO: Implement ExtraLive! game.Sounds.CreateSound("ExtraLife").Play(); ((Player2)player).Lifes++; Intercom.GiveExtraLife(); break; case "FUEL": ((Player2)player).Fuel += desc.Value; Intercom.GiveFuel(); break; default: break; } }
public static void Postfix(Intercom __instance, ref bool __result) { CharacterClassManager ccm = __instance.GetComponent <CharacterClassManager>(); if (!ccm.CurClass.Is939()) { return; } __result = Vector3.Distance(__instance.transform.position, ccm.transform.position) < __instance.triggerDistance; }
private void RadioRefresh(object sender, EventArgs eventArgs) { var dcsPlayerRadioInfo = _clientStateSingleton.DcsPlayerRadioInfo; bool first = true; foreach (var radio in radioControlGroup) { radio.RepaintRadioReceive(); radio.RepaintRadioStatus(); //TODO show and hide radio 4 if its visible } Intercom.RepaintRadioStatus(); TransponderPanel.RepaintTransponderStatus(); if ((dcsPlayerRadioInfo != null) && dcsPlayerRadioInfo.IsCurrent()) { var avalilableRadios = 0; for (var i = 0; i < dcsPlayerRadioInfo.radios.Length; i++) { if (dcsPlayerRadioInfo.radios[i].modulation != RadioInformation.Modulation.DISABLED) { avalilableRadios++; } } if (avalilableRadios > 1) { if (dcsPlayerRadioInfo.control == DCSPlayerRadioInfo.RadioSwitchControls.HOTAS) { ControlText.Text = "HOTAS Controls"; } else { ControlText.Text = "Cockpit Controls"; } } else { ControlText.Text = ""; } } else { ControlText.Text = ""; } FocusDCS(); }
public override void OnEnter() { //TODO: Geräusch, dass ein Enemy den Player im Visier hat. Intercom.PlayerIsInTargetOf("a strong defense tower"); // We start attack, aim and fire"! ((TowerAI)Owner).Weapons.PrimaryWeapon.AimAt(Player.GetDirectionToPlayer(Game, Owner.GlobalPosition, 0)); ((TowerAI)Owner).Weapons.PrimaryWeapon.BeginFire(); ((TowerAI)Owner).Weapons.SecondaryWeapon.AimAt(Player.GetDirectionToPlayer(Game, Owner.GlobalPosition, 0)); ((TowerAI)Owner).Weapons.SecondaryWeapon.BeginFire(); }
public static bool Prefix(Intercom __instance, bool player) { if (EventPlugin.IntercomSpeakingEventPatchDisable) { return(true); } try { if (!__instance._interactRateLimit.CanExecute(true) || Intercom.AdminSpeaking) { return(false); } bool allow = true; if (player) { if (!__instance.ServerAllowToSpeak()) { return(false); } Events.InvokeIntercomSpeak(__instance.gameObject, ref allow); if (allow) { Intercom.host.RequestTransmission(__instance.gameObject); } } else { if (!(Intercom.host.Networkspeaker == __instance.gameObject)) { return(false); } Events.InvokeIntercomSpeak(__instance.gameObject, ref allow); if (allow) { Intercom.host.RequestTransmission(null); } } return(false); } catch (Exception exception) { Log.Error($"IntercomSpeakEvent error: {exception}"); return(true); } }
public override void OnCreate() { base.OnCreate(); RegisterActivityLifecycleCallbacks(this); //A great place to initialize Xamarin.Insights and Dependency Services! Intercom.Initialize(this, "your api key", "your app id"); Registration registration = Registration.Create().WithUserId("123456"); Intercom.Client().RegisterIdentifiedUser(registration); Intercom.Client().DisplayMessenger(); }
private static bool Prefix(Intercom __instance) { if (!string.IsNullOrEmpty(__instance.CustomContent)) { __instance.IntercomState = Intercom.State.Custom; __instance.Network_intercomText = __instance.CustomContent; } else if (__instance.Muted) { //IntercomState = State.Muted; SetContent(__instance, Intercom.State.Muted); } else if (Intercom.AdminSpeaking) { //IntercomState = State.AdminSpeaking; SetContent(__instance, Intercom.State.AdminSpeaking); } else if (__instance.remainingCooldown > 0f) { int num = Mathf.CeilToInt(__instance.remainingCooldown); //IntercomState = State.Restarting; __instance.NetworkIntercomTime = (ushort)((num >= 0) ? ((ushort)num) : 0); SetContent(__instance, Intercom.State.Restarting); } else if (__instance.Networkspeaker != null) { if (__instance.bypassSpeaking) { //IntercomState = State.TransmittingBypass; SetContent(__instance, Intercom.State.TransmittingBypass); } else { int num2 = Mathf.CeilToInt(__instance.speechRemainingTime); //IntercomState = State.Transmitting; __instance.NetworkIntercomTime = (ushort)((num2 >= 0) ? ((ushort)num2) : 0); SetContent(__instance, Intercom.State.Transmitting); } } else { //IntercomState = State.Ready; SetContent(__instance, Intercom.State.Ready); } if (Intercom.AdminSpeaking != Intercom.LastState) { Intercom.LastState = Intercom.AdminSpeaking; __instance.RpcUpdateAdminStatus(Intercom.AdminSpeaking); } return(false); }
public static void Prefix(Intercom __instance) { if (!SanyaPlugin.Instance.Config.IntercomInformation) { return; } int leftdecont = (int)Math.Truncate((DecontaminationController.Singleton.DecontaminationPhases[DecontaminationController.Singleton.DecontaminationPhases.Length - 1].TimeTrigger) - Math.Truncate(DecontaminationController.GetServerTime)); int leftautowarhead = AlphaWarheadController.Host != null ? (int)Mathf.Clamp(AlphaWarheadController.Host._autoDetonateTime - (AlphaWarheadController.Host._autoDetonateTime - AlphaWarheadController.Host._autoDetonateTimer), 0, AlphaWarheadController.Host._autoDetonateTimer) : -1; int nextRespawn = (int)Math.Truncate(RespawnManager.CurrentSequence() == RespawnManager.RespawnSequencePhase.RespawnCooldown ? RespawnManager.Singleton._timeForNextSequence - RespawnManager.Singleton._stopwatch.Elapsed.TotalSeconds : 0); bool isContain = PlayerManager.localPlayer.GetComponent <CharacterClassManager>()._lureSpj.allowContain; bool isAlreadyUsed = OneOhSixContainer.used; leftdecont = Mathf.Clamp(leftdecont, 0, leftdecont); string contentfix = string.Concat( $"作戦経過時間 : {RoundSummary.roundTime / 60:00}:{RoundSummary.roundTime % 60:00}\n", $"残存SCPオブジェクト : {RoundSummary.singleton.CountTeam(Team.SCP):00}/{RoundSummary.singleton.classlistStart.scps_except_zombies:00}\n", $"残存Dクラス職員 : {RoundSummary.singleton.CountTeam(Team.CDP):00}/{RoundSummary.singleton.classlistStart.class_ds:00}\n", $"残存研究員 : {RoundSummary.singleton.CountTeam(Team.RSC):00}/{RoundSummary.singleton.classlistStart.scientists:00}\n", $"AlphaWarheadのステータス : {(AlphaWarheadOutsitePanel.nukeside.enabled ? "READY" : "DISABLED")}\n", $"SCP-106再収容設備:{(isContain ? (isAlreadyUsed ? "使用済み" : "準備完了") : "人員不在")}\n", $"軽度収容区画閉鎖まで : {leftdecont / 60:00}:{leftdecont % 60:00}\n", $"自動施設爆破開始まで : {leftautowarhead / 60:00}:{leftautowarhead % 60:00}\n", $"接近中の部隊突入まで : {nextRespawn / 60:00}:{nextRespawn % 60:00}\n\n" ); if (__instance.Muted) { contentfix += "アクセスが拒否されました"; } else if (Intercom.AdminSpeaking) { contentfix += $"施設管理者が放送設備をオーバーライド中"; } else if (__instance.remainingCooldown > 0f) { contentfix += $"放送設備再起動中 : 残り{Mathf.CeilToInt(__instance.remainingCooldown)}秒"; } else if (__instance.speaker != null) { contentfix += $"{Player.Get(__instance.speaker).Nickname}が放送中... : 残り{Mathf.CeilToInt(__instance.speechRemainingTime)}秒"; } else { contentfix += "放送設備準備完了"; } __instance.CustomContent = contentfix; return; }
protected override void OnCreate(Bundle bundle) { TabLayoutResource = Resource.Layout.Tabbar; ToolbarResource = Resource.Layout.Toolbar; base.SetTheme(Resource.Style.MainTheme); base.OnCreate(bundle); global::Xamarin.Forms.Forms.Init(this, bundle); //LoadApplication(new App()); Intercom.Initialize(this.Application, "android_sdk-bec55dc8fc4abbcba258f5132cad4d4cfc91f997", "zyx82osk"); }
private static void SetContent(Intercom intercom, Intercom.State state) { var customContents = SameThings.Instance.Config.CustomIntercomContent; if (customContents.TryGetValue(state, out var content)) { intercom.Network_intercomText = string.Format(content, intercom.NetworkIntercomTime); intercom.Network_state = Intercom.State.Custom; } else { intercom.Network_state = state; } }
private static bool Prefix(Intercom __instance, bool player) { try { if (!__instance._interactRateLimit.CanExecute(true) || Intercom.AdminSpeaking) { return(false); } var ev = new IntercomSpeakingEventArgs(player ? API.Features.Player.Get(__instance.gameObject) : null); if (player) { if (!__instance.ServerAllowToSpeak()) { return(false); } Player.OnIntercomSpeaking(ev); if (ev.IsAllowed) { Intercom.host.RequestTransmission(__instance.gameObject); } } else { if (!(Intercom.host.Networkspeaker == __instance.gameObject)) { return(false); } Player.OnIntercomSpeaking(ev); if (ev.IsAllowed) { Intercom.host.RequestTransmission(null); } } return(false); } catch (Exception e) { Exiled.API.Features.Log.Error($"Exiled.Events.Patches.Events.Player.IntercomSpeaking: {e}\n{e.StackTrace}"); return(true); } }
public static bool Prefix(Intercom __instance, bool player) { Plugin.Log.Debug("SetTransmitPatch"); Player ply = Player.Get(__instance.gameObject); if (!Plugin.GhostList.Contains(ply)) { return(true); } ply.ClearBroadcasts(); ply.Broadcast(3, Translation.Translation.GetText().IntercomDenied); return(false); }
public IEnumerator <float> CheckFor939Intercom() { while (true) { yield return(Timing.WaitForSeconds(0.1f)); if (Intercom.host.speaker != null || Intercom.host.speaking) { continue; } foreach (ReferenceHub rh in GetHubs()) { try { if (!rh.characterClassManager.CurClass.Is939()) { continue; } GameObject player = rh.gameObject; Intercom intercom = player.GetComponent <Intercom>(); Scp939PlayerScript script = player.GetComponent <Scp939PlayerScript>(); if (Vector3.Distance(player.transform.position, IntercomArea.position) > intercom.triggerDistance) { continue; } if (!script.NetworkusingHumanChat) { continue; } Intercom.host.RequestTransmission(player); } catch (Exception e) { while (e != null) { plugin.Error(e.ToString()); e = e.InnerException; } } } } }
public void Initialize() { lock (this) { isInitialized.CheckIfFulfills("CommandDispatcher", "initialized", false); isInitialized = true; } MediaEncodingProfile mediaEncodingProfile = MediaEncodingProfile.CreateMp4(VideoEncodingQuality.Vga); mediaEncodingProfile.Video.FrameRate.Numerator = 5; mediaEncodingProfile.Video.FrameRate.Denominator = 1; intercom = new Intercom(mediaEncodingProfile, SettingsManager.Instance.IntercomButtonPin, gpio); intercom.Initialize(); devices = OutputDevice.CreateOutputDevices(gpio); }
private static bool Prefix(Intercom __instance, bool player) { if (!__instance._interactRateLimit.CanExecute(true) || Intercom.AdminSpeaking) { return(false); } var ev = new IntercomSpeakingEventArgs(player ? API.Features.Player.Get(__instance.gameObject) : null); if (player) { if (!__instance.ServerAllowToSpeak()) { return(false); } Player.OnIntercomSpeaking(ev); if (ev.IsAllowed) { Intercom.host.RequestTransmission(__instance.gameObject); } } else { if (!(Intercom.host.Networkspeaker == __instance.gameObject)) { return(false); } Player.OnIntercomSpeaking(ev); if (ev.IsAllowed) { Intercom.host.RequestTransmission(null); } } return(false); }
private void RadioRefresh(object sender, EventArgs eventArgs) { var IL2PlayerRadioInfo = _clientStateSingleton.PlayerGameState; Radio1.RepaintRadioStatus(); Radio1.RepaintRadioReceive(); if (IL2PlayerRadioInfo.radios[2].modulation != RadioInformation.Modulation.DISABLED) { if (Radio2.Visibility == Visibility.Collapsed) { //show Radio2.Visibility = Visibility.Visible; Radio2Seperator.Visibility = Visibility.Visible; MinHeight = _originalMinHeight + 55 + 10; Recalculate(); } Radio2.RepaintRadioStatus(); Radio2.RepaintRadioReceive(); } else { if (Radio2.Visibility != Visibility.Collapsed) { Radio2.Visibility = Visibility.Collapsed; MinHeight = _originalMinHeight; Radio2Seperator.Visibility = Visibility.Collapsed; Recalculate(); } } Intercom.RepaintRadioStatus(); FocusIL2(); }
public void RegisterUser(UserModel user) { if (user == null) { Intercom.RegisterUnidentifiedUser(); return; } var currentUser = AppSettings.CurrentUser; ICMCompany company = null; if (currentUser.Company != null) { company = new ICMCompany(); company.Name = currentUser.Company.Name; company.CompanyId = currentUser.Company.Id; } var attributes = new ICMUserAttributes(); attributes.Name = currentUser.Firstname; attributes.Email = currentUser.Mail; attributes.UserId = currentUser.Id; attributes.Phone = currentUser.PhoneNumber; attributes.SignedUpAt = DateTimeToNSDate(currentUser.SubscriptionDate); var companies = new ICMCompany[1]; companies[0] = company; attributes.Companies = companies; Intercom.UpdateUser(attributes); Intercom.RegisterUserWithUserId(user.Id, user.Mail); //Intercom.HandleIntercomPushNotification(); }
private void RadioRefresh(object sender, EventArgs eventArgs) { var dcsPlayerRadioInfo = _clientStateSingleton.DcsPlayerRadioInfo; foreach (var radio in radioControlGroup) { radio.RepaintRadioStatus(); radio.RepaintRadioReceive(); } Intercom.RepaintRadioStatus(); TransponderPanel.RepaintTransponderStatus(); if ((dcsPlayerRadioInfo != null) && dcsPlayerRadioInfo.IsCurrent()) { var availableRadios = 0; //handle 4th radio on the overlay or not if (dcsPlayerRadioInfo.radios.Length < 5) { Radio4.Visibility = Visibility.Collapsed; if (MinHeight != _originalMinHeight) { MinHeight = _originalMinHeight; Recalculate(); } } else { if (dcsPlayerRadioInfo.radios[4].modulation == RadioInformation.Modulation.DISABLED) { Radio4.Visibility = Visibility.Collapsed; if (MinHeight != _originalMinHeight) { MinHeight = _originalMinHeight; Recalculate(); } } else { //show it Radio4.Visibility = Visibility.Visible; if (MinHeight == _originalMinHeight) { MinHeight += Radio4.Height; Recalculate(); } } } for (var i = 0; i < dcsPlayerRadioInfo.radios.Length; i++) { if (dcsPlayerRadioInfo.radios[i].modulation != RadioInformation.Modulation.DISABLED) { availableRadios++; } } if (availableRadios > 1) { if (dcsPlayerRadioInfo.control == DCSPlayerRadioInfo.RadioSwitchControls.HOTAS) { ControlText.Text = "HOTAS Controls"; } else { ControlText.Text = "Cockpit Controls"; } } else { ControlText.Text = ""; } } else { Radio4.Visibility = Visibility.Collapsed; if (MinHeight != _originalMinHeight) { MinHeight = _originalMinHeight; Recalculate(); } ControlText.Text = ""; } FocusDCS(); }
public void OpenDoor(Intercom intercom) { _reposistory.OpenDoor(intercom); }
public void RegisterAnonymousUser() { Intercom.RegisterUnidentifiedUser(); }
private void RadioRefresh(object sender, EventArgs eventArgs) { var dcsPlayerRadioInfo = _clientStateSingleton.DcsPlayerRadioInfo; foreach (var radio in radioControlGroup) { radio.RepaintRadioStatus(); radio.RepaintRadioReceive(); } Intercom.RepaintRadioStatus(); TransponderPanel.RepaintTransponderStatus(); if ((dcsPlayerRadioInfo != null) && dcsPlayerRadioInfo.IsCurrent()) { var availableRadios = 0; for (var i = 0; i < dcsPlayerRadioInfo.radios.Length; i++) { if (dcsPlayerRadioInfo.radios[i].modulation != RadioInformation.Modulation.DISABLED) { availableRadios++; } } if (availableRadios == 6 || dcsPlayerRadioInfo.radios.Length >= 6 && dcsPlayerRadioInfo.radios[5].modulation != RadioInformation.Modulation.DISABLED) { Radio5.Visibility = Visibility.Visible; Radio4.Visibility = Visibility.Visible; if (MinHeight != _originalMinHeight + (_radioHeight * 2)) { MinHeight = (_originalMinHeight + (_radioHeight * 2)); Recalculate(); } } else if (availableRadios == 5 || dcsPlayerRadioInfo.radios.Length >= 5 && dcsPlayerRadioInfo.radios[4].modulation != RadioInformation.Modulation.DISABLED) { Radio5.Visibility = Visibility.Collapsed; Radio4.Visibility = Visibility.Visible; if (MinHeight != _originalMinHeight + _radioHeight) { MinHeight = _originalMinHeight + _radioHeight; Recalculate(); } } else { ResetHeight(); } if (availableRadios > 1) { if (dcsPlayerRadioInfo.control == DCSPlayerRadioInfo.RadioSwitchControls.HOTAS) { ControlText.Text = "HOTAS Controls"; } else { ControlText.Text = "Cockpit Controls"; } } else { ControlText.Text = ""; } } else { ResetHeight(); ControlText.Text = ""; } FocusDCS(); }
public static bool Prefix(Intercom __instance) { if (!Configs.intercom_information) { return(true); } int leftdecont = (int)((Math.Truncate(((11.74f * 60) * 100f)) / 100f) - (Math.Truncate(PlayerManager.localPlayer.GetComponent <DecontaminationLCZ>().time * 100f) / 100f)); int leftautowarhead = Mathf.Clamp(Configs.auto_warhead_start - RoundSummary.roundTime, 0, Configs.auto_warhead_start); int nextRespawn = (int)Math.Truncate(PlayerManager.localPlayer.GetComponent <MTFRespawn>().timeToNextRespawn + PlayerManager.localPlayer.GetComponent <MTFRespawn>().respawnCooldown); bool isContain = PlayerManager.localPlayer.GetComponent <CharacterClassManager>()._lureSpj.NetworkallowContain; bool isAlreadyUsed = UnityEngine.Object.FindObjectOfType <OneOhSixContainer>().Networkused; float totalvoltagefloat = 0f; foreach (var i in Generator079.generators) { totalvoltagefloat += i.localVoltage; } totalvoltagefloat *= 1000f; string contentfix = string.Concat( $"作戦経過時間 : {RoundSummary.roundTime / 60:00}:{RoundSummary.roundTime % 60:00}\n", $"残存SCPオブジェクト : {RoundSummary.singleton.CountTeam(Team.SCP):00}/{RoundSummary.singleton.classlistStart.scps_except_zombies:00}\n", $"残存Dクラス職員 : {RoundSummary.singleton.CountTeam(Team.CDP):00}/{RoundSummary.singleton.classlistStart.class_ds:00}\n", $"残存科学者 : {RoundSummary.singleton.CountTeam(Team.RSC):00}/{RoundSummary.singleton.classlistStart.scientists:00}\n", $"施設内余剰電力 : {totalvoltagefloat:0000}kVA\n", $"AlphaWarheadのステータス : {(AlphaWarheadOutsitePanel.nukeside.Networkenabled ? "READY" : "DISABLED")}\n", $"SCP-106再収用設備:{(isContain ? (isAlreadyUsed ? "使用済み" : "準備完了") : "人員不在")}\n", $"軽度収用区画閉鎖まで : {leftdecont / 60:00}:{leftdecont % 60:00}\n", $"自動施設爆破開始まで : {leftautowarhead / 60:00}:{leftautowarhead % 60:00}\n", $"接近中の部隊突入まで : {nextRespawn / 60:00}:{nextRespawn % 60:00}\n" ); if (__instance.Muted) { __instance._content = contentfix + "あなたは管理者によってミュートされている"; } else if (Intercom.AdminSpeaking) { __instance._content = contentfix + "管理者が放送設備をオーバーライド中"; } else if (__instance.remainingCooldown > 0f) { __instance._content = contentfix + "放送設備再起動中 : " + Mathf.CeilToInt(__instance.remainingCooldown) + "秒必要"; } else if (__instance.Networkspeaker != null) { if (__instance.speechRemainingTime == -77f) { __instance._content = contentfix + "放送中... : オーバーライド"; } else { __instance._content = contentfix + $"{ReferenceHub.GetHub(__instance.Networkspeaker).GetNickname()}が放送中... : 残り" + Mathf.CeilToInt(__instance.speechRemainingTime) + "秒"; } } else { __instance._content = contentfix + "放送設備準備完了"; } if (__instance._contentDirty) { __instance.NetworkintercomText = __instance._content; __instance._contentDirty = false; } if (Intercom.AdminSpeaking != Intercom.LastState) { Intercom.LastState = Intercom.AdminSpeaking; __instance.RpcUpdateAdminStatus(Intercom.AdminSpeaking); } return(false); }
public void ShowHelpCenter() { Intercom.PresentHelpCenter(); }
private static bool Prefix(Intercom __instance) { if (__instance.remainingCooldown > 0f) { if (Images.Singleton.ICool) { return(true); } Images.Singleton.IntercomText = null; ReferenceHub.HostHub.GetComponent <Intercom>().CustomContent = ""; Images.Singleton.ICool = true; Images.Singleton.IReady = false; Images.Singleton.ITrans = false; Timing.KillCoroutines(Images.Singleton.IntercomHandle); Images.Singleton.RunIntercomImage(Images.Singleton.Config.DefaultIntercomImageCooldown); } else if (__instance.Networkspeaker != null) { if (Images.Singleton.ITrans) { return(true); } Images.Singleton.IntercomText = null; ReferenceHub.HostHub.GetComponent <Intercom>().CustomContent = ""; Images.Singleton.ITrans = true; Images.Singleton.IReady = false; Images.Singleton.ICool = false; Timing.KillCoroutines(Images.Singleton.IntercomHandle); Images.Singleton.RunIntercomImage(Images.Singleton.Config.DefaultIntercomImageSpeaking); } else { if (Images.Singleton.IReady) { return(true); } Images.Singleton.IntercomText = null; ReferenceHub.HostHub.GetComponent <Intercom>().CustomContent = ""; Images.Singleton.IReady = true; Images.Singleton.ITrans = false; Images.Singleton.ICool = false; Timing.KillCoroutines(Images.Singleton.IntercomHandle); Images.Singleton.RunIntercomImage(Images.Singleton.Config.DefaultIntercomImageReady); } return(true); }
public void ShowMessenger() { Intercom.PresentMessenger(); }
public void Logout() { Intercom.Logout(); }