Staredit Network > Forums > SC1 UMS Theory and Ideas > Topic: Skewed Locations
Skewed Locations
Aug 10 2011, 4:53 pm
By: Sacrieur  

Aug 10 2011, 4:53 pm Sacrieur Post #1

Still Napping

A skewed location is a location that cannot be centered correctly. It instead becomes off-center by half a pixel. Pixels are the smallest particle in StarCraft, and cannot be broken down further. This limitation causes all skewed locations to be 1 px more on one side than the other. All skewed locations will center in a unique fashion:



Locations will always shift to the right or down when skewing occurs, never up or to the left. To accomplish skewing, a location must be an odd number of pixels larger than the unit or location being centered on.


Location Centers

Skewing occurs due to the center of locations, which exists as a pixel up and to the left of the exact center in a location with even dimensions. While a general rule is that a location will center down and to the left, this does not apply to odd locations centering on even locations: only even locations will skew.


Inverted Skewed Location

Inverted skewed locations behave in the exact same manner as skewed locations. There is no special qualities or changes that occur from inversion. They also skew down and to the right.


Applications






I've attached a test map so you may confirm the results for yourself. The map size is 32x32, so you must run a game with normal dimensions before playing it.

Attachments:
Skewed Locations.scx
Hits: 14 Size: 35.84kb

Post has been edited 4 time(s), last time on Sep 21 2012, 11:36 pm by Sacrieur.



None.

Aug 10 2011, 7:36 pm JehZirO Post #2



Hmm... What would be any other applications. I'm sure some will come along but what do you believe will come out of this.



None.

Aug 10 2011, 8:36 pm Sacrieur Post #3

Still Napping

Quote from JehZirO
Hmm... What would be any other applications. I'm sure some will come along but what do you believe will come out of this.

Working on some things right now, I'll post them in this forum if I have anything to show. Due to the nature of the discovery, most ideas revolve around determining the direction of something.



None.

Aug 11 2011, 10:30 pm Chia-Tyrant Post #4



I apologize if this has been done before or if everyone's already aware of this but I attached a map that uses "skewed locations" to detect in which direction your unit is moving then fires a projectiles in that direction. A few notes about it:
  • I only detect 8 directions but you could probably make it for 16. (I just got lazy :P)
  • You don't have to slow down the unit but, if you don't, you'd probably need a few more locations.
  • Some of the locations could be redundant; I didn't test it out extensively.
  • You could make certain directions more/less sensitive by playing a bit with the triggers.

Hope it helps ^^



None.

Aug 11 2011, 11:34 pm Sacrieur Post #5

Still Napping

Quote from Chia-Tyrant
I apologize if this has been done before or if everyone's already aware of this but I attached a map that uses "skewed locations" to detect in which direction your unit is moving then fires a projectiles in that direction. A few notes about it:
  • I only detect 8 directions but you could probably make it for 16. (I just got lazy :P)
  • You don't have to slow down the unit but, if you don't, you'd probably need a few more locations.
  • Some of the locations could be redundant; I didn't test it out extensively.
  • You could make certain directions more/less sensitive by playing a bit with the triggers.

Hope it helps ^^

I had the same idea for this system before. You're actually the first one to successfully do it. Well done =P.

Don't worry about documenting it, I'll take care of that in another post I was planning for the exact same system.



None.

Aug 14 2011, 1:54 am Chia-Tyrant Post #6



Quote from Sacrieur
You're actually the first one to successfully do it. Well done =P.
Actually, it was brought to my attention that some maps were already made using that system (see strafe arena). I pretty much did that for nothing :lol:

I won't let it be a complete waste since I've made a small map around it for the contest :)



None.

Aug 30 2011, 9:19 pm Tank_7 Post #7



If you have a 2x1 and a 1x2.... and you start at the very top left of a map... Can you theoretically then place a location, and subsequently a unit... on any specific pixel of the map that you desire? I mean I know it would need alot of trigger duplication to run in a reasonable amount of time, but I just want to know if its possible. (Acknowledging ofcourse like... you cant place right on the edge, you must be "Unit Width / 2" and "Unit Height / 2" away)

EDIT: To clarify I mean... counting off two death counts, one representing "X" and the other "Y"... and You re-center these 2x1, 1x2, and a 1x1 location once per each Death of X and each Death of Y respectively, so then your map could decide to place something literally at the 1089,358 pixel for example.

Post has been edited 1 time(s), last time on Aug 30 2011, 9:30 pm by Tank_7.



None.

Aug 30 2011, 10:09 pm Sacrieur Post #8

Still Napping

