Conditional Actions

Plugins Conditional Actions

First, great plugin. I'm curious is it possible to make this with this plugin.
When deactivating embody manually, UI buttons show/unhide.

I'm usually using timeline triggers to unhide buttons when the scene has finished but would want to make to make it automatic when someone leaves embody for any reason
 
First, great plugin. I'm curious is it possible to make this with this plugin.
When deactivating embody manually, UI buttons show/unhide.

I'm usually using timeline triggers to unhide buttons when the scene has finished but would want to make to make it automatic when someone leaves embody for any reason

Sure, you just use a boolean comparison, if the embody Active toggle is Off -> activates buttons :)
 
Hi! Soooo I was _finally_ going to use the VR check condition, but it didn't work the way I thought :D I'm sharing my use case, but please don't consider this a request as it might take again quite a long time before I actually try to use it again. Still, feedback is always useful, so there you go.

What I wanted to do was enable PostMagic only when not in VR mode; however I'd do this only when activating Embody (which I use on the WindowCamera).

So my goal was to do:

- On Embody Active
- Call Conditional Trigger's "My Trigger"
- If VR
- Enable PostMagic

Right now, it checks for triggers every frame, but in my case I only want to check it whenever I call a trigger myself.

A simple implementation for this would be a new Condition Type "Trigger", which would add a JSONStorableAction and only activate when I call it (for one frame). This way it fits in the existing model of conditions and update loop.

Thanks for listening :)
 
A quick question. My scenes are usually built like this:
First I add the plugin ''boolean comparison'': When embody is active [TRUE] = enable depth of field
Then I add another one ''boolean comparison'': When embody is active [FALSE] = disable depth of field

Is it possible to make this in one plugin? It takes lots of time to do this when there are multiple atoms with embody like person 1, person 2 and camera.
 
@JaxZoa Hello! Awesome set of plugins, but I found a few issues.
I found 2 bugs I believe in TC_CompareRotation.cs

1. The Directions currently don't do anything as there are missing callbacks for first and second direction. The functions are there, but they are never regsitered.
C#:
js_FirstTargetDirection = new JSONStorableStringChooser(id + "FirstTargetDirection", _directions, "Forward", "Direction");
js_SecondTargetDirection = new JSONStorableStringChooser(id + "SecondTargetDirection", _directions, "Forward", "Direction");

Just need to add the callback function that are already created:
C#:
js_FirstTargetDirection = new JSONStorableStringChooser(id + "FirstTargetDirection", _directions, "Forward", "Direction", Callback_OnFirstDirectionChanged);
js_SecondTargetDirection = new JSONStorableStringChooser(id + "SecondTargetDirection", _directions, "Forward", "Direction", Callback_OnSecondDirectionChanged);

2. The else statement below doesn't seem to work correctly, the dot is always between 0.8 and 1 no matter what.
C#:
public bool CheckCondition()
{
    if (firstTargetController == null || secondTargetController == null)
        return false;

    if(js_UseSecondaryDirection.val)
        currentDot = Vector3.Dot(firstTargetController.transform.rotation * firstDir, secondTargetController.transform.rotation * secondDir);
    else
        currentDot = Vector3.Dot(firstTargetController.transform.rotation * firstDir, (secondTargetController.transform.position - firstTargetController.transform.position).normalized);

    if (currentDot > 1 - js_ComparisonFlexibility.val)
        return true;

    return false;
}

I would just change it to:
C#:
else
    currentDot = Vector3.Dot(firstTargetController.transform.rotation * firstDir, secondTargetController.transform.rotation * firstDir);
 
Last edited:
Hi JaxZoa,

Thank you for the awesome plugin. I just wanted to ask if there is a way to turn off the UseForResetCheck for good? Everytime I load a scene that I've updated and unchecked the UseForResetCheck it checks it again and throws everything off. Everytime I load a scene I have to go through every conditional trigger to check if it has been removed otherwise it throws off everything in the scene.

Thank you!
 
Back
Top Bottom