Skip to content

EntityPrefab.AddTag(string) Method

Definition

Namespace: Brine2D.ECS

Adds a tag to be applied to instantiated entities.

C#
public Brine2D.ECS.EntityPrefab AddTag(string tag);

Parameters

tag System.String

Returns

EntityPrefab

Example

C#
var prefab = new EntityPrefab("Enemy")
    .AddComponent<TransformComponent>()
    .AddTag("Enemy")
    .AddTag("Hostile");