"I though I had them rooted out" not possible in the real world. sorry.
i'm not 'fluent' in renpy/python, but i think you don't have any coding background.
a statment like this is wrong
Code:
if scompany == 1 and sstate == "mindless" or if scompany == 1 and sstate == "affected":
the problem is the double "if" or better the totally laking any syntactic rules in renpy/python.
translate in other language you should have
Code:
if( scompany == 1 and sstate == "mindless" or if( scompany == 1 and sstate == "affected"){...}
don't make any sense and you miss the main if close braket.
a correct write should be
Code:
if( ( scompany == 1 and sstate == "mindless") or ( scompany == 1 and sstate == "affected") )
translating in
Code:
if ( scompany == 1 and sstate == "mindless") or ( scompany == 1 and sstate == "affected") :
but you have the same statment "scompany == 1" in both or 'branch' with an "and" with another condition.
a better way to write this is
Code:
if(scompany == 1 and (sstate == "mindless" or sstate == "affected"))
translating in
Code:
if scompany == 1 and (sstate == "mindless" or sstate == "affected") :
it's called Distributive law. similar to a * ( b + c) = (a*b) + (a*c)
[for anyone with the right knowledge, yes i know i should use 'exclusive or' and not the simple 'or' for the right parallel... but we know... simplicity]
the formula with two braket between the or is right. don't use nested if in a if statement (the use of another if before closing the conditional statment witht the ":") make thing much difficult to read and debugging [even in the remote case it's correct]