Advanced Scene Switcher

Advanced Scene Switcher 1.28.1

The “obs-zoom-mouse-advss.lua” version of that script is what Warmuptill created for me, and I worked out a way to enhance it so I could use one hotkey to zoom IN from 100% to 150%, followed by another press of the same hotkey from 150% to 200%, and so on.

Then a second hotkey press for zooming out in steps.

If anyone is interested, I can share how I did it.
 
Last edited:

Carmine Flauros

New Member
Sorry if this is a stupid question but I'm unsure how to install the plugin? I'm aware that you need to add them to the program files, but whenever I do that and then open OBS, it only shows me this error pop up:

Failed to find plug-in's 'data' directory.
Please check installation instructions!
Data most likely expected at:
C:/Program Files/obs-studio/bin/64bit/.../data/ obs-plugins/advanced-scene-switcher

I'm not sure how to fix this, and YouTube tutorials/forums typically only pick up AFTER the initial installation. Maybe I'm missing something very obvious and I apologise if I am, but I just don't know what to do. Any and all help is appreciated
 

Warmuptill

Active Member
Sorry if this is a stupid question but I'm unsure how to install the plugin? I'm aware that you need to add them to the program files, but whenever I do that and then open OBS, it only shows me this error pop up:

Failed to find plug-in's 'data' directory.
Please check installation instructions!
Data most likely expected at:
C:/Program Files/obs-studio/bin/64bit/.../data/ obs-plugins/advanced-scene-switcher

I'm not sure how to fix this, and YouTube tutorials/forums typically only pick up AFTER the initial installation. Maybe I'm missing something very obvious and I apologise if I am, but I just don't know what to do. Any and all help is appreciated
Unless there is a very specific reason that you are attempting to manually install files I would recommend running the installer instead.
So "advanced-scene-switcher-1.28.1-windows-x64-Installer.exe" for the latest release.

If this should not work let me know and I can try to guide you to install the files manually :)
 

Lycanthrope -R-

New Member
I'm afraid I may have found a glitch (or a limitation I wasn't aware of).
Adv. Scene Switcher 1.28.1
OBS 30.2.3

I have a few macros that trigger upon transitioning to certain scenes. For instance, mic on when switching to Scene X, mic off when switching to Scene Y. The thing is, it stopped acknowledging certain scenes when transitioning to them.

Advanced Scene Switcher Problem.png


Take the above screenshot. It's configured to mute the mic for this list of scenes. It works if you switch to e.g., my Loading or Break overlays, but doesn't work if you switch to e.g., my Stream Start or Intro Videos overlay despite them all being in the same list. I can check using the green flashes when the macro is working and when it's not.

It worked perfectly fine until maybe a week or 2 ago. Maybe 1.28.0 broke it.

The full list of ones I have that don't work anymore are named:
  • Stream Start Overlay
  • Intro Videos
  • Stream End Overlay
  • Black Screen
Are words like "Stream" or "Intro" considered invalid now for some reason? Or is this maybe a bug?

Thanks for any help that can be provided.
 

AaronD

Active Member
I'm afraid I may have found a glitch (or a limitation I wasn't aware of).
Adv. Scene Switcher 1.28.1
OBS 30.2.3

I have a few macros that trigger upon transitioning to certain scenes. For instance, mic on when switching to Scene X, mic off when switching to Scene Y. The thing is, it stopped acknowledging certain scenes when transitioning to them.

View attachment 109431

Take the above screenshot. It's configured to mute the mic for this list of scenes. It works if you switch to e.g., my Loading or Break overlays, but doesn't work if you switch to e.g., my Stream Start or Intro Videos overlay despite them all being in the same list. I can check using the green flashes when the macro is working and when it's not.

It worked perfectly fine until maybe a week or 2 ago. Maybe 1.28.0 broke it.

The full list of ones I have that don't work anymore are named:
  • Stream Start Overlay
  • Intro Videos
  • Stream End Overlay
  • Black Screen
Are words like "Stream" or "Intro" considered invalid now for some reason? Or is this maybe a bug?

Thanks for any help that can be provided.
You have a lot of conditions in the screenshotted macro. Enough that we can't see them all. I suspect that that's part of the problem.

Nothing wrong with having all those conditions, but you really need to know how they're evaluated. PEMDAS means nothing here. Instead, imagine that you have a bunch of open parentheses up front, and close one for each condition. Thus, the last one has the highest priority, followed by the second-to-last, and the first ones that we see here almost don't matter at all.

