• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 20:32
CET 01:32
KST 09:32
  • 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
[ASL20] Finals Preview: Arrival13TL.net Map Contest #21: Voting10[ASL20] Ro4 Preview: Descent11Team TLMC #5: Winners Announced!3[ASL20] Ro8 Preview Pt2: Holding On9
Community News
Weekly Cups (Oct 20-26): MaxPax, Clem, Creator win42025 RSL Offline Finals Dates + Ticket Sales!9BSL21 Open Qualifiers Week & CONFIRM PARTICIPATION1Crank Gathers Season 2: SC II Pro Teams10Merivale 8 Open - LAN - Stellar Fest3
StarCraft 2
General
Weekly Cups (Oct 20-26): MaxPax, Clem, Creator win Could we add "Avoid Matchup" Feature for rankgame RotterdaM "Serral is the GOAT, and it's not close" The New Patch Killed Mech! Chinese SC2 server to reopen; live all-star event in Hangzhou
Tourneys
Crank Gathers Season 2: SC II Pro Teams 2025 RSL Offline Finals Dates + Ticket Sales! Merivale 8 Open - LAN - Stellar Fest $5,000+ WardiTV 2025 Championship $3,500 WardiTV Korean Royale S4
Strategy
Custom Maps
Map Editor closed ?
External Content
Mutation # 497 Battle Haredened Mutation # 496 Endless Infection Mutation # 495 Rest In Peace Mutation # 494 Unstable Environment
Brood War
General
BW General Discussion BSL Team A vs Koreans - Sat-Sun 16:00 CET Ladder Map Matchup Stats [ASL20] Ask the mapmakers — Drop your questions BGH Auto Balance -> http://bghmmr.eu/
Tourneys
[ASL20] Grand Finals The Casual Games of the Week Thread BSL21 Open Qualifiers Week & CONFIRM PARTICIPATION ASL final tickets help
Strategy
How to stay on top of macro? PvZ map balance Soma's 9 hatch build from ASL Game 2 Current Meta
Other Games
General Games
Stormgate/Frost Giant Megathread General RTS Discussion Thread Path of Exile Nintendo Switch Thread Dawn of War IV
Dota 2
Official 'what is Dota anymore' discussion LiquidDota to reintegrate into TL.net
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
TL Mafia Community Thread SPIRED by.ASL Mafia {211640}
Community
General
Things Aren’t Peaceful in Palestine US Politics Mega-thread Russo-Ukrainian War Thread YouTube Thread The Chess Thread
Fan Clubs
White-Ra Fan Club The herO Fan Club!
Media & Entertainment
Anime Discussion Thread Movie Discussion! [Manga] One Piece Korean Music Discussion Series you have seen recently...
Sports
MLB/Baseball 2023 2024 - 2026 Football Thread Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023 NBA General Discussion
World Cup 2022
Tech Support
SC2 Client Relocalization [Change SC2 Language] Linksys AE2500 USB WIFI keeps disconnecting Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List Recent Gifted Posts
Blogs
Analysis of the Trump-Lee S…
Peanutsc
Reality "theory" prov…
perfectspheres
The Benefits Of Limited Comm…
TrAiDoS
Our Last Hope in th…
KrillinFromwales
Certified Crazy
Hildegard
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1281 users

Personal XSplit Scene Switcher

Blogs > zhurai
Post a Reply
zhurai
Profile Blog Joined September 2010
United States5660 Posts
Last Edited: 2012-09-01 21:48:33
September 01 2012 21:25 GMT
#1
Ah I already posted it on my personal blog (http://zhurai.com/139-xsplit-scene-switcher-version-1-0/) but I felt it's also relevant to the people here on Teamliquid (because of Streaming)

Reasoning/whatever

Ok so to start, I should say this was done as a proof of concept for myself, as well as a (probably bad) tool to push myself to actually learn the language (Python). Also it's to fill in a hole that I needed filled (cause I'm lazy) to switch the scene for more programs than just SC2 and LoL (such as using R1CH's or HellGreen's programs)

I also didn't want to learn .NET as I don't like it, and prefer to learn languages that can be run on (roughly) all the systems (and C/C++ memory stuff makes my brain hurt)

This should work for all (Windows) Systems, but I'm not sure. I know it works on Windows 7 64 bit at least..

