Method HasBuffer
HasBuffer<T>(Entity)
Checks whether an entity has a dynamic buffer of a specific IBufferElementData type.
Declaration
[GenerateTestsForBurstCompatibility(GenericTypeArguments = new Type[]{typeof(BurstCompatibleBufferElement)})]
public bool HasBuffer<T>(Entity entity)
where T : struct, IBufferElementData
Parameters
| Type | Name | Description |
|---|---|---|
| Entity | entity | The Entity object. |
Returns
| Type | Description |
|---|---|
| Boolean | True, if the specified entity has a dynamic buffer of IBufferElementData type. |
Type Parameters
| Name | Description |
|---|---|
| T | The IBufferElementData type. |
Remarks
Always returns false for an entity that has been destroyed.