Comparisons and truth
Created By:
Corrade
Last Updated By:
Corrade
Category:
References
Posted:
about 1 year ago
Revisions:
18 revisions
Last updated:
12 months ago
Info
You can find the spreadsheet for this topic here or reference the image below. The code for the mode used to gather data is available at this git repo.
This spreadsheet should be read row-wise, i.e.
null entity != zero vector
, but zero vector == null entity
.
Uses
You might be able to abbreviate your actions by comparing between data types, especially regarding whether a variable is true or false. For example, if you want to check whether or not A
is the zero vector, you could write A == TRUE
or simply A
instead of A == (0, 0, 0)
.
This resource also tells you how uninitialised variables will behave in comparisons.