Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Sanderling.Parse.IMemoryMeasurement Measurement => Sanderling?.MemoryMeasurementParsed?.Value;
- var chatLocal =
- Sanderling.MemoryMeasurementParsed?.Value?.WindowChatChannel
- ?.FirstOrDefault(windowChat => windowChat?.Caption?.RegexMatchSuccessIgnoreCase("local") ?? false);
- bool hostileOrNeutralsInLocal => 1 != chatLocal?.ParticipantView?.Entry?.Count(IsNeutralOrEnemy);
- bool IsNeutralOrEnemy(IChatParticipantEntry participantEntry) =>
- !(participantEntry?.FlagIcon?.Any(flagIcon =>
- new[] { "good standing", "excellent standing", "Pilot is in your (fleet|corporation)", }
- .Any(goodStandingText =>
- flagIcon?.HintText?.RegexMatchSuccessIgnoreCase(goodStandingText) ?? false)) ?? false);
- while(true)
- {
- var chatLocal =
- Sanderling.MemoryMeasurementParsed?.Value?.WindowChatChannel
- ?.FirstOrDefault(windowChat => windowChat?.Caption?.RegexMatchSuccessIgnoreCase("local") ?? false);
- if(chatLocal?.ParticipantView?.Entry?.Count(IsNeutralOrEnemy) > 1)
- {
- Host.Log(hostileOrNeutralsInLocal);
- Host.Log(chatLocal?.ParticipantView?.Entry?.Count(IsNeutralOrEnemy));
- System.Media.SoundPlayer simpleSound = new System.Media.SoundPlayer(@"C:\watchalm.wav");
- simpleSound.Play();
- }
- Host.Delay(4000);
- Sanderling.InvalidateMeasurement();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement