Monitor overview and warpout?

Hey guys, I do alot of exploration and was wondering if it was possible to let Sanderling monitor my overview to warp out ?
I want it to warp out ASAP if ship get on overview ?

Yes this is possible.

For the monitoring part, you can get the overview entries from Measurement?.WindowOverview?.FirstOrDefault()?.ListView?.Entry. You can (among other properties) get Type, Name and Distance from each entry.

For warping out, you can use the menu opened via the surroundings button: You can configure the eve online client to make a bookmark show up in there.

Anyone willing to write a little script for me ?

I can confirm it’s possible, but requires some work. I modified included mining script to do something similar, but it included more stuff than it may seem from the beginning to be really efficient. I mined in ganker-heavy high-sec system using Venture (with more performant miners in mind for the future) and it means you have not much time to attempt to escape and at the same time you don’t want to run from any single contact. So, I needed several overview settings with changes of client settings for colors of overview entries, changes in default overview tab handling and so on… It could be even better if directional scanner support was there in Sanderling, but it wasn’t there at the time (not sure about now)
I stopped logging into Eve due to other interests in life, so can’t offer support here right now, sorry. Just heads up on possible complexities…

Hello, everyone!
I have the same goal - create 2 functions:

  1. bool IsFriendlyShipInGrid() - Is there a friendly ship nearby?
  2. bool IsEnemyShipInGrid() - Is there a hostile/neutral ship nearby?

Player distinguishes these concepts from icons in the overview.

And also there is the possibility of setting the background.

But with default setting oveview pilot with Neutral standing have’t any icons or backgrounds.
So I have only two ideas to solve our goal:
1.Change the default settings and recognize the background or icon.
2. Match the lists from the local chat room and the column to the overview “Name”.

The first is not universal, but simpler.
The second requires more computer resources and is more difficult to implement, but is suitable for a non-configured client.

I need a little time to investigate how the definition of friend / enemy in the local chat works.

1 Like

I know of an example, in the demo mining script:

In that case, the classification into friend/enemy depends on the text which would be displayed in the UI when you hover the mouse over the flag icon of a char in the local chat. The memory measurement contains this text (property HintText), independent of mouse location.

The said script currently uses the following code (Sanderling/src/Sanderling/Sanderling.Exe/sample/script/Mine.ore.cs at 59be48d7c04d9cb28072242a9732c20a67c69866 · Arcitectus/Sanderling · GitHub):

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);

Beautiful solution! Icons in the overview also have HintText.
But “do not work”
(if I’m looking in the right place:
MemoryMeasurement?.Value?.WindowOverview?[0]?.ListView?.Entry?[1]?.SetSprite or
MemoryMeasurement?.Value?.WindowOverview?[0]?.ListView?.Entry?[1]?.Sprite?[0]?.HintText
)

"Looking HintText in overview" screenshot

Need to find the address and add to the ReadMemory structure?

From your screenshot, I can see there is a popup for an entry in the overview, but I see no indication that this would work the analogous to the popup in the chat participant.

Lets take a closer look at the portion below I cropped from your screenshot:
https://i.imgur.com/6gEVxp5.png

The first path I would look for this is MemoryMeasurementParsed?.Value?.Tooltip.

Do you see the text visible in the popup under MemoryMeasurementParsed?.Value?.Tooltip?

Nope

http://ipic.su/img/img7/fs/eve_Tooltip.1507192373.jpg

In that case, I don’t expect this popup to be found in the current API.
I guess that making this popup available on the API requires changes to the memory reading code.

I think the task of changing the structure of reading memory is too complicated for me. I’ll try to understand it a little later after solving another important bug. (Occasionally, the EnsureIsActive() function does not work …).

If you send me a process measurement with that popup, I can look into adapting the memory reading.

In case you take a measurement, please make sure that the popup is visible during the whole time the process measurement is taken.

Done.

A little observation: if the settings without flagged a checkbox, then there is no standing in the pop.

http://ipic.su/img/img7/fs/popup_without_standing.1507281791.jpg

Otherwise

http://ipic.su/img/img7/fs/popup_with_standing.1507281848.jpg

