Hytale
Integrate FastStats with Hytale server plugins
Use dev.faststats.hytale.FastStatsHytale for Hytale server plugins. Requires Java 25+.
Artifact: dev.faststats.metrics:hytale
import com.hypixel.hytale.server.core.plugin.JavaPlugin;
import com.hypixel.hytale.server.core.plugin.JavaPluginInit;
import dev.faststats.ErrorTracker;
import dev.faststats.FastStatsContext;
import dev.faststats.Metrics;
import dev.faststats.hytale.FastStatsHytale;
public class ExamplePlugin extends JavaPlugin {
public static final ErrorTracker ERROR_TRACKER = ErrorTracker.contextAware();
private final FastStatsContext context = FastStatsHytale.builder(this)
.token("YOUR_TOKEN")
.errorTrackerService(ERROR_TRACKER)
.metrics(Metrics.Factory::create)
.build();
public ExamplePlugin(final JavaPluginInit init) {
super(init);
}
@Override
protected void start() {
context.ready();
}
@Override
protected void shutdown() {
context.shutdown();
}
} Call context.ready() once, in start(). Calling it a second time logs a warning and does nothing.
See Error Tracking for configuring error reporting.
Replace YOUR_TOKEN with your project token. To keep it out of your git
repository, inject it at build time instead of
hardcoding it.