Quote from Tank_7
If you have a 2x1 and a 1x2.... and you start at the very top left of a map... Can you theoretically then place a location, and subsequently a unit... on any specific pixel of the map that you desire? I mean I know it would need alot of trigger duplication to run in a reasonable amount of time, but I just want to know if its possible. (Acknowledging ofcourse like... you cant place right on the edge, you must be "Unit Width / 2" and "Unit Height / 2" away)

EDIT: To clarify I mean... counting off two death counts, one representing "X" and the other "Y"... and You re-center these 2x1, 1x2, and a 1x1 location once per each Death of X and each Death of Y respectively, so then your map could decide to place something literally at the 1089,358 pixel for example.

No, you cannot drag locations along a map by skewing. It's not that the location centers off-center, it's that the location's center is off-center.



None.

Nov 9 2011, 2:28 pm MetalGear Post #9



I've done a lot of playing around with mobile grid systems, and I've experienced this problem before. You can easily see when units get spawned out of place even if it's just 1 pixel. However, I'm quite sure that I found a way around it. I will dig through my files later and report back if I'm correct about this.



None.

Nov 9 2011, 4:17 pm Oh_Man Post #10

Find Me On Discord (Brood War UMS Community & Staredit Network)

GJ posting this.




Nov 9 2011, 6:03 pm samsizzle Post #11



Someone wanna upload chia's map? The file on his post isn't working. I'd really like to see it.



None.

Nov 9 2011, 9:20 pm MetalGear Post #12



It really helps knowing the exact unit sizes as well because you can modify your location layers to suit the exact unit measurements. Just a tip guys, don't go by the wiki unit measurements; though they are somewhat close, they are not completely accurate. The best thing to do is to create a map with inverted locations and manually figure out the sizes. That way you can create a perfectly responsive system.



None.

Nov 9 2011, 9:58 pm Oh_Man Post #13

Find Me On Discord (Brood War UMS Community & Staredit Network)

Get in donuts Sam!!




Sep 21 2012, 11:45 pm jjf28 Post #14

Cartography Artisan

Content for OP:

Even Sized Location + Fixed, Odd Sized Location = Even Sized Location Skews Down and Right


Odd Sized Location + Fixed, Even Sized Location = Odd Sized Location Skews Up and Left


Even Sized Location + Fixed, Unit's Center = Even Sized Location Skews Down and Right


Unit's Center + Fixed, Even Sized Location = Unit's Center Skews Up and Left


Post has been edited 1 time(s), last time on Sep 21 2012, 11:51 pm by jjf28.



TheNitesWhoSay - Clan Aura - github

Reached the top of StarCraft theory crafting 2:12 AM CST, August 2nd, 2014.

Sep 30 2012, 2:23 am rockz Post #15

ᴄʜᴇᴇsᴇ ɪᴛ!

Quote from MetalGear
It really helps knowing the exact unit sizes as well because you can modify your location layers to suit the exact unit measurements. Just a tip guys, don't go by the wiki unit measurements; though they are somewhat close, they are not completely accurate. The best thing to do is to create a map with inverted locations and manually figure out the sizes. That way you can create a perfectly responsive system.
The wiki measurements are perfect.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[2024-4-14. : 9:21 pm]
O)FaRTy1billion[MM] -- there are some real members mixed in those latter pages, but the *vast* majority are spam accounts
[2024-4-14. : 9:21 pm]
O)FaRTy1billion[MM] -- there are almost 3k pages
[2024-4-14. : 9:21 pm]
O)FaRTy1billion[MM] -- the real members stop around page 250
[2024-4-14. : 9:20 pm]
O)FaRTy1billion[MM] -- look at the members list
[2024-4-12. : 12:52 pm]
Oh_Man -- da real donwano
da real donwano shouted: This is the first time I've seen spam bots like this on SEN. But then again, for the last 15 years I haven't been very active.
it's pretty common
[2024-4-11. : 9:53 pm]
da real donwano -- This is the first time I've seen spam bots like this on SEN. But then again, for the last 15 years I haven't been very active.
[2024-4-11. : 4:18 pm]
IlyaSnopchenko -- still better than "Pakistani hookers in Sharjah" that I've seen advertised in another forum
[2024-4-11. : 4:07 pm]
Ultraviolet -- These guys are hella persistent
[2024-4-11. : 3:29 pm]
Vrael -- You know, the outdoors is overrated. Got any indoor gym and fitness equipment?
[2024-4-10. : 8:11 am]
Sylph-Of-Space -- Hello!
Please log in to shout.


Members Online: Roy, jun3hong