/
TON618OFF
/
Unity-Project-RTU
Обзор
Документация
Войти
/
TON618OFF
/
Unity-Project-RTU
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
Library/PackageCache/com.unity.visualscripting@1.9.4/Runtime/VisualScripting.Flow/Framework/Logic/NotEqual.cs
38 строк
978 B
TON618OFF
release
03 окт 2024, 22:20
03 окт 2024, 22:20
7c70e9f
Код
Авторство
О чём код?
using UnityEngine; namespace Unity.VisualScripting { /// <summary> /// Compares two inputs to determine whether they are not equal. /// </summary> [UnitCategory("Logic")] [UnitOrder(6)] public sealed class NotEqual : BinaryComparisonUnit { public NotEqual() : base() { numeric = false; } // Backward compatibility protected override string outputKey => "notEqual"; /// <summary> /// Whether A is different than B. /// </summary> [DoNotSerialize] [PortLabel("A \u2260 B")] [PortKey("notEqual")] public override ValueOutput comparison => base.comparison; protected override bool NumericComparison(float a, float b) { return !Mathf.Approximately(a, b); } protected override bool GenericComparison(object a, object b) { return OperatorUtility.NotEqual(a, b); } } }