Diff

util/timer.lua @ 11200:bf8f2da84007

Merge 0.11->trunk
author Kim Alvefur <zash@zash.se>
date Thu, 05 Nov 2020 22:31:25 +0100
parent 10981:e6c1e92cc7a7
child 11264:2cdcf55c6dd5
line wrap: on
line diff
--- a/util/timer.lua	Thu Nov 05 22:27:17 2020 +0100
+++ b/util/timer.lua	Thu Nov 05 22:31:25 2020 +0100
@@ -16,6 +16,11 @@
 local xpcall = require "util.xpcall".xpcall;
 local math_max = math.max;
 
+if server.timer then
+	-- The selected net.server implements this API, so defer to that
+	return server.timer;
+end
+
 local _ENV = nil;
 -- luacheck: std none