For example, what you've shown so far translates to:
(...((((Mic/Aux unmuted) AND Stream Start Overlay) OR Intro Videos) OR Loading Overlay) ... )

Notice where the parentheses are...

---

It's easy to program that way, behind the scenes. Just go down the list once, in order, and update a single accumulator with the immediate expression. Nothing more.
 

Lycanthrope -R-

New Member
You have a lot of conditions in the screenshotted macro. Enough that we can't see them all. I suspect that that's part of the problem.

Nothing wrong with having all those conditions, but you really need to know how they're evaluated. PEMDAS means nothing here. Instead, imagine that you have a bunch of open parentheses up front, and close one for each condition. Thus, the last one has the highest priority, followed by the second-to-last, and the first ones that we see here almost don't matter at all.
Funnily enough, this is the end result of my rearranging it seeing if I could do something to make it work. It wasn't like that originally. lol

Trust me in that it's just not recognizing certain scenes on transition. This isn't the only macro that suddenly stopped working a few weeks ago.
 

Lycanthrope -R-

New Member
The full list of ones I have that don't work anymore are named:
  • Stream Start Overlay
  • Intro Videos
  • Stream End Overlay
  • Black Screen
Further Report:
  • Renaming the scenes in question: no effect.
  • Duplicating the scenes and swapping them out in the macro: no effect.
  • Creating a brand new scene and swapping it out in the macro: now it works.
For now, I guess I'm making new scenes and copying all the sources over. Maybe those scenes became corrupted in the Advanced Scene Switchers eyes, but I don't know why that would've happened. It may still be worth investigating.
 

rtgarland

New Member
When I attempt to automatically switch profiles and start streaming, OBS crashes.
I am running on the following:
1) MAC with Sequoia 15.1.1 M1 Processor
2) OBS version 30.1.2
3) Advanced Scene Switcher version 1.28.1

Everything is update to date as of this posting. My macro is set at a certain time to switch profiles and start streaming. It is very consistent on crashing. I'm attaching the crash report.
 

Attachments

  • crash_report.txt
    310.4 KB · Views: 6

Warmuptill

Active Member
When I attempt to automatically switch profiles and start streaming, OBS crashes.
I am running on the following:
1) MAC with Sequoia 15.1.1 M1 Processor
2) OBS version 30.1.2
3) Advanced Scene Switcher version 1.28.1

Everything is update to date as of this posting. My macro is set at a certain time to switch profiles and start streaming. It is very consistent on crashing. I'm attaching the crash report.
Thanks for reporting the issue.
Unfortunately the crash log does not really provide any obvious indication what might be causing the crash.

Does it maybe help if you add a "wait" action in between the "Profile" and the "Streaming" action?
 

rtgarland

New Member
Thanks for reporting the issue.
Unfortunately the crash log does not really provide any obvious indication what might be causing the crash.

Does it maybe help if you add a "wait" action in between the "Profile" and the "Streaming" action?
That's a good suggestion. I tried that as well prior to posting. It appears to be the simple action of setting the profile. My latest test is just setting the profile and it still crashes. I haven't tried it on a Windows machine at this point. I may try that at some point.
 

AaronD

Active Member
When I attempt to automatically switch profiles and start streaming, OBS crashes.
I am running on the following:
1) MAC with Sequoia 15.1.1 M1 Processor
2) OBS version 30.1.2
3) Advanced Scene Switcher version 1.28.1

Everything is update to date as of this posting. My macro is set at a certain time to switch profiles and start streaming. It is very consistent on crashing. I'm attaching the crash report.
It appears to be the simple action of setting the profile. My latest test is just setting the profile and it still crashes. I haven't tried it on a Windows machine at this point. I may try that at some point.
I think it's an OBS issue, not Adv. SS. The Linux version usually crashes too, but not always, even when switching manually from the menu. Probably nothing to do with Adv. SS in that case.

I solved it with the command-line flags when starting OBS:
Bash:
...
OBS_PROFILE="Meeting_Master"    # default, can be overridden by a later argument
...
obs --verbose --unfiltered_log --disable-updater --disable-shutdown-check --multi --studio-mode --profile "$OBS_PROFILE" --collection "$OBS_PROFILE" --startvirtualcam > /dev/null &
PID_MASTER=$!
sleep 10
That's copy/pasted verbatim from a script that manages a fairly complex rig. The two lines after starting OBS, grab the Process ID (PID) to be able to shut it down later, and then wait 10 seconds before starting a second simultaneous instance on the same machine with a different profile and collection:
Bash:
obs --verbose --unfiltered_log --disable-updater --disable-shutdown-check --multi --studio-mode --profile "Meeting_Slave" --collection "Meeting_Slave" > /dev/null &
PID_SLAVE=$!
sleep 10
Same idea there, and then set up some other stuff too...

