From 5f18f79ed6f46db3729171ff937073817e610b6b Mon Sep 17 00:00:00 2001 From: Kazhnuz Date: Sat, 3 Apr 2021 19:59:41 +0200 Subject: [PATCH] fix: only use lovebird in debug mode --- sonic-radiance.love/core/debug.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sonic-radiance.love/core/debug.lua b/sonic-radiance.love/core/debug.lua index 0c1097a..17adcb8 100644 --- a/sonic-radiance.love/core/debug.lua +++ b/sonic-radiance.love/core/debug.lua @@ -28,12 +28,16 @@ local lovebird = require(cwd .. "libs.lovebird") function DebugSystem:new(controller, active) self.controller = controller - lovebird.update() self.active = active or false + if (self.active) then + lovebird.update() + end end function DebugSystem:update(dt) - lovebird.update(dt) + if (self.active) then + lovebird.update(dt) + end end -- PRINT FUNCTIONS