Exemple #1
0
        /// <summary>
        /// Logs an occurance of an invalid tag type error, and advances to the next event in the event chain.
        /// </summary>
        /// <param name="e">Data about the NBT node being verified.</param>
        /// <returns>A <see cref="TagEventCode"/> indicating whether event processing should pass, fail, or advance.</returns>
        public static TagEventCode InvalidTagTypeHandler(TagEventArgs e)
        {
            Console.WriteLine("Invalid Tag Type Error: '{0}' has type '{1}', expected '{2}'", e.TagName, e.Tag.GetTagType(), e.Schema.ToString());

            return(TagEventCode.NEXT);
        }
Exemple #2
0
        /// <summary>
        /// Logs an occurance of an invalid tag value error, and advances to the next event in the event chain.
        /// </summary>
        /// <param name="e">Data about the NBT node being verified.</param>
        /// <returns>A <see cref="TagEventCode"/> indicating whether event processing should pass, fail, or advance.</returns>
        public static TagEventCode InvalidTagValueHandler(TagEventArgs e)
        {
            Console.WriteLine("Invalid Tag Value Error: '{0}' of type '{1}' is set to invalid value '{2}'", e.TagName, e.Tag.GetTagType(), e.Tag.ToString());

            return(TagEventCode.NEXT);
        }
Exemple #3
0
        /// <summary>
        /// Logs an occurance of a missing tag error, and advances to the next event in the event chain.
        /// </summary>
        /// <param name="e">Data about the NBT node being verified.</param>
        /// <returns>A <see cref="TagEventCode"/> indicating whether event processing should pass, fail, or advance.</returns>
        public static TagEventCode MissingTagHandler(TagEventArgs e)
        {
            Console.WriteLine("Missing Tag Error: '{0}'", e.TagName);

            return(TagEventCode.NEXT);
        }