• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 17:51
CEST 23:51
KST 06:51
  • 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
[ASL21] Ro4 Preview: On Course12Code S Season 1 - RO8 Preview7[ASL21] Ro8 Preview Pt2: Progenitors8Code S Season 1 - RO12 Group A: Rogue, Percival, Solar, Zoun13[ASL21] Ro8 Preview Pt1: Inheritors16
Community News
Code S Season 1 (2026) - RO8 Results1Weekly Cups (May 4-10): Clem, MaxPax, herO win1Maestros of The Game 2 announcement and schedule !11Weekly Cups (April 27-May 4): Clem takes triple0RSL Revival: Season 5 - Qualifiers and Main Event12
StarCraft 2
General
Code S Season 1 (2026) - RO8 Results MaNa leaves Team Liquid Weekly Cups (May 4-10): Clem, MaxPax, herO win Code S Season 1 - RO8 Preview Behind the Blue - Team Liquid History Book
Tourneys
2026 GSL Season 2 Qualifiers Maestros of The Game 2 announcement and schedule ! $5,000 WardiTV Spring Championship 2026 SC2 INu's Battles#16 <BO.9> Master Swan Open (Global Bronze-Master 2)
Strategy
Custom Maps
[D]RTS in all its shapes and glory <3 [A] Nemrods 1/4 players
External Content
Mutation # 525 Wheel of Misfortune The PondCast: SC2 News & Results Mutation # 524 Death and Taxes Mutation # 523 Firewall
Brood War
General
ASL21 Strategy, Pimpest Plays Discussions vespene.gg — BW replays in browser Flashes ASL S21 Ro8 Review Pros React to: TvT Masterclass in FlaSh vs Light BGH Auto Balance -> http://bghmmr.eu/
Tourneys
[ASL21] Semifinals B [BSL22] RO8 Bracket Stage + Another TieBreaker Small VOD Thread 2.0 [Megathread] Daily Proleagues
Strategy
Fighting Spirit mining rates [G] Hydra ZvZ: An Introduction Simple Questions, Simple Answers Muta micro map competition
Other Games
General Games
Stormgate/Frost Giant Megathread Nintendo Switch Thread Warcraft III: The Frozen Throne Starcraft Tabletop Miniature Game PC Games Sales Thread
Dota 2
The Story of Wings Gaming
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
Vanilla Mini Mafia Mafia Game Mode Feedback/Ideas TL Mafia Community Thread Five o'clock TL Mafia
Community
General
US Politics Mega-thread Russo-Ukrainian War Thread UK Politics Mega-thread YouTube Thread European Politico-economics QA Mega-thread
Fan Clubs
The IdrA Fan Club
Media & Entertainment
[Manga] One Piece Anime Discussion Thread [Req][Books] Good Fantasy/SciFi books
Sports
2024 - 2026 Football Thread McBoner: A hockey love story Formula 1 Discussion
World Cup 2022
Tech Support
streaming software Strange computer issues (software) [G] How to Block Livestream Ads
TL Community
The Automated Ban List
Blogs
How EEG Data Can Predict Gam…
TrAiDoS
ramps on octagon
StaticNine
Funny Nicknames
LUCKY_NOOB
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1960 users

s2prot: Command line app to parse SC2Replay files

Forum Index > SC2 General
Post a Reply
Dakota_Fanning *
Profile Joined January 2008
Hungary2368 Posts
Last Edited: 2017-05-22 15:05:31
May 22 2017 14:29 GMT
#1
I've created and open-sourced a command line StarCraft II replay parser tool called s2prot here:

https://github.com/icza/s2prot

What it is

It's a standalone app with no GUI, and it can be used from the command line to pass a StarCraft II replay file to it (.SC2Replay), and it will parse the file and display low-level information from the replay in textual, JSON representation.

Target audience

While anyone may download it and use it, the information it presents is quite low level. It is human readable (JSON), but it's primarily intended for developers and web sites that wish to extract data from replays.

Supported platforms

