Home > @esengine/ecs-framework-monorepo > ComponentPool > (constructor)
ComponentPool.(constructor)
Constructs a new instance of the ComponentPool
class
Signature:
typescript
constructor(createFn: () => T, resetFn?: (component: T) => void, maxSize?: number);
Parameters
Parameter | Type | Description |
---|---|---|
createFn | () => T | |
resetFn | (component: T) => void | (Optional) |
maxSize | number | (Optional) |