• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 16:44
CEST 22:44
KST 05:44
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
Tournament Spotlight: FEL Cracow 20259Power Rank - Esports World Cup 202577RSL Season 1 - Final Week9[ASL19] Finals Recap: Standing Tall15HomeStory Cup 27 - Info & Preview18
Community News
EWC 2025 - Replay Pack0Google Play ASL (Season 20) Announced25BSL Team Wars - Bonyth, Dewalt, Hawk & Sziky teams10Weekly Cups (July 14-20): Final Check-up0Esports World Cup 2025 - Brackets Revealed19
StarCraft 2
General
EWC 2025 - Replay Pack #1: Maru - Greatest Players of All Time Tournament Spotlight: FEL Cracow 2025 Power Rank - Esports World Cup 2025 I offer completely free coaching services
Tourneys
FEL Cracov 2025 (July 27) - $10,000 live event Esports World Cup 2025 $25,000 Streamerzone StarCraft Pro Series announced $5,000 WardiTV Summer Championship 2025 WardiTV Mondays
Strategy
How did i lose this ZvP, whats the proper response
Custom Maps
External Content
Mutation # 484 Magnetic Pull Mutation #239 Bad Weather Mutation # 483 Kill Bot Wars Mutation # 482 Wheel of Misfortune
Brood War
General
Google Play ASL (Season 20) Announced [Update] ShieldBattery: 2025 Redesign Dewalt's Show Matches in China BGH Auto Balance -> http://bghmmr.eu/ BW General Discussion
Tourneys
[Megathread] Daily Proleagues [BSL20] Non-Korean Championship 4x BSL + 4x China CSL Xiamen International Invitational [CSLPRO] It's CSLAN Season! - Last Chance
Strategy
Simple Questions, Simple Answers [G] Mineral Boosting Does 1 second matter in StarCraft?
Other Games
General Games
Stormgate/Frost Giant Megathread Nintendo Switch Thread Total Annihilation Server - TAForever [MMORPG] Tree of Savior (Successor of Ragnarok) Path of Exile
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
UK Politics Mega-thread US Politics Mega-thread Stop Killing Games - European Citizens Initiative Things Aren’t Peaceful in Palestine Russo-Ukrainian War Thread
Fan Clubs
INnoVation Fan Club SKT1 Classic Fan Club!
Media & Entertainment
Anime Discussion Thread [\m/] Heavy Metal Thread Movie Discussion! [Manga] One Piece Korean Music Discussion
Sports
2024 - 2025 Football Thread Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023 NBA General Discussion
World Cup 2022
Tech Support
Installation of Windows 10 suck at "just a moment" Computer Build, Upgrade & Buying Resource Thread
TL Community
TeamLiquid Team Shirt On Sale The Automated Ban List
Blogs
Ping To Win? Pings And Their…
TrAiDoS
momentary artworks from des…
tankgirl
from making sc maps to makin…
Husyelt
StarCraft improvement
iopq
Socialism Anyone?
GreenHorizons
Eight Anniversary as a TL…
Mizenhauer
Customize Sidebar...

Website Feedback

Closed Threads



Active: 695 users

Defusion by terrain – interesting Mine behaviour

Forum Index > Brood War Strategy
Post a Reply
Normal
Freakling
Profile Joined October 2012
Germany1529 Posts
Last Edited: 2021-02-27 11:15:58
February 21 2021 17:00 GMT
#1
This clip was brought up on the NHFFA discord, together with the question: "Why was there no damage here?"


The answer, it turns out, is rather interesting, courtesy of tscmoo:

tscmoo on SSCAIT discord wrote:
spider mines explode through the "castspell" iscript opcode, this leads to this check https://github.com/OpenBW/openbw/blob/master/bwgame.h#L14942 and then this spider mine specific check https://github.com/OpenBW/openbw/blob/master/bwgame.h#L14610 which, because of this line https://github.com/OpenBW/openbw/blob/master/bwgame.h#L5656, checks if the spider mine itself is on walkable terrain. if the spider mine is not on walkable terrain, then it does not deal any damage

bw pathfinding being what it is, put the spider mine on unwalkable terrain the moment it got in range
also slightly worth noting that this walkability test is buildtile/megatile resolution, so effectively it checks if more than 12 minitiles within that are are walkable
in that regard, the bw pathfinding might not be doing anything wrong here, it's just a resolution issue with the walkability test.


