just throw some parentheses in there: m_bPressed = (v == 1.0);