Pre-built binary releases are provided for Windows, Linux and MAC OS X, both for 32 and 64-bit architectures.

Note that the project is written using the Go language, which supports a lot more platforms. Should you need to use it on other platforms, you can checkout the source code and compile it on your platform.

Requirements

Nothing is required. s2prot is shipped as a single, self-contained executable binary. It has no dependency. You do not need anything installed on your system. You just download the binary for your platform, extract it and use it.

Supported replay versions

Parses all versions (up to 3.14) that were written with retail versions of StarCraft II (and some beta versions too).

Download

Pre-built binaries can be downloaded from:

https://github.com/icza/s2prot/releases

Feedback / Bug report

Feedback and bug report is welcome. Feedback may be posted here, bugs and issues should be reported at:

https://github.com/icza/s2prot/issues

Star / Follow the project

If you like the project, please star it / watch it / follow me on github. Thanks.



Also check out the sister project to parse StarCraft: Brood War replays: screp
https://repmastered.icza.net
feardragon
Profile Blog Joined October 2010
United States973 Posts
May 22 2017 15:30 GMT
#2
Yessss! Thank you for this. This is the push I needed to start playing around with replays more.
Ok Starcraft 2 Commentator
loginn
Profile Blog Joined January 2011
France815 Posts
May 22 2017 17:58 GMT
#3
Is this mainly a port of the s2protocol in Go ?
Loading a bunch of replays and processing them concurrently is very nice in any case.
Nice job
Stephano, Taking skill to the bank since IPL3. Also Lucifron and FBH
Dakota_Fanning *
Profile Joined January 2008
Hungary2368 Posts
Last Edited: 2017-05-22 18:04:37
May 22 2017 18:02 GMT
#4
On May 23 2017 02:58 loginn wrote:
Is this mainly a port of the s2protocol in Go ?
Loading a bunch of replays and processing them concurrently is very nice in any case.
Nice job

Yes, it is based on s2protocol, but everything is written in Go (s2protocol requires python). I also wrote the MPQ parser required by s2protocol in Go, made available as a separate open-source project: https://github.com/icza/mpq
https://repmastered.icza.net
Haighstrom
Profile Joined March 2011
United Kingdom207 Posts
May 22 2017 18:27 GMT
#5
Is the format spec for the replay files publicly available? I'm interested in developing my own parsing tool in C#.
Dakota_Fanning *
Profile Joined January 2008
Hungary2368 Posts
May 22 2017 19:33 GMT
#6
On May 23 2017 03:27 Haighstrom wrote:
Is the format spec for the replay files publicly available? I'm interested in developing my own parsing tool in C#.

There is no public doc available, the closest you can get is the s2protocol reference implementation.
https://repmastered.icza.net
FightingFrog
Profile Blog Joined September 2013
Sweden30 Posts
July 18 2017 15:29 GMT
#7
Hi again,

Thank you for redirecting me here from Scelight thread, this is exactly what I wanted!

I have a few questions:

1. Is there any information that that will allow me to distinguish between two players with identical name? If not, do you know if that information even exist in the replay?

2. Is it possible to see when units take damage/use spells/location at a given time? (other than when they are created/destroyed)
Dakota_Fanning *
Profile Joined January 2008
Hungary2368 Posts
July 19 2017 08:22 GMT
#8
On July 19 2017 00:29 FightingFrog wrote:
Hi again,

Thank you for redirecting me here from Scelight thread, this is exactly what I wanted!

I have a few questions:

1. Is there any information that that will allow me to distinguish between two players with identical name? If not, do you know if that information even exist in the replay?

2. Is it possible to see when units take damage/use spells/location at a given time? (other than when they are created/destroyed)

1. There is a universally unique identifier for all players, this is called the toon. The toon is recorded in multiple parts of the replay, for example in the Details section, Players array, Toon field. It contains the program ID ("S2" for StarCraft II), region ID, realm ID, and player ID.

