Advanced Scene Switcher

Advanced Scene Switcher 1.28.1

David_G

New Member
I am sorry about that!

I think I will need a bit more information to investigate what the issue might be.
Can you share a screenshot of the macro that is not working or export your settings to a file so I can try to reproduce the issue on my end?


If I understand correctly what you are trying to do I would recommend separate out the actions into a macro which does not have any conditions.
So something like this:
View attachment 102239
You would then use the "Macro" action to run the actions this helper macro in both the "First level macro" and the "Nested macro".
View attachment 102240
I hope this helped / the explanation was clear enough! :)
Hi,

OK, I can see that performing how you say it should and I wasn't aware of that.

However, I was wanting the nested macro to have it's own condition. I was hoping to split the condition logic over several macros to handle things like

If condition A and (condition B or condition C) then

Do you have any documentation on condition evaluation? For instance is it short circuit evaluation? How do I achieve bracket groups etc?

cheers,

David
 

AaronD

Active Member
Hi,

OK, I can see that performing how you say it should and I wasn't aware of that.

However, I was wanting the nested macro to have it's own condition. I was hoping to split the condition logic over several macros to handle things like

If condition A and (condition B or condition C) then

Do you have any documentation on condition evaluation? For instance is it short circuit evaluation? How do I achieve bracket groups etc?

cheers,

David
The condition logic works as if you had all of your open brackets up front, and then close one for each condition. It's easy to program that way, and I've done that myself a few times in other projects. But it does have some limitations, like you can't directly do ((A or B) and (C or D)).

But we also have the Macro condition here. So what you might do, is make a macro that has part of your logic in it, and no actions, and then use the Macro condition to see if that macro is true. Something like:
Macro 1: (C or D), no actions
Macro 2: ((A or B) and Macro 1), do something

No short-circuiting. Everything is always evaluated, even if it would make no difference. Again, easy to program, at the expense of some runtime efficiency and maybe some side-effects. A big side-effect would be running an external process to get its return code, and that external process does something else too. That's not *necessarily* bad in all cases, but definitely something to be aware of!
 
Last edited:

Guuvita