To add some more background to that:
  • Each terrain tile is made up of 4×4 minitiles, which are either walkable or unwalkable.
  • At game-start the game classifies each tile with at least 4 unwalkable minitiles as unwalkable, all other tiles as walkable.
  • Whether a ground unit can occupy a location depends solely on the minitile walkability property.
  • The tile the mine from the clip detonates on has 8/16 unwalkable minitiles and is thus classified as an unwalkable tile, which makes the Mine dud out.


Conclusion: Near unwalkable terrain, such as cliff edges, in particularlyin tight chokes, or doodads, there is a certain chance that Mine damage will be completely mitigated.

EDIT: Here's the whole situation recreated in ScmDraft with overlays showing the relevant walkabily properties:
+ Show Spoiler [Show animation] +
[image loading]


EDIT2: Thanks to StaticNine for another video demonstrating the effect. Note that the video title does not explain the conditions and cause of the effect correctly:
+ Show Spoiler [show video] +
kogeT
Profile Joined September 2013
Poland2037 Posts
February 21 2021 17:36 GMT
#2
Just another argument for PvT imba. :D
https://www.twitch.tv/kogetbw
Highgamer
Profile Joined October 2015
1407 Posts
February 21 2021 19:56 GMT
#3
And they complain about goon AI...
EMPaThy789
Profile Joined July 2009
New Zealand878 Posts
February 22 2021 02:54 GMT
#4
Time to lose all my dragoons trying to abuse this in a game.
FlaShFTW
Profile Blog Joined February 2010
United States10154 Posts
February 22 2021 03:22 GMT
#5
I love how this one clip is getting so much traction. My goon is a hero now, and his tale will be echoed throughout Auir.
Writer#1 KT and FlaSh Fanboy || Woo Jung Ho Never Forget || Teamliquid Political Decision Desk
TL+ Member
ggsimida
Profile Joined August 2015
1148 Posts
Last Edited: 2021-02-22 06:01:36
February 22 2021 06:01 GMT
#6
what an intriguing 20+ yr old game

thx for sharing
Freakling
Profile Joined October 2012
Germany1529 Posts
February 22 2021 10:13 GMT
#7
On February 22 2021 12:22 FlaShFTW wrote:
I love how this one clip is getting so much traction. My goon is a hero now, and his tale will be echoed throughout Auir.

Wait till Bisu finds out – and perfects his cliff-hugging technique
MeSaber
Profile Joined December 2009
Sweden1235 Posts
February 22 2021 13:35 GMT
#8
Cool and all, my question then is how do i know where the unwalkable terrain is? Is it randomized on game start or in map editor?

No way of knowing?
-.-
Freakling
Profile Joined October 2012
Germany1529 Posts
February 22 2021 14:26 GMT
#9
If you want to know for sure, the easiest way it to open the map in ScmDraft:
[image loading]
Highgamer
Profile Joined October 2015
1407 Posts
February 22 2021 14:58 GMT
#10
Jeez, no wonder stuff gets stuck on ramps sometimes...
Freakling
Profile Joined October 2012
Germany1529 Posts
February 22 2021 15:04 GMT
#11
The red is unwalkable tiles. As I explained where stuff can go is determined on the minitile level, which is the grey overlay.
As far as this topic is concerned: Grey prohibits movement, red makes Mines dud.
Highgamer
Profile Joined October 2015
1407 Posts
Last Edited: 2021-02-22 19:12:19
February 22 2021 19:10 GMT
#12
Just one quick question: What exactly do you mean by "grey prohibits movement"?

From your explanation above - 'ground units can occupy walkable mini-tiles' - I had the impression that units can walk/move on walkable mini-tiles, despite the whole tile being classified as unwalkable. Maybe only by patch-finding accident, but isn't that what the mine in the video did, no?

Or did you mean: "Normally units won't step on walkable mini-tiles if the whole tile is unwalkable"?
Are units being pushed off of a walkable mini-tile (in an unwalkable whole-tile) should they accidentally move onto it?

Thx in advance.
Freakling
Profile Joined October 2012
Germany1529 Posts
Last Edited: 2021-02-22 20:28:46
February 22 2021 20:25 GMT
#13
Units can occupy any walkable space they can fit in. But if the tile is flagged unwalkable any mine explosions on it will be duds. The mine can move onto the tile because it is partly walkable (has walkable minitiles), but doesn't deal damage because the whole tile is flagged as unwalkable.

