Tps (Expression) — Skript

Addon: Skript · Category: Expression

Syntax

tps [(from|over|in) [the] last (1:5 seconds|2:10 seconds|3:minute|4:5 minutes|5:15 minutes)]

Description

The server's ticks per second, as measured by spark. Without a window, this returns all five of spark's averages, in order: the last 5 seconds, 10 seconds, minute, 5 minutes and 15 minutes.

Examples

broadcast "%tps from the last minute%"

every 30 seconds:
	if tps from the last 5 seconds < 15:
		broadcast "<red>The server is lagging!"

View source