“If” expressions are supposed to pass A>=B input if A==B input is unspecified, but in 4.6 it seems to be putting out zeroes. It’s easy enough to plug same line into both A>=B and A==B as a workaround.
Editor: Version 4.6.0-2369412+++depot+UE4-Releases+4.6
iMac (21.5-inch, Late 2013)
OS X Yosemite version 10.10.1 (14B25)
*2.9 GHz Intel Core i5
8 GB 1600 MHz DDR3
NVIDIA GeForce GT 750M 1024 MB
I’m sorry, but I’m not certain what you mean by using an unspecified input for A>=B. Can you post an image of Blueprint setup in which this does not function as expected? Thanks!
That’s not what I said. A>=B can’t have an unspecified input, it’s required. A==B is an optional input, but if you leave it unspecified, 4.6 outputs 0 instead of input to A>=B, like it’s supposed to.
This is easily seen by making a simple new material and just looking at preview sphere.
From top down is:
IF bug in 4.6.0, two equal inputs, no input for A==B, output is black (wrong)
Same IF in 4.5.1, output is red (correct)
Workaround for bug, just attach same line to A==B instead of leaving it unspecified
Hmm, it looks like 4.5.1 wasn’t doing right thing – it’s supposed to emit a default value if A==B and there’s no input for result. So it’s a bugfix, not a bug.
Now I’m confused, because it looks like 4.6 behavior is what was originally intended because of “Const AEquals B” default value (tooltip is “only used if AEqualsB is not hooked up”), and that it was earlier versions that were wrong.
But in that case A>=B input should really just read “A>B”, since it’s not used if A==B in any case.
Seems like there’s some disagreement whether a default constant should be emitted or A>=B input.
current IF module reads as inconsistent. Either A>=B should be changed to A>B and “Const AEquals B” default value is emitted, or “Const AEquals B” default value should be deleted as unused.
This is definitely a bug and we’re working on fixing it ASAP.
way it’s supposed to work (and did before 4.6) is that if you didn’t connect AEqualsB input, it’s just a A>B comparison and there’s no case for equality. In 4.7 there’s always an equality case when A==B, it uses value of ConstAEqualsB, even when AEqualsB is disconnected.
whole idea of ConstAEqualsB is flawed because if AEqualsB is disconnected, it drops special case for equality. So ConstAEqualsB can never be used. Before 4.6, changing ConstAEqualsB would cause a crash or undefined behavior ( attempted fix for this is what caused regression).