Works just fine when specifying the profile and collection on startup like this. Just don't change it in OBS, at all. Duplicating is okay.

obs --help in a terminal to see what all you can do on the command-line.
 

rtgarland

New Member
If I manually set the profile, it works fine. I can switch it multiple times and I don't see an issue. My adv SS macro is set to run at a certain time. So if it is 8am for example it switches the profile. So I believe it is crashing only in the adv SS plugin. I may try to execute the profile change through a different method. Meaning instead of at a certain time, use a different method to trigger the profile change. I'll see if it is related to the date event triggering.
 

Joos Madison

New Member
Advanced Scene Switcher works commands randomly

Dear Community,
I've been using OBS for a while now and updating versions.
I've experienced the same behavior on a few occasions and I've fixed it by updating OBS, the plugin or Visual C.
The problems are: it runs macros randomly, especially with the date/time function. Sometimes it runs it and sometimes it doesn't.
The same thing happens with the time function, with the same result.
And the sequence. If for example I have scene A that lasts 15 seconds and it has to go to scene B, it doesn't respect the time and takes about 6 to 10 seconds longer. On other occasions it doesn't even execute the instructions.
I have OBS version 30.2.3 installed.
I have ASS version 1.28.1 installed.
I've tried it with several versions of Visual C.
I've checked the date and time in the BIOS and the system and everything is correct. I've tried downgrading, but now I have the same behavior with previous versions.
Has anyone experienced this behavior?
Thanks in advance

PS. Sorry if is not the right place for this question.
 

Warmuptill

Active Member
Advanced Scene Switcher works commands randomly

Dear Community,
I've been using OBS for a while now and updating versions.
I've experienced the same behavior on a few occasions and I've fixed it by updating OBS, the plugin or Visual C.
The problems are: it runs macros randomly, especially with the date/time function. Sometimes it runs it and sometimes it doesn't.
The same thing happens with the time function, with the same result.
And the sequence. If for example I have scene A that lasts 15 seconds and it has to go to scene B, it doesn't respect the time and takes about 6 to 10 seconds longer. On other occasions it doesn't even execute the instructions.
I have OBS version 30.2.3 installed.
I have ASS version 1.28.1 installed.
I've tried it with several versions of Visual C.
I've checked the date and time in the BIOS and the system and everything is correct. I've tried downgrading, but now I have the same behavior with previous versions.
Has anyone experienced this behavior?
Thanks in advance

PS. Sorry if is not the right place for this question.
I am sorry about the issues you are facing.
Unfortunately, I can't really any concrete steps to solve or investigate your issues yet.

