Does a Hero constant not actually equal a value? Or does the value TRUE equal anything/everything?
So i have a Rule:
Condition:
Var X = True
Action:
IF Var X = Hero: Sombra
(do stuff)
Else
(do something different)
TLDR;
So I made a rule that IF Sombra hacks someone, they become ‘infected’ for a short while. While ‘infected’, IF they get close to another team mate, they too become Hacked/Infected and so on… This make a chain effect.
Anyways, the 1st person to be hacked By Sombra receives a ‘special’ penalty, which disables Primary/Secondary Fire for a few secs.
The problem is, the 1st half of the rule is ONLY supposed to execute IF the Variable specifically = the hero constant Sombra (which is only set IF that person is hacked by Sombra) else that part is skipped and the rest of the rule exicutes. Well the If = Sombra always executes. Even if the Var x = True (the value TRUE)
Why is this?
EDIT:
So I changed it slightly. Instead of setting Var x = hero Sombra, I set it to a String “Sombra”. Sure enough, the works the way i intended it…Just seem weird why the Value TRUE satisfied the IF statement (IF = Hero Sombra)