Implement Custom Function To Handle When Field of Diarkis Field changes Due To AutoScaling

Diarkis Field allows you to implement custom logic to handle field updates triggered by Diarkis' autoscaling.

field.SetOnGridUpdated lets you register a callback to be invoked whenever the field of Diarkis Field changes so that you may update the map data and other related information.

Intended Usage

This feature is intended for dynamic updates whenever the field of Diarkis Field changes that are triggered by autoscaling of Diarkis.

// Required package
// github.com/Diarkis/diarkis/field

field.SetOnGridUpdate(func (gridKeys []string) {

// gridKeys is an array of each grid's unique key for this server process.
// Retrieve map data and other related information based on the grid keys.

})