Powder_Keg and I have been working on a system to detect where the player clicks without the use of EUDs. We have hit somewhat of a wall.

**The Concept**Using a group of scourges located outside of the detectable area, the system will be able to pinpoint the exact location where the scourges are ordered to move to. By calculating each of the scourge's paths you should be able to determine where these paths intersect.

**Requirements**Maximum of 12 scourges.

128x128 detectable area. This is to ensure a wide potential of practical uses for different maps.

Accurately detect a click within a 1x1 tile area.

Scourges must be located outside of the detectable area to allow mobile grids.

**Issues**It may be difficult to determine angles after around 16?. Scourge pathing (or maybe pathing in general) allows for small inconsistencies that may hinder having further detectable angles.

What would be the minimum detectable angles necessary to cover the entire 128x128 grid?

Because the system will have to calculate the exact angle of several scourge paths the majority of the trigger production will be automated.

**Progress So Far**I've got a rough idea of how the system will work but it still needs some tweaking. I'm using inverted locations around the scourge and depending on what combination of locations the scourge enters after it leaves the starting point I can determine the rough angle of travel. However I think that I will have to tweak the location sizes in order to get accurate angles.

I've already figured out how to move a location to the clicked area by using a combination of a mobile grid for the x axis and a static grid for the y axis.

Attached is an example map. It has a rough system for detecting the angle of travel of the scourge but it isn't accurate yet. In the middle would be the 128x128 example grid.

Of course different systems are always welcome.

**Attachments:**

None.

1.) Use simple brings to check which x-axis and y-axis scourges a click was closest too (simple logic i.e. 'is it to the right of this one?')

2.) Grab the set of coordinates for each scourge: you may find this helpful (or maddening):

Exact Coordinate Detection3.) Calculate the angles of both scourges (calculate the imaginary triangles side lengths, use law of sines/cosines, taylor series/hardcoded angle values)

4.) Pick an origin somewhere on the map, using the start-point, your angle, and the angle tools listed above, calculate the slope-intercept equation for your line

5.) Calculate the intersection point from the two slope-intercept forms

I did something similar getting target Y coordinate and angle using EUDs, then calculating X coordinate:

http://www.staredit.net/topic/15142/

TheNitesWhoSay - Clan Aura -

githubReached the top of StarCraft theory crafting 2:12 AM CST, August 2nd, 2014.
I haven't looked at your map, but without EUD's (and the game-breaking Extended Preplaced Units, which do not use EUD's IIRC) you are indeed restricted to using locations/brings to detect the scourge placement offsets which would occur after the player ordered to move them.

I don't know if you are already aware of

FRAGS which implements just this, albeit in a much smaller area.

Kenoli's method of calculating placement offsets provides pixel accuracy. albeit not the easiest to understand, and hybrid location grids are probably the best option for placing locations at the desired point in the area, demonstrated

here (mobile grids prohibit air units in the vicinity, and cause nearby ground units to be slowed).

In essence, each scourge movement provides a single linear equation. With two scourges, you can solve a system of two linear equations to get a single x,y point (except when the slopes are parallel). With three or more equations, there is no guarantee that a solution exists, so you're probably left to solve each combination of two equations, then simply calculate the arithmetic mean of the resulting points, which presumably provide better accuracy than simply using two scourges.

Either way, you are way better off using some sort of programming language for trigger/location generation. Oreo Triggers is probably the best option as it allows you to directly compile trigger data into your map, as opposed to the other options where you have to manually copy and paste text triggers. SCMC is another option that also directly compiles but is less documented (if at all).

None.

Thanks for the replies guys. I'll check out the links when I have the time. I was more focused on how to set up the triggers and locations in order to get the directions of the scourges. I do plan on using Oreo to automate the calculation part.

None.