Hello! do anyone know how to invert int value in C++?
i want to make cvar1 be (1) Int
and cvar4 to be (0) int
something like flip/flop
is it real to make? or i need to make another Void for Cvar4?
(sorry for my very bad english) ;D
Hello! do anyone know how to invert int value in C++?
i want to make cvar1 be (1) Int
and cvar4 to be (0) int
something like flip/flop
is it real to make? or i need to make another Void for Cvar4?
(sorry for my very bad english) ;D
Treat it as bool (implicit conversion to bool and back):
CVar1->Set(SSAO)
CVar4->Set(!SSAO)
Also 88 line can be written as SSAO = (bool)NewValue
. While it’s not full equivalent (the behaviour for negative values will differ), it’s still the same in the main usecases, while being more readable imo.
Thank u for help!