Coming up with a way to detect when something is on but no working, and if that case is true, make it stop counting towards another variable

Hi I'm trying to create a piece of coding. Using logic something along the lines of if input1=1 but input 2 is 0 then 0.
Any help in coding this would be greatly appreciated.

To what are you attaching this logic?

You'll need to be more specific. Is this in an expression or in a python script?

It sounds like you want:
Expression:

{view.custom.input1} && {view.custom.input2}

Python:

if input1 and input2:
    do_something()

Assuming input1 and 2 are bools or can be treated as 0 = false and > 0 is true

1 Like