(I'll probably update this less frequently... check site for the more/most up to date source code)
(downloads once I have exe files would be updated here probably more frequently however)

Currently Detects (and somewhat acts upon)
- Guild Wars 2
- SC2 Menu
- SC2 "In Game"
- Desktop
- Xsplit Broadcaster (live and not) - ignores it however
- (at least) windows 7 alt tab functionability ("Task Switching") - But also ignores it
- Osu!
- BW "In Game" - Meaning Main Menu, Lobby, and when you're actually ingame ... goes back to Desktop while you're in Battle.Net chat windows
- Magic the Gathering Online (Not the crappy new beta version)

Requirements
- Python 2.7 (NOT SURE ABOUT 3.x… maybe works, maybe not)
- Auto-it
- Python for Windows extentions (for the python version, in this case, 2.7) http://sourceforge.net/projects/pywin32/files/pywin32/Build 217/
- Have both Python 2.7 and Autoit both the same bit. as in 32 bit, or 64 bit. If your computer is 64 bit, you can use either 32 or 64 bit (I’m on a 64 bit computer, but I’m using 32 bit because pygame doesn’t support 64 bit too well)

See the blog post on my site for the license text (BSD), and my important notes about the program, as well as how Xsplit's Buttons are like atm (like what's Button1, Button2, etc)

Current Source (1.0) that I have at the moment... (sorry it's messy)
--> EDIT: since the whitespace was truncated, I uploaded it to pastebin for now: http://pastebin.com/N3KEuSwN
(save it as something like "Scene Switcher.py")

Changelog
9/1: 1.0 release
(forgot what happened before cause I didn't have timestamps of what happened...)

NOTE: if you don't really know coding, I'd suggest you wait before trying to use this program for now... or rather wait until I have the program read configuration files...


Hope you all like it T_T, or at least find it interesting...

EDIT: Derp, the forum software kills the whitespace X_X, uploaded to pastebin

Twitter: @zhurai | Site: http://zhurai.com
Birdie
Profile Blog Joined August 2007
New Zealand4438 Posts
September 09 2012 08:41 GMT
#2
Would it be possible to have this trigger local recording when you're in and out of a game? That is, when a game (in BW) starts, it starts local recording, and when you end the game, it ends local recording.
Red classic | A butterfly dreamed he was Zhuangzi | 4.5k, heading to 5k as support!
zhurai
Profile Blog Joined September 2010
United States5660 Posts
September 09 2012 21:11 GMT
#3
On September 09 2012 17:41 Birdie wrote:
Would it be possible to have this trigger local recording when you're in and out of a game? That is, when a game (in BW) starts, it starts local recording, and when you end the game, it ends local recording.

hmm the problem with BW is that it doesn't have much of an indication (that I know of) that I can use to detect if it's in "ingame" or "bw menu" modes... (I assume using windowed-mode BW)

in SC2 I can detect if it's ingame or menu because of the registry changes (HKEY_CURRENT_USER\SOFTWARE\Razer\StarCraft2)

as for starting/ending local recording...it could be possible...but not via mouse clicks (because everyone has different x/y coordinates where their Xsplit is), so the best option could be to set a hotkey for start/stop local recording, and then make autoit send that...

possibly with http://www.autoitscript.com/autoit3/docs/functions/ControlSend.htm
but I'll have to test it out later for that


but I'm not sure (yet) how to determine if it's BW menu (main menu/etc)/BW lobby/BW ingame states yet


Twitter: @zhurai | Site: http://zhurai.com
Birdie
Profile Blog Joined August 2007
New Zealand4438 Posts
September 09 2012 22:05 GMT
#4
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.
Red classic | A butterfly dreamed he was Zhuangzi | 4.5k, heading to 5k as support!
CecilSunkure
Profile Blog Joined May 2010
United States2829 Posts
September 09 2012 22:15 GMT
#5
On September 10 2012 07:05 Birdie wrote:
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.

Well then mr. howdy doody, why don't you do this for him?
Birdie
Profile Blog Joined August 2007
New Zealand4438 Posts
September 09 2012 23:19 GMT
#6
On September 10 2012 07:15 CecilSunkure wrote:
Show nested quote +
On September 10 2012 07:05 Birdie wrote:
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.

Well then mr. howdy doody, why don't you do this for him?

Ohi Cecil, it's Jack from SEN :D

I don't know Python, am not very good at programming, and don't have time for the next...3-4 weeks. Otherwise I would be happy to :D after Thursday I could probably have a look for an address that works but making it trigger anything is beyond me.
Red classic | A butterfly dreamed he was Zhuangzi | 4.5k, heading to 5k as support!
zhurai
Profile Blog Joined September 2010
United States5660 Posts
Last Edited: 2012-09-10 00:17:55
September 10 2012 00:16 GMT
#7
On September 10 2012 07:05 Birdie wrote:
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.


too... time... consuming T_T

On September 10 2012 07:15 CecilSunkure wrote:
Show nested quote +
On September 10 2012 07:05 Birdie wrote:
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.

Well then mr. howdy doody, why don't you do this for him?


Cecil graces this semi programming thread with his presence o..o

On September 10 2012 08:19 Birdie wrote:
Show nested quote +
On September 10 2012 07:15 CecilSunkure wrote:
On September 10 2012 07:05 Birdie wrote:
You'd have to detect memory address changes. You can use a debugger like OllyDBG, and search for changes from when out of a game and when in a game. Keep filtering it down until one is found that's stable for every game, then detect when that byte is changed to trigger the local recording.

Well then mr. howdy doody, why don't you do this for him?

Ohi Cecil, it's Jack from SEN :D

I don't know Python, am not very good at programming, and don't have time for the next...3-4 weeks. Otherwise I would be happy to :D after Thursday I could probably have a look for an address that works but making it trigger anything is beyond me.

I barely know python.
like I said, this is my first _actual_ at all program in python anyways (I skipped hello world >> << >>) :DDDD



as for making it trigger...

I found that
1) trying to do Control+b, down (until local recording), enter...... doesn't actually do anything
2) trying to use ControlSend() function in autoit does absolutely nothing when trying to send anything to XSplit
3) the only thing that works is Send() (which technically just sends it globally to the computer from what I get?)

