Skip to content
ConcordConcordConcord

World:setKeyGenerator

Sets the function used to generate Entity keys.

← World

Sets the function used to generate Entity keys.

world = world:setKeyGenerator( generator, initialState )
Name Type Description
generator fun(state: any): string|number, any Callable that receives the current state and returns key, newState
initialState any Initial state passed to the generator
Name Type Description
world World