2. Units taking damage is not recorded. Spell usage and location is recorded, this is in the Game events section.
https://repmastered.icza.net
Dakota_Fanning *
Profile Joined January 2008
Hungary2368 Posts
July 19 2017 08:38 GMT
#9
Btw I just released a new version v1.1.0 of s2prot, please do download the new version if you plan to play / experiment with it. It also adds support for replays up to 3.16.

New v1.1.0 version available for downloading here:

https://github.com/icza/s2prot/releases/tag/v1.1.0
https://repmastered.icza.net
Please log in or register to reply.
Live Events Refresh
Next event in 2h 9m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
PiGStarcraft176
JuggernautJason99
CosmosSc2 48
StarCraft: Brood War
Britney 14422
Artosis 318
Aegong 54
NaDa 8
Dota 2
monkeys_forever313
NeuroSwarm86
League of Legends
summit1g6005
Doublelift4992
Counter-Strike
Fnx 1760
Other Games
gofns13008
tarik_tv8187
Grubby5046
Liquid`RaSZi1543
FrodaN1336
Liquid`Hasu190
C9.Mang0186
ArmadaUGS119
UpATreeSC69
Livibee54
ViBE28
Organizations
Other Games
BasetradeTV56
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
[ Show 22 non-featured ]
StarCraft 2
• Hupsaiya 71
• musti20045 33
• Reevou 8
• Kozan
• IndyKCrew
• sooper7s
• AfreecaTV YouTube
• Migwel
• intothetv
• LaughNgamezSOOP
StarCraft: Brood War
• blackmanpl 51
• HerbMon 18
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• masondota2849
• lizZardDota260
Other Games
• imaqtpie1290
• Shiphtur353
• WagamamaTV186
• Scarra53
• tFFMrPink 10
Upcoming Events
Replay Cast
2h 9m
RSL Revival
12h 9m
Classic vs Solar
herO vs SHIN
OSC
15h 9m
Big Brain Bouts
18h 9m
sebesdes vs Iba
Percival vs YoungYakov
Reynor vs GgMaChine
Korean StarCraft League
1d 5h
RSL Revival
1d 12h
Clem vs Rogue
Bunny vs Lambo
IPSL
1d 18h
Dewalt vs nOmaD
Ret vs Cross
BSL
1d 21h
Bonyth vs Doodle
Dewalt vs TerrOr
GSL
2 days
Cure vs herO
SHIN vs Maru
IPSL
2 days
Bonyth vs Napoleon
G5 vs JDConan
[ Show More ]
BSL
2 days
OyAji vs JDConan
DragOn vs TBD
Replay Cast
3 days
Monday Night Weeklies
3 days
Replay Cast
4 days
The PondCast
4 days
GSL
5 days
Replay Cast
6 days
GSL
6 days
Liquipedia Results

Completed

Proleague 2026-05-13
WardiTV TLMC #16
Nations Cup 2026

Ongoing

BSL Season 22
ASL Season 21
IPSL Spring 2026
KCM Race Survival 2026 Season 2
Acropolis #4
KK 2v2 League Season 1
BSL 22 Non-Korean Championship
SCTL 2026 Spring
RSL Revival: Season 5
2026 GSL S1
Heroes Pulsing #1
Asian Champions League 2026
IEM Atlanta 2026
PGL Astana 2026
BLAST Rivals Spring 2026
IEM Rio 2026
PGL Bucharest 2026
Stake Ranked Episode 1
BLAST Open Spring 2026
ESL Pro League S23 Finals
ESL Pro League S23 Stage 1&2

Upcoming

Escore Tournament S2: W7
YSL S3
Escore Tournament S2: W8
CSLAN 4
Kung Fu Cup 2026 Grand Finals
HSC XXIX
uThermal 2v2 2026 Main Event
Maestros of the Game 2
WardiTV Spring 2026
2026 GSL S2
BLAST Bounty Summer Qual
Stake Ranked Episode 3
XSE Pro League 2026
IEM Cologne Major 2026
Stake Ranked Episode 2
CS Asia Championships 2026
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 © 2026 TLnet. All Rights Reserved.