Can you please share more information about which macros you have set up?
Ideally you would export your settings to a file and share it with me (doesn't need to be here - feel free to send me a DM).

Additionally it would be very helpful if you try to reproduce the issue with verbose logging enabled.
Once you have managed to reproduce the issue again please share the corresponding OBS log file, which you can access in OBS via Help > Log Files.

This will help me identify which macro is causing the issue and then I can track down the potential bug.
 

rtgarland

New Member
If I manually set the profile, it works fine. I can switch it multiple times and I don't see an issue. My adv SS macro is set to run at a certain time. So if it is 8am for example it switches the profile. So I believe it is crashing only in the adv SS plugin. I may try to execute the profile change through a different method. Meaning instead of at a certain time, use a different method to trigger the profile change. I'll see if it is related to the date event triggering.
I setup a hot key and triggered the profile switch. It crashed. So I am nearly 100% sure it is the switch profile action within the Advance Scene Switcher plugin. Seems very consistent on crashing when setting the profile.
 
Thread 35D0: (Crashed)
Stack EIP Arg0 Arg1 Arg2 Arg3 Address
00000077FC0F9820 00007FFB70ECFA4C 0000000000000024 00007FFB5C3832F0 0000007700000024 00007FFB5C3832F0 kernelbase.dll!0x7ffb70ecfa4c
00000077FC0F9900 00007FFB5D665267 0000019C869335C0 0000000000000005 0000000000000005 000000000000000B vcruntime140.dll!0x7ffb5d665267
00000077FC0F9960 00007FFB5C313106 00000198BE3AC428 00000198BE3AC428 00000077FC0F9B59 000000000000000B msvcp140.dll!0x7ffb5c313106
00000077FC0F99C0 00007FFAE58C62E7 0000019BD9D48720 00007FFAE043E5C8 00007FFAE08F470C 0000019C8A238570 advanced-scene-switcher-lib.dll!advss::LockContext+0x57
00000077FC0F9A00 00007FFAE524B03B 0000019BCE6BE680 0000000000000000 0000019BD97EE130 00007FFAE0AD730B advanced-scene-switcher-base.dll!0x7ffae524b03b
00000077FC0F9A90 00007FFADFCC8DAA 0000019BD97EE130 0000019B0000000B 0000000000000007 0000000000000003 qt6core.dll!0x7ffadfcc8daa
00000077FC0F9BC0 00007FFADFCCBAA4 0000019BCE6BE680 0000000000000001 0000000000000000 000000000000000C qt6core.dll!0x7ffadfccbaa4
00000077FC0F9BF0 00007FFAE0AD3385 0000019BCE6BE680 00000077FC0F9C99 00000077FC0FA380 0000019BD97EE130 qt6widgets.dll!0x7ffae0ad3385
00000077FC0F9C20 00007FFAE09A5033 0000019C8DC881B0 0000000000000000 0000019BCE6BE680 00007FFADFE1476B qt6widgets.dll!0x7ffae09a5033
00000077FC0F9D00 00007FFAE0AD2E77 0000019800000000 00000198B30019B0 00000198B3056970 0000019BD97EE130 qt6widgets.dll!0x7ffae0ad2e77
00000077FC0F9DC0 00007FFAE096226E 00000198B3056970 00000077FC0F9EF0 00000198B30019B0 00000198B3056970 qt6widgets.dll!0x7ffae096226e
00000077FC0F9DF0 00007FFAE09613F6 00000077FC0FFB00 0000019BD97EE130 00000077FC0FA380 0000019BD97EE130 qt6widgets.dll!0x7ffae09613f6
00000077FC0FA2E0 00007FFADFC88DFF 0000019C8821D450 00007FFADFCCBAA4 0000019C8821D450 0000019800000013 qt6core.dll!0x7ffadfc88dff
00000077FC0FA350 00007FFAE096759A 0000019C8821D450 0000019C8821D450 0000019C8821D450 0000000000000000 qt6widgets.dll!0x7ffae096759a
00000077FC0FA400 00007FFAE09B3CD5 0000000000000000 0000019C8821D450 0000019C84A32830 0000000000000000 qt6widgets.dll!0x7ffae09b3cd5
00000077FC0FA4B0 00007FFAE09A67C8 0000019C876ECE00 0000019C8A224BB0 0000000000000001 00000198B3000000 qt6widgets.dll!0x7ffae09a67c8
00000077FC0FA500 00007FFAE09A66A9 0000019C876ECEA0 00000077FC0FA8E0 0000000000000001 0000019C85992890 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA550 00007FFAE09A66A9 00007FFA80007EC1 00007FFAE0D4FC70 0000000000000001 0000019C876ECEA0 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA5A0 00007FFAE09A66A9 00000077FC0FA8E0 00007FFAE0D4FC70 0000000000000001 00007FFAE0D4FC70 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA5F0 00007FFAE09A66A9 00000077FC0FA8E0 0000019C86F7CCF0 0000000000000001 00007FFAE0BE588B qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA640 00007FFAE09A66A9 00000198BE8B7CF0 00007FFB3A9134C0 0000000000000001 00007FFAE0BE588B qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA690 00007FFAE09A66A9 0000019BD9CA7CE0 00007FFAE0BE588B 0000000000000001 0000000000000000 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA6E0 00007FFAE09A66A9 00000077FC0FA850 00007FFB3A993AF9 0000000000000001 00007FFAE0BE588B qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA730 00007FFAE09A66A9 0000FDDE281CFEFD 0000019C85992890 0000019C87A01AB0 00007FFB3A9134C0 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA780 00007FFAE0B2EBEE 00000077FC0FA8E0 00000198B300B118 0000000000000000 00007FFAE0BE588B qt6widgets.dll!0x7ffae0b2ebee
00000077FC0FA7B0 00007FFAE09A66A9 00000198B300B118 00007FFAF3C7A6ED 0000000000000001 0000000000000008 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA800 00007FFAE09A66A9 0000019C8A224BB0 0000000000000001 0000000000000001 00007FFAE05A0497 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA850 00007FFAE09A66A9 0000019C86F7CCF0 0000000000000001 0000019C84A32830 0000019C8A224BB0 qt6widgets.dll!0x7ffae09a66a9
00000077FC0FA8A0 00007FFAE09A7E84 0000019C81BDC1D0 0000019C8A224BB0 0000019C8A224BB0 00007FFAE0990DBF qt6widgets.dll!0x7ffae09a7e84
00000077FC0FA960 00007FFAE09B8D56 0000000000000000 0000000000000001 0000019C84A32830 00007FFAE58C62B0 qt6widgets.dll!0x7ffae09b8d56
00000077FC0FA9B0 00007FFAE09B89EE 0000019BD9D4A460 000000000000002B 0000019C84A32830 0000019C86933760 qt6widgets.dll!0x7ffae09b89ee
00000077FC0FA9E0 00007FFAE5710FCC 00000000FFFFFFFF 0000000000000001 00000198B302EC01 00007FFAE56F5FF9 advanced-scene-switcher-lib.dll!advss::DeleteLayoutItemWidget+0x2c
00000077FC0FAA10 00007FFAE56C5B27 000000000000002B 0000019C84A32830 00000198BE3AC428 00007FFAE0B988A1 advanced-scene-switcher-lib.dll!advss::AdvSceneSwitcher::RemoveMacroCondition+0x77
00000077FC0FAAB0 00007FFAE56C660D 000000000000002B 00000077FC0FAD00 00000077FC0FAD00 00000077FC0FACB0 advanced-scene-switcher-lib.dll!advss::AdvSceneSwitcher::on_conditionRemove_clicked+0x9d
...

Trying to diagnose my constant crashing on OBS, here's one of them.
 

Crimson03Ghost

New Member
I'm trying to set it to detect some text and it doesn't seem to be working.... am I missing a step? btw I'm only choosing "Invert Flight" temporarily because it's way less complicated than the text I want, simple blackish words on whitish background. Just to test because it wasn't detecting my intended target either.
 

AaronD

Active Member
I'm trying to set it to detect some text and it doesn't seem to be working.... am I missing a step? btw I'm only choosing "Invert Flight" temporarily because it's way less complicated than the text I want, simple blackish words on whitish background. Just to test because it wasn't detecting my intended target either.
A few things:

It takes a while to load the macro, meanwhile Windows calls it "Not Responding". That might be a bug in Adv. SS, that is probably not related to your original problem, because I can't imagine that it would take that long just to load the UI. Or it could indicate that something *else* is wrong, and that same thing also kills a detection that would have worked otherwise. Hard to tell from here.

You have multiple conditions, which seems to be difficult for people to understand how they actually work. Fortunately, you only have two of them (if I saw the video correctly), so the nuances really don't matter yet. And they're OR'ed, so the macro not firing as you show, means that neither of them did.

A very useful troubleshooting tool is the execution highlighting:
1733285880198.png

If you have a macro open, there will be more here, but you'll always have at least this. Check all three as shown, and things will light up green when they're active. Actions when they happen, each condition independently when it's true, and the macro itself when it runs.
I always have those options on. Keep Adv. SS open while the thing you're looking for happens, and see if it lights up.

And one last thing: Adv. SS is running in the first place, right? :-)
1733286074893.png
 

Crimson03Ghost

New Member
A few things:

It takes a while to load the macro, meanwhile Windows calls it "Not Responding". That might be a bug in Adv. SS, that is probably not related to your original problem, because I can't imagine that it would take that long just to load the UI. Or it could indicate that something *else* is wrong, and that same thing also kills a detection that would have worked otherwise. Hard to tell from here.

You have multiple conditions, which seems to be difficult for people to understand how they actually work. Fortunately, you only have two of them (if I saw the video correctly), so the nuances really don't matter yet. And they're OR'ed, so the macro not firing as you show, means that neither of them did.

A very useful troubleshooting tool is the execution highlighting:
View attachment 109683
If you have a macro open, there will be more here, but you'll always have at least this. Check all three as shown, and things will light up green when they're active. Actions when they happen, each condition independently when it's true, and the macro itself when it runs.
I always have those options on. Keep Adv. SS open while the thing you're looking for happens, and see if it lights up.

And one last thing: Adv. SS is running in the first place, right? :-)
View attachment 109684
I followed your instructions, still no luck. One thing, where exactly am I supposed to be seeing those green indicators you're talking about?
 
Top