Class Tag
Gameplay tag that represents a hierarchical name of the form 'X.Y.Z' (namespaces separated with a dot). Tags are defined in project LayersAndTagsSettings asset but can be also created from code.
Inheritance
Namespace: FlaxEngine
Assembly: FlaxEngine.CSharp.dll
Syntax
[Unmanaged]
public sealed class Tag : ValueType, IEquatable<Tag>, IEquatable<string>, IComparable, IComparable<Tag>, IComparable<string>
Constructors
Tag(UInt32)
Initializes a new instance of the Tag struct.
Declaration
public Tag(uint index)
Parameters
System.UInt32
index
The tag index. |
Fields
Index
Index of the tag (in global Level.Tags list). Index 0 is invalid. 1 is the first index.
Declaration
public uint Index
Field Value
System.UInt32
|
Properties
Default
Methods
CompareTo(Tag)
CompareTo(Object)
Declaration
public int CompareTo(object obj)
Parameters
System.Object
obj
|
Returns
System.Int32
|
CompareTo(String)
Declaration
public int CompareTo(string other)
Parameters
System.String
other
|
Returns
System.Int32
|
Equals(Tag)
Equals(Object)
Declaration
public override bool Equals(object obj)
Parameters
System.Object
obj
|
Returns
System.Boolean
|
Equals(String)
Declaration
public bool Equals(string other)
Parameters
System.String
other
|
Returns
System.Boolean
|
GetHashCode()
Declaration
public override int GetHashCode()
Returns
System.Int32
|
ToString()
Declaration
public override string ToString()
Returns
System.String
|
Operators
Equality(Tag, Tag)
Compares two tags.
Declaration
public static bool operator ==(Tag left, Tag right)
Parameters
Tag
left
The lft tag. |
Tag
right
The right tag. |
Returns
System.Boolean
True if both values are equal, otherwise false. |
Equality(Tag, String)
Compares two tags.
Declaration
public static bool operator ==(Tag left, string right)
Parameters
Tag
left
The lft tag. |
System.String
right
The right tag name. |
Returns
System.Boolean
True if both values are equal, otherwise false. |
Implicit(Tag to Boolean)
Checks if tag is valid.
Declaration
public static implicit operator bool (Tag tag)
Parameters
Tag
tag
The tag to check. |
Returns
System.Boolean
True if tag is valid, otherwise false. |
Inequality(Tag, Tag)
Compares two tags.
Declaration
public static bool operator !=(Tag left, Tag right)
Parameters
Tag
left
The lft tag. |
Tag
right
The right tag. |
Returns
System.Boolean
True if both values are not equal, otherwise false. |
Inequality(Tag, String)
Compares two tags.
Declaration
public static bool operator !=(Tag left, string right)
Parameters
Tag
left
The lft tag. |
System.String
right
The right tag name. |
Returns
System.Boolean
True if both values are not equal, otherwise false. |