MV Victor Engine is Broken 2 (Event Conditions) [SOLVED]

So this one, I don't even know what to make of what's wrong with it.

Context: I used Victor Event Conditions back in VX Ace to have better control over... well, event page conditions.

However, the MV version just... does not work? A fresh install of it makes all of my events unusable, and nothing I've tried makes it work. Conditions themselves don't do anything, either.

I've tried Himeworks's Custom Page Conditions, but while that one works... it makes Olivia's Skip Cutscene stop working for all events on the map, which I can't make my games without due to how long my cutscenes can get.

I think this might be the end of me if I can't get Victor's thing to work.

Note: The "unusable events" thing still happens even after turning every other plugin off, so this is a fundamental issue with Victor's script itself.

Links to the plugins:

Victor Engine - Event Conditions MV

Himeworks Custom Page Conditions
Do you have the Basic Module installed, per the prerequisites list?
Do you have the Basic Module installed, per the prerequisites list?

Yes.

S4IxQa3.png
And there are no console errors or anything? Just...stuff doesn't run?
And there are no console errors or anything? Just...stuff doesn't run?

No console errors at all, regardless if I have my entire plugin set-up on or off (barring VE_BasicModule & Event Conditions, of course). It just completely turns off all events no matter what their conditions say - custom or otherwise.

It makes me think there's something about Victor's script that's missing, like I noticed there's no meetsConditions prototype function, but I wouldn't know how to go about fixing that.
rofl, totally verified...I installed it and all of my events are just gone.

Talk about untested. I wonder if it predates MV 1.6 and was never updated to be compatible. I'll try to take a poke.

Edit: It definitely predates it.
Interesting, so it's not just me being cursed. It also makes sense considering the tutorial video he put up on his wordpress shows the plugin working just fine.

I did notice that it also ignores database conditions for page events - I set a debug event to be activated by switch 1, yet it doesn't activate that event.

CRITICALLY ENOUGH: Event Conditions doesn't mess with Olivia Skip Cutscene when I put up a bunch of result = true conditions.

Having to adding conditions to every page in the game will just wind up being an infinitely expanding spider's web of problems, but Skip Cutscene working with it is why I'm even entertaining this to begin with.
Okay...it has nothing to do with 1.6, I don't see how this ever functioned properly. Like, the logic appears to be flat out wrong 🤣

Put this as a plugin underneath the Victor stuff. This causes both editor conditions and custom conditions to be respected in my test project.

Code:
Game_Event.prototype.meetsConditions = function(page) {
    var c = page.conditions;
    if (c.switch1Valid) {
        if (!$gameSwitches.value(c.switch1Id)) {
            return false;
        }
    }
    if (c.switch2Valid) {
        if (!$gameSwitches.value(c.switch2Id)) {
            return false;
        }
    }
    if (c.variableValid) {
        if ($gameVariables.value(c.variableId) < c.variableValue) {
            return false;
        }
    }
    if (c.selfSwitchValid) {
        var key = [this._mapId, this._eventId, c.selfSwitchCh];
        if ($gameSelfSwitches.value(key) !== true) {
            return false;
        }
    }
    if (c.itemValid) {
        var item = $dataItems[c.itemId];
        if (!$gameParty.hasItem(item)) {
            return false;
        }
    }
    if (c.actorValid) {
        var actor = $gameActors.actor(c.actorId);
        if (!$gameParty.members().contains(actor)) {
            return false;
        }
    }
    var condition = VictorEngine.EventConditions.getCustomCondition(page);
    if (condition)
        return eval(condition[1]);

    return true;
};
Okay...it has nothing to do with 1.6, I don't see how this ever functioned properly. Like, the logic appears to be flat out wrong 🤣

Put this as a plugin underneath the Victor stuff. This causes both editor conditions and custom conditions to be respected in my test project.

Code:
Game_Event.prototype.meetsConditions = function(page) {
    var c = page.conditions;
    if (c.switch1Valid) {
        if (!$gameSwitches.value(c.switch1Id)) {
            return false;
        }
    }
    if (c.switch2Valid) {
        if (!$gameSwitches.value(c.switch2Id)) {
            return false;
        }
    }
    if (c.variableValid) {
        if ($gameVariables.value(c.variableId) < c.variableValue) {
            return false;
        }
    }
    if (c.selfSwitchValid) {
        var key = [this._mapId, this._eventId, c.selfSwitchCh];
        if ($gameSelfSwitches.value(key) !== true) {
            return false;
        }
    }
    if (c.itemValid) {
        var item = $dataItems[c.itemId];
        if (!$gameParty.hasItem(item)) {
            return false;
        }
    }
    if (c.actorValid) {
        var actor = $gameActors.actor(c.actorId);
        if (!$gameParty.members().contains(actor)) {
            return false;
        }
    }
    var condition = VictorEngine.EventConditions.getCustomCondition(page);
    if (condition)
        return eval(condition[1]);

    return true;
};

Maybe it was an attempted direct conversion of the VX Ace code without checking how javascript worked? But then how did he record the video... false advertising? lmao.

Anyway, thanks so much for this! 😍😍

Do you mind if I add this as a fix for my debug thread (that obviously isn't a ripoff of your tweaks thread no sir :LZSangel:) since it turned out my original fix wasn't actually working?
Not at all, I'll also add it to my tweak thread. All the visibility it can get is good.

Original thread: https://forums.rpgmakerweb.com/threads/victor-engine-is-broken-2-event-conditions-solved.157389/