do not switch if entry is uninitialized for window, time, region, random

This commit is contained in:
WarmUpTill
2020-10-18 01:52:19 +02:00
parent 491108678e
commit 51612d9e7f
4 changed files with 12 additions and 0 deletions

View File

@@ -47,6 +47,9 @@ void SwitcherData::checkRandom(bool &match, OBSWeakSource &scene,
std::mt19937 urng(rng());
std::shuffle(rs.begin(), rs.end(), urng);
for (RandomSwitch &r : rs) {
if (!r.initialized())
continue;
if (r.scene == lastRandomScene)
continue;
scene = r.scene;