I looked at your changes in the program. As far as I understood, now when you move the mouse pointer over the overview the tooltip is read into the MemoryMeasurement.Value.Tooltip.
A good change, but not quite what I was counting on. If you remember, our goal is to identify enemies in the overview. If you mouse over every line of the overview, then it takes too much time.
I hoped that it was possible to change MemoryRead structure in the same way as it was done in the Local chat.


@Terpla
Why use the icons? when you can add directly the background into the overview and reconize it from the memoryStructure?

The background into memoryStructure is an array, the first result [0] is the standard background, the [1] is the background setted from overview settings, if you follow my logic you will not need 2 functions, but only one to check if the entry in overview is enemy, so you can warp out, what you have to do is checking if the background is the neutral/no standing/bad standing/ red, else you can do the inverse check if is not blue/azzure/transparent (transparent is the background with index [0]) then is’t normal is a neutral or enemy then warp out

I do an example:

bool IsFriendBackgroundColor(ColorORGB color) =>
				color.OMilli == 500 && color.RMilli == 0 && color.GMilli == 150 && color.BMilli == 600;

var listOverviewEntryFriends =
				memoryMeasurement?.WindowOverview?.FirstOrDefault()?.ListView?.Entry
				?.Where(entry => entry?.ListBackgroundColor?.Any(IsFriendBackgroundColor) ?? false)
				?.ToArray();
if (listOverviewEntryFriends.Length > 0){
// friends in overview
}

In this example Im able to see if any friend is in overview, you can change and add other colors, example nostanding/neutral/bad standing/enemy

then you will have the enemy in owerview instead the friends, without check icons or hint

Thank you for detailed explanation.
Earlier I already wrote why I do not really like this option: it requires additional settings from the user.
In addition, the adding of Hinttex will also help solve the problem of determining the type of ship: there is no need to enter lists of rats.
Perhaps in the future, Hinttex will help to solve other problems (remember the description of the abilities of the carier, although this does not apply to the overview).
That’s why I still ask Viir to add this useful tip.

@Terpla

Yes it’s true but is also true we can make it “configurable” it’s a little bit of work but it’s possible build a function then react based on what the user set into config file.

At moment the only serious stuff we miss is the cooldown into memorystructure, this is the priority from my point-of-view, the rest can be added later and for now work in a pre-configured file.

Im not going versus your point-of-view, Im trying to explain why is more important fix the missing cooldown instead other stuff

If we have a path to this information in memory, I can look into adding it to memory reading code.
I do not see a memory path so far.

Let me introduce my solution: class BackgoundColors

