docs.unity.cn
    Show / Hide Table of Contents

    Method LogFormat

    LogFormat(String, Object[])

    LogFormat can be used to write a formatted log message.

    Declaration
    [Conditional("ADDRESSABLES_LOG_ALL")]
    public static void LogFormat(string format, params object[] args)
    Parameters
    Type Name Description
    String format

    The string with format tags.

    Object[] args

    The args used to fill in the format tags.

    Remarks

    LogFormat supports Composite Formatting and works the same way as Debug.LogFormat. Addressables logs warnings and errors so by default this function will not log.

    Examples
            public void UsingLogFormatSample()
    {
    
            Addressables.LogFormat("{0:o}[{1}]Downloaded bundle", DateTime.Now, this.GetType().Name);
    
        }
    See Also
    Enable all logging
    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on Monday, June 26, 2023