| 153 | } |
| 154 | |
| 155 | export interface CreatePlayerStateOptions { |
| 156 | onInit: (state: PlayerState) => void |
| 157 | onUpdate: <K extends keyof PlayerState>(key: K, value: PlayerState[K], state: PlayerState) => void |
| 158 | } |
| 159 | |
| 160 | export const createPlayerState = (player: Player, options: CreatePlayerStateOptions) => { |
| 161 | const keys = Object.keys(StateConfig) as Array<keyof typeof StateConfig> |
nothing calls this directly
no outgoing calls
no test coverage detected