Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Negate()

static Half System.Half.Negate ( Half value)
inlinestaticpackage

Definition at line 513 of file Half.cs.

514 {
515 if (!IsNaN(value))
516 {
517 return new Half((ushort)(value._value ^ 0x8000u));
518 }
519 return value;
520 }
static bool IsNaN(Half value)
Definition Half.cs:170
Half(ushort value)
Definition Half.cs:78

References System.Half.Half(), System.Half.IsNaN(), and System.value.

Referenced by System.Number.Dragon4Half(), System.Number.NumberToHalf(), and System.Number.Grisu3.TryRunHalf().