Or, to be very technical about it:
  • A ground unit's collision box may not overlap with any unwalkable minitiles
  • If a ground unit overlaps with unwalkable terrain it will be force-moved to the "nearest" (according to the game's idea of nearest…) walkable area (this just as a side note, it is not relevant for the effect discussed in this thread).
  • The centre of the collision box (rounded up coordinates) is the actual unit position, which is what is checked to determine the terrain flag checks for the unit.


Maybe it's not quite clear what I mean with grey, because the grey overlay actually looks dark red under the red overlay… Can you see that there are two overlays visible on that image, the darker one with 4× the resolution of the other? Maybe I should make a gif…
Highgamer
Profile Joined October 2015
1407 Posts
Last Edited: 2021-02-23 09:57:55
February 23 2021 09:52 GMT
#14
Thx Freakling, it's all cleared up now that you mentioned that the grey overlay is where it's deep red.

I think you're fine if you maybe just use the terms "deep red/light red" instead of "grey/red" in your above post.

Other than that, precise in-depth BW-knowledge as always.
Freakling
Profile Joined October 2012
Germany1529 Posts
February 23 2021 10:10 GMT
#15
I added an animation to the OP that shows the terrain analysis step by step.
MeSaber
Profile Joined December 2009
Sweden1235 Posts
February 23 2021 18:40 GMT
#16
Nice!
-.-
Dangermousecatdog
Profile Joined December 2010
United Kingdom7084 Posts
Last Edited: 2021-02-23 20:30:27
February 23 2021 20:13 GMT
#17
So there are mini-tiles that are either walkable or unwalkable, but a tile as a whole is either flagged as walkable or unwalkable? Are there any other circumstance where a whole tile being flagged walkable or unwalkable matters? Other than building placment presumably. Scarab duds too due to this perhaps?

I guess with this info the best way to make a spider mine dud is make it hit a unit on the sides of a ramp or throw your unit to a corner and hope for the best.
Freakling
Profile Joined October 2012
Germany1529 Posts
Last Edited: 2021-02-25 20:13:14
February 24 2021 10:15 GMT
#18
On February 24 2021 05:13 Dangermousecatdog wrote:
So there are mini-tiles that are either walkable or unwalkable, but a tile as a whole is either flagged as walkable or unwalkable? Are there any other circumstance where a whole tile being flagged walkable or unwalkable matters? Other than building placment presumably.
Pathfinding regions are generated and connected based on the walkability and terrain level tile flags (both generated from the respective minitile flags at game-start), so indirectly they have a huge bearing on long-range pathfinding and a plethora of associated behaviours.

Buildability is only determined by the buildability flag, a game-generated "partially walkable" flag (which is set as soon as one minitile of a tile in unwlkable) and a creep flag for Zerg (there are some special cases regarding partially unwalkable, but buildable tiles).
Creep spread is only determined by the buildability flag though (and has some unintended buggy interaction with a deprecated "flipped doodad sprite" flag).

Scarab duds too due to this perhaps?
Read the quote from the OP, follow the references! The relevant flag check is specifically hardcoded for Mines only.
Scarabs dud due to timeout, when they cannot reach their target due to other units blocking the way, or when the Reaver owner aborts the attack (gives the Reaver a stop order).

I guess with this info the best way to make a spider mine dud is make it hit a unit on the sides of a ramp or throw your unit to a corner and hope for the best.
Something like this. In practice it is situationally useful to know and somewhat luck based, I guess.
Freakling
Profile Joined October 2012
Germany1529 Posts
Last Edited: 2021-02-25 20:10:40
February 24 2021 10:20 GMT
#19
double post, delete please
Dangermousecatdog
Profile Joined December 2010
United Kingdom7084 Posts
Last Edited: 2021-02-25 20:51:16
February 25 2021 20:50 GMT
#20
Thanks Freakling, for the informative answers.
SirGlinG
Profile Blog Joined January 2008
Sweden933 Posts
February 25 2021 22:56 GMT
#21
On February 22 2021 23:26 Freakling wrote:
If you want to know for sure, the easiest way it to open the map in ScmDraft:
[image loading]

Is this unwalkable area on the ramp the reason why Reavers often bug out, start walking instead of shooting at stuff when they're at a ramp?
Not my chair. Not my problem. That's what I say
Freakling
Profile Joined October 2012
Germany1529 Posts
Last Edited: 2021-02-26 11:10:22
February 26 2021 11:04 GMT
#22
Only very indirectly. The reason for Reaver jams is a bad pathfinding region layout. Because Scarabs are ground units Reavers use pathfinding distances instead of normal distances to determine their attack range. Pahfinding distances across three or more regions are measured over the nodes of the intervening regions, so if the nodes are far off the shortest path the effective attack distance will be severely shortened.
StaticNine
Profile Blog Joined March 2017
27 Posts
February 27 2021 00:42 GMT
#23
Interesting. Also, there a bunch of doodad's that give 100% invulnerability to spider man damage if the spidermine approaches from the south. Here is a video showing it:

https://www.youtube.com/watch?v=yMstR5bC9vs
Freakling
Profile Joined October 2012
Germany1529 Posts
February 27 2021 11:11 GMT
#24
It's not the direction of approach though but of where the Mines explode, right next to the doodad where tiles are flagged as unwalkable. If you flipped Marine and Mine positions in this setup you'd get the same result.

But it's a nice, instructive video. I'll link it in the OP.
Normal
Please log in or register to reply.
Live Events Refresh
BSL20 Non-Korean Champi…
18:00
RO8 Round Robin Group - Day 4
Bonyth vs Zhanhun
Dewalt vs Mihu
Hawk vs Sziky
Sziky vs QiaoGege
Mihu vs Hawk
Zhanhun vs Dewalt
Fengzi vs Bonyth
ZZZero.O221
LiquipediaDiscussion
FEL
09:00
Cracow 2025
Clem vs LamboLIVE!
Reynor vs TBD
RotterdaM2689
ComeBackTV 2487
IndyStarCraft 693
WardiTV439
3DClanTV 189
CranKy Ducklings187
EnkiAlexander 136
Rex69
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
RotterdaM 2689
IndyStarCraft 693
Rex 69
StarCraft: Brood War
ZZZero.O 221
NaDa 10
Dota 2
capcasts332
LuMiX2
League of Legends
JimRising 297
febbydoto13
Counter-Strike
fl0m2991
Fnx 2254
Stewie2K749
flusha450
Super Smash Bros
hungrybox1947
Mew2King1852
AZ_Axe324
Westballz18
Heroes of the Storm
Liquid`Hasu612
Khaldor390
Other Games
Grubby2925
B2W.Neo937
tarik_tv583
mouzStarbuck139
Sick29
Organizations
Other Games
gamesdonequick3129
StarCraft 2
angryscii 20
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 19 non-featured ]
StarCraft 2
• davetesta26
• LUISG 18
• Adnapsc2 6
• intothetv
• IndyKCrew
• sooper7s
• Migwel
• AfreecaTV YouTube
• LaughNgamezSOOP
• Kozan
StarCraft: Brood War
• Azhi_Dahaki32
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• masondota22135
• WagamamaTV925
League of Legends
• Doublelift4792
Other Games
• imaqtpie1674
• Shiphtur516
Upcoming Events
Wardi Open
14h 16m
Sparkling Tuna Cup
1d 13h
WardiTV European League
1d 19h
Online Event
1d 20h
uThermal 2v2 Circuit
2 days
The PondCast
3 days
Replay Cast
4 days
Korean StarCraft League
5 days
CranKy Ducklings
5 days
Sparkling Tuna Cup
6 days
Liquipedia Results

Completed

CSLPRO Last Chance 2025
Esports World Cup 2025
Murky Cup #2

Ongoing

Copa Latinoamericana 4
Jiahua Invitational
BSL 20 Non-Korean Championship
BSL 20 Team Wars
FEL Cracov 2025
CC Div. A S7
Underdog Cup #2
IEM Cologne 2025
FISSURE Playground #1
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025
PGL Astana 2025
Asian Champions League '25

Upcoming

ASL Season 20: Qualifier #1
ASL Season 20: Qualifier #2
ASL Season 20
CSLPRO Chat StarLAN 3
BSL Season 21
RSL Revival: Season 2
Maestros of the Game
SEL Season 2 Championship
WardiTV Summer 2025
uThermal 2v2 Main Event
HCC Europe
ESL Pro League S22
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.