class BackgroundColors
public static class BackgroundColors
	{
		#region Colors Names
		/// <summary>
		/// This color not used in default overview settings (#004F4C)
		/// </summary>
		public static readonly ColorORGB Mosque;       //004F4C

		/// <summary>
		/// Pilot is in your militia or allied to your militia (#4C007F)
		/// </summary>
		public static readonly ColorORGB Indigo;       //4C007F

		/// <summary>
		/// Pilot is in your alliance, Pilot has Excellent Standing.(#002699)
		/// </summary>
		public static readonly ColorORGB DarkBlue;     //002699

		/// <summary>
		/// Pilot has a limited engagement with you (#00A091)
		/// </summary>
		public static readonly ColorORGB PersianGreen; //00A091

		/// <summary>
		/// Pilot is a suspect (#FFB200)
		/// </summary>
		public static readonly ColorORGB Yellow;       //FFB200

		/// <summary>
		/// Pilot has Good Standing., Pilot (agent) is interactable (#337FFF)
		/// </summary>
		public static readonly ColorORGB Blue;         //337FFF

		/// <summary>
		/// Pilot is in your fleet (#9926E5)
		/// </summary>
		public static readonly ColorORGB Violet;       //9926E5

		/// <summary>
		/// Pilot is in your corporation (#199919)
		/// </summary>
		public static readonly ColorORGB Green;        //199919

		/// <summary>
		/// Pilot has Bad Standing., Pilot has a kill right on him that you can activate, Pilot is at war with your militia (blink) (#FF5900)
		/// </summary>
		public static readonly ColorORGB Orange;       //FF5900

		/// <summary>
		/// Pilot has bounty on him (#000000)
		/// </summary>
		public static readonly ColorORGB Black;        //000000

		/// <summary>
		/// Pilot has Neutral Standing. (#B2B2B2)
		/// </summary>
		public static readonly ColorORGB Grey;         //B2B2B2

		/// <summary>
		/// Pilot is a criminal, Pilot has Terrible Standing., Pilot has a security status below -5, Pilot is at war with your corporation/alliance (blink) (#BF0000)
		/// </summary>
		public static readonly ColorORGB Red;          //BF0000  

		#endregion

		static BackgroundColors()
		{
			Mosque = new ColorORGB { OMilli = 500, RMilli = 0, GMilli = 340, BMilli = 330 };
			Indigo = new ColorORGB { OMilli = 050, RMilli = 300, GMilli = 0, BMilli = 500 };
			DarkBlue = new ColorORGB { OMilli = 500, RMilli = 0, GMilli = 150, BMilli = 600 };
			PersianGreen = new ColorORGB { OMilli = 500, RMilli = 0, GMilli = 630, BMilli = 570 };
			Yellow = new ColorORGB { OMilli = 500, RMilli = 1000, GMilli = 700, BMilli = 0 };
			Blue = new ColorORGB { OMilli = 500, RMilli = 200, GMilli = 500, BMilli = 1000 };
			Violet = new ColorORGB { OMilli = 500, RMilli = 600, GMilli = 150, BMilli = 900 };
			Green = new ColorORGB { OMilli = 500, RMilli = 100, GMilli = 600, BMilli = 100 };
			Orange = new ColorORGB { OMilli = 500, RMilli = 1000, GMilli = 350, BMilli = 0 };
			Black = new ColorORGB { OMilli = 500, RMilli = 0, GMilli = 0, BMilli = 0 };
			Grey = new ColorORGB { OMilli = 500, RMilli = 700, GMilli = 700, BMilli = 700 };
			Red = new ColorORGB { OMilli = 500, RMilli = 750, GMilli = 0, BMilli = 0 };
		}

		public static bool IsFriend(ColorORGB color)
		{
			return new[] { DarkBlue, Indigo, Blue, Green, Violet }.Contains(color, new ORGBColorComparar());
		}

		public static bool IsNeutral(ColorORGB color) => IsSameColor(color, Grey);

		public static bool IsEnemy(ColorORGB color)
		{
			return new[] {PersianGreen, Yellow, Orange, Grey, Red }.Contains(color, new ORGBColorComparar());
		}

		public static bool IsSameColor(ColorORGB c1, ColorORGB c2)
		{
			if (c1 == null && c2 == null)
			{
				return true;
			}
			else
				if (c1 == null || c2 == null) return false;

			return c1.OMilli == c2.OMilli && c1.RMilli == c2.RMilli && c1.GMilli == c2.GMilli && c1.BMilli == c2.BMilli;
		}

public class ORGBColorComparar : IEqualityComparer<ColorORGB>
	{
		bool IEqualityComparer<ColorORGB>.Equals(ColorORGB x, ColorORGB y)
		{
			if (x == null && y == null)
			{
				return true;
			}
			else
				  if (x == null || y == null) return false;

			return x.OMilli == y.OMilli && x.RMilli == y.RMilli && x.GMilli == y.GMilli && x.BMilli == y.BMilli;
		}

		int IEqualityComparer<ColorORGB>.GetHashCode(ColorORGB obj)
		{
			ColorORGB x = obj as ColorORGB;
			return (x.BMilli ?? 0)^(x.GMilli ?? 0) + (x.RMilli ?? 0) *1000 + (x.OMilli ?? 0)*1000000;
		}
	}

I added this code in the BotExtension.cs

To work with this class, you must first configure the overview: check the checkboxes and the bot will be able to recognize the pilots with the corresponding status.

1 Like

Example :

var listOverviewEntryFriends =
								memoryMeasurement?.WindowOverview?.FirstOrDefault()?.ListView?.Entry
								?.Where(entry => entry?.ListBackgroundColor?.Any(BackgroundColors.IsFriend) ?? false)
								?.ToArray();

				if (listOverviewEntryFriends.Length > 0)
                                {///our friends in grid!
                                 }

1 Like