Game.Prefabs.InfomodeGroup
Assembly: Assembly-CSharp (typical game/mod assembly)
Namespace: Game.Prefabs
Type: struct
Base: System.ValueType
Implements: Unity.Entities.IComponentData, Unity.Entities.IQueryTypeParameter
Summary:
InfomodeGroup is an empty/tag ECS component used to mark entities that belong to an "info mode" group. The type is annotated with [StructLayout(LayoutKind.Sequential, Size = 1)] so the runtime will allocate one byte for the struct (avoiding a true zero-sized type). Because it implements IComponentData it can be attached to entities; implementing IQueryTypeParameter makes it usable conveniently in query/type-parameter contexts (e.g., WithAll
Fields
No instance fields
This struct declares no fields. The StructLayout attribute sets Size = 1 so the struct occupies one byte even though it contains no members.
Properties
No properties
This type is a marker component and exposes no properties.
Constructors
public InfomodeGroup()
The default parameterless constructor is the value-type default (zero-initialized). Use new InfomodeGroup() when adding as component data if an explicit instance is required.
Methods
No methods
There are no methods defined on this type; it functions solely as a tag/marker component.
Usage Example
// Add the tag component to an existing entity
entityManager.AddComponentData(entity, new InfomodeGroup());
// Create an archetype that includes the tag
var archetype = entityManager.CreateArchetype(typeof(InfomodeGroup), typeof(Translation), typeof(RenderMesh));
var entity = entityManager.CreateEntity(archetype);
// Query for entities with the tag in a SystemBase
Entities
.WithAll<InfomodeGroup>()
.ForEach((Entity e /*, other components */) =>
{
// handle infomode-group entities
})
.Schedule();
{{ This small, zero-field struct is intended purely as a lightweight marker to identify or group entities for "info mode" behavior in the game's ECS. Use it wherever you need to tag entities for queries, filtering, or conditional systems. }}