basically
set a hotkey in the Xsplit for Local recording/live to something that you probably won't press (such as something like Shift+Ctrl+Alt+F12 or something)
make the program send autoit the hotkey to the computer (Send() rather than ControlSend()) the hotkey ... if the address changes or whatever

using...for example
autoit.Send("!{F1}")

(Sends basically Alt + F1 to the computer, which starts the XSplit Recording)

where...
! = alt
+ = shift
^ = ctrl



hmm I really should've had it as an EXE file and released it like that I guess... judging from the lack of replies or anything D:
Twitter: @zhurai | Site: http://zhurai.com
Please log in or register to reply.
Live Events Refresh
Replay Cast
23:00
Crank Gathers S2: Playoffs D2
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
ProTech96
CosmosSc2 42
StarCraft: Brood War
Artosis 739
yabsab 36
NaDa 23
Dota 2
monkeys_forever640
NeuroSwarm48
LuMiX0
Counter-Strike
fl0m417
Foxcn196
Super Smash Bros
hungrybox1545
Other Games
summit1g11018
Grubby2799
Day[9].tv514
C9.Mang0172
Maynarde136
ViBE118
Organizations
Other Games
gamesdonequick864
BasetradeTV55
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 18 non-featured ]
StarCraft 2
• Hupsaiya 49
• musti20045 32
• davetesta22
• Kozan
• IndyKCrew
• sooper7s
• AfreecaTV YouTube
• Migwel
• intothetv
• LaughNgamezSOOP
StarCraft: Brood War
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• masondota21736
League of Legends
• Doublelift4328
• Stunt236
Other Games
• Scarra795
• Day9tv514
Upcoming Events
The PondCast
8h 28m
OSC
11h 28m
Harstem vs SKillous
Gerald vs Spirit
Krystianer vs TriGGeR
Cham vs Ryung
CrankTV Team League
12h 28m
Team Liquid vs Team Falcon
Replay Cast
1d 9h
WardiTV Invitational
1d 11h
ByuN vs Spirit
herO vs Solar
MaNa vs Gerald
Rogue vs GuMiho
Epic.LAN
1d 11h
CrankTV Team League
1d 12h
BASILISK vs TBD
Replay Cast
2 days
Epic.LAN
2 days
BSL Team A[vengers]
2 days
Dewalt vs Shine
UltrA vs ZeLoT
[ Show More ]
BSL 21
2 days
Sparkling Tuna Cup
3 days
BSL Team A[vengers]
3 days
Cross vs Motive
Sziky vs HiyA
BSL 21
3 days
Wardi Open
4 days
Monday Night Weeklies
4 days
Liquipedia Results

Completed

CSL 2025 AUTUMN (S18)
WardiTV TLMC #15
Eternal Conflict S1

Ongoing

BSL 21 Points
BSL 21 Team A
C-Race Season 1
IPSL Winter 2025-26
KCM Race Survival 2025 Season 4
SOOP Univ League 2025
CranK Gathers Season 2: SC II Pro Teams
PGL Masters Bucharest 2025
Thunderpick World Champ.
CS Asia Championships 2025
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

Upcoming

SC4ALL: Brood War
YSL S2
BSL Season 21
SLON Tour Season 2
BSL 21 Non-Korean Championship
RSL Offline Finals
WardiTV 2025
RSL Revival: Season 3
Stellar Fest
SC4ALL: StarCraft II
META Madness #9
eXTREMESLAND 2025
ESL Impact League Season 8
SL Budapest Major 2025
BLAST Rivals Fall 2025
IEM Chengdu 2025
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.