- Home /
Question by
ComeSweetDeath · Jun 04, 2014 at 06:48 PM ·
checkconditionequal
"Double" conditional check? alarm.alarmOn = position != resetPosition;
alarm.alarmOn = position != resetPosition;
This is a line of code from Unity's project, stealth. What does this line mean?
The comment to this line says: // Set the alarm light to be on or off.
does it equal to : alarm.alarmOn = (position != resetPosition); ?
Comment
Best Answer
Answer by freshgamer10 · Jun 04, 2014 at 06:53 PM
Yes, it does equal to the same thing in parentheses. You are not required to use those in a statement like this.