docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method IsFalse

    IsFalse(bool)

    Assert that a condition must be false. Throws an exception if the assertion fails.

    Declaration
    [Conditional("UNITY_ASSERTIONS")]
    public static void IsFalse(bool condition)
    Parameters
    Type Name Description
    bool condition

    The expression that the caller expects to be false.

    IsFalse(bool, string)

    Assert that a condition must be false. Throws an exception if the assertion fails.

    Declaration
    [Conditional("UNITY_ASSERTIONS")]
    public static void IsFalse(bool condition, string message)
    Parameters
    Type Name Description
    bool condition

    The expression that the caller expects to be false.

    string message

    If the assertion fails, this message will be logged.

    In This Article
    • IsFalse(bool)
    • IsFalse(bool, string)
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)