Documentation index for AI agents (llms.txt) A Markdown version of every page is available: request the page's source under /docs/, follow the "alternate" link in this page's head, or start from /llms.txt.
Visual Script logo Manual

NAND#

Math / NAND

  • Can Read

  • Cannot Write

Description#

Returns True unless both value 1 and value 2 are True

Parameters#

Name Description
Value 1 The first value of the operation
Value 2 The second value of the operation

Code#

using System;
using UnityEngine;
using VisualScript.Icons;

namespace VisualScript.Runtime
{
    [Get]

    [Title("NAND")]
    [Category("Math/NAND")]

    [Description("Returns True unless both value 1 and value 2 are True")]
    [Image(typeof(IconNAND), ColorTheme.Type.Yellow)]

    [Parameter("Value 1", "The first value of the operation")]
    [Parameter("Value 2", "The second value of the operation")]

    [Keywords("Not", "And", "Invert", "Logic")]

    [Serializable]
    public class TypeBoolMathNAND : TypeBool
    {
        [SerializeField] private GetBool m_Value1 = new GetBool();
        [SerializeField] private GetBool m_Value2 = new GetBool();

        public override bool GetPreview(GameObject source)
        {
            return !(this.m_Value1.GetPreview(source) && this.m_Value2.GetPreview(source));
        }

        public override bool Get(Args args)
        {
            return !(this.m_Value1.Get(args) && this.m_Value2.Get(args));
        }

        public override string ToString()
        {
            return $"{this.m_Value1} NAND {this.m_Value2}";
        }

        protected override SubscriptionMode Subscription => SubscriptionMode.OnChange;
    }
}
Visual Script logoVisual Script © Catsoft Works 2026. All rights reserved.