New Member
none of the images of the changelog work :(
looks like renaming a variable from the cog menu in the macro tab crashes obs all the time

Also a request, could you add a save button or autosave after a configurable amount of time? each time obs crashes i lose all the work done unless i close and reopen the plugin window, and crashes being random makes an autosave kind of useful :(
 

Warmuptill

Active Member
looks like renaming a variable from the cog menu in the macro tab crashes obs all the time
Can you please share the crash log?
I can't seem to reproduce it on my end for some reason.

looks like renaming a variable from the cog menu in the macro tab crashes obs all the time

Also a request, could you add a save button or autosave after a configurable amount of time? each time obs crashes i lose all the work done unless i close and reopen the plugin window, and crashes being random makes an autosave kind of useful :(
I will add that the plugin also saves its current settings when selecting a new macro.
 
Last edited:

youjiman

New Member
I am sorry about that!

I think I will need a bit more information to investigate what the issue might be.
Can you share a screenshot of the macro that is not working or export your settings to a file so I can try to reproduce the issue on my end?
Thank you. I attached a screenshot. The thing is I want to trigger the macro when there is a moment that have no game sounds. Yet the trigger will activated even there is sounds all the time. I did a workaround by change the setting from below 1% to below -40.00dB, and it will works but even when it has very low volume. Let me know if there anything else that I need to show
 

Attachments

  • Screenshot.png
    Screenshot.png
    228.6 KB · Views: 18

Warmuptill

Active Member
Thank you. I attached a screenshot. The thing is I want to trigger the macro when there is a moment that have no game sounds. Yet the trigger will activated even there is sounds all the time. I did a workaround by change the setting from below 1% to below -40.00dB, and it will works but even when it has very low volume. Let me know if there anything else that I need to show
Ah, I see - Thanks for the hint that it works when using the dB value!
The calculation was off by a factor of 100 when using the percent based selection.

I will release a version with a fix for that issue later today.
And sorry for not catching that issue in the first place!
 

Rozenman

Member
Hi all!
Please tell me how to put the contents of the clipboard into a variable? In particular, links to youtube?
TASK: copy a link from an email to the clipboard so that it immediately appears in the value of a variable.
Thankы!
 
Last edited:

ATs_fm

New Member
Hi Warmuptill,
I came across an issue with the websocket integration. After I set up a ws action adv-ss is constantly trying to connect to the ip even though I deleted the corresponding macro. Even if I delete all macros it still tries to connect constantly resulting in cluttering of the OBS log especially since I have set condition check to 10ms. Is there a way to fix this?
Also I came to find that MIDI triggers only register after I activate the trigger once without effect. Meaning I have to trigger every MIDI trigger once before it activates the corresponding actions.
 

ATs_fm

New Member
I've found at least a workaround for the ws issue: I exported every macro-group seperately, uninstalled and reinstalled the adv-ss plugin and imported all macro-groups again.
 

AaronD

Active Member
Even if I delete all macros it still tries to connect constantly resulting in cluttering of the OBS log especially since I have set condition check to 10ms. Is there a way to fix this?
I've found at least a workaround for the ws issue: I exported every macro-group seperately, uninstalled and reinstalled the adv-ss plugin and imported all macro-groups again.

You don't have to do all that! Add a dummy macro, give it a WS condition, select the connection you want to remove as if you're going to use it, and then you have a Remove option:
1709561943961.png


That IS really confusing though. Sorry, @Warmuptill, for yanking things around after you've just done them, but I think it'd be VERY helpful to have either a single Resources tab or a separate tab for each resource, always present either way, and allows adding, removing, changing properties, etc. for everything that is used by the macros but is not itself a macro. Variables, connections, etc.
 

Warmuptill

Active Member
You don't have to do all that! Add a dummy macro, give it a WS condition, select the connection you want to remove as if you're going to use it, and then you have a Remove option:
View attachment 102288

That IS really confusing though. Sorry, @Warmuptill, for yanking things around after you've just done them, but I think it'd be VERY helpful to have either a single Resources tab or a separate tab for each resource, always present either way, and allows adding, removing, changing properties, etc. for everything that is used by the macros but is not itself a macro. Variables, connections, etc.
Sure, I can look into adding a "Websocket connections" tab as well. :)
 
Last edited:

Warmuptill

Active Member
Also I came to find that MIDI triggers only register after I activate the trigger once without effect. Meaning I have to trigger every MIDI trigger once before it activates the corresponding actions.
Thanks for reporting the issue! :)

Just to clarify:
What do you mean by MIDI trigger?
Is this a MIDI condition or MIDI action?
Was this issue introduced with 1.25 or did it already happen before?
 

Bairespm

Member
Hello, I'm trying to understand how queues are used, I understand what they are used to give priority, but I can't understand how to implement it, sorry, but someone could explain with an example. a thousand apologies for my English. thank you

1709670343550.png
 

Warmuptill

Active Member
Hello, I'm trying to understand how queues are used, I understand what they are used to give priority, but I can't understand how to implement it, sorry, but someone could explain with an example. a thousand apologies for my English. thank you

View attachment 102340
Hello,
what are the circumstances in which you are considering using action queues?

Creating them is quite simple.
First create a Queue action or condition and select "add new queue":
CreateQueue.gif


Now for an example how to use them:

Assume you have configured a macro which shows the user name of new follower you received on Twitch in text source, which looks similar to this macro:

1709760571542.png


This first grabs the Twitch follower user name and puts into the variable "Follower", then modifies the text source settings using this new variable, then shows the source for 5 seconds, and finally hides it again.

This example macro has the problem that no other macro will be run while those "long" waits are performed.

You might think that you can simply enable the option to "Run the macro in parallel to other macros", but this will only help in certain cases.
It works fine, when you only receive a single follower at most every five seconds.
You will run into issues, however, if you receive multiple followers within one 5 second span.

Here the first follower triggers the macro to be run and while it is running the second follower event is received.
As the macro is already running the actions will not be executed.

To resolve this problem you can instead add those actions to a queue and slightly rework the macro / split it into two macros.

First the macro which does the bulk of the "work".
Meaning it modifies the text source's settings and shows it for the specified amount of time:
309479013-a8cf4415-76c3-483d-a481-ff873a4033de.png

(Note that it does not have any conditions - it will be used to as the collection of actions to add to the queue)

Second a macro which grabs the Twitch follower name and assigns it to the "Follower" variable and then add the previously created macro to the queue.

309478832-7330de90-c158-45cf-9bbd-23ef2352f777.png

(The variable will be resolved when the action is added to the queue - unless configured differently in the queue settings)

Hope that helps you to understand how and when to use queues!
Feel free to ask more questions!
 

AaronD

Active Member
(The variable will be resolved when the action is added to the queue - unless configured differently in the queue settings)
That's huge! Good idea to do it that way!

I would have made it like "traditional" software, which waits to resolve it until it's actually used, which would NOT work in your example!
 

Bairespm

Member
Hello,
what are the circumstances in which you are considering using action queues?

Creating them is quite simple.
First create a Queue action or condition and select "add new queue":
View attachment 102363

Now for an example how to use them:

Assume you have configured a macro which shows the user name of new follower you received on Twitch in text source, which looks similar to this macro:

View attachment 102364

This first grabs the Twitch follower user name and puts into the variable "Follower", then modifies the text source settings using this new variable, then shows the source for 5 seconds, and finally hides it again.

This example macro has the problem that no other macro will be run while those "long" waits are performed.

You might think that you can simply enable the option to "Run the macro in parallel to other macros", but this will only help in certain cases.
It works fine, when you only receive a single follower at most every five seconds.
You will run into issues, however, if you receive multiple followers within one 5 second span.

Here the first follower triggers the macro to be run and while it is running the second follower event is received.
As the macro is already running the actions will not be executed.

To resolve this problem you can instead add those actions to a queue and slightly rework the macro / split it into two macros.

First the macro which does the bulk of the "work".
Meaning it modifies the text source's settings and shows it for the specified amount of time:
View attachment 102365
(Note that it does not have any conditions - it will be used to as the collection of actions to add to the queue)

Second a macro which grabs the Twitch follower name and assigns it to the "Follower" variable and then add the previously created macro to the queue.

View attachment 102366
(The variable will be resolved when the action is added to the queue - unless configured differently in the queue settings)

Hope that helps you to understand how and when to use queues!
Feel free to ask more questions!
Perfect, I understand, you are very clear, thank you very much. I just need to understand how to use sizes 1 to 9,
and Thank you for taking the time to answer our questions.
 
Top