From 82bc4c6d6b0c3a12b429cf8f0d2a6e09b54f5180 Mon Sep 17 00:00:00 2001 From: Andyyy7666 <86536434+Andyyy7666@users.noreply.github.com> Date: Mon, 18 Sep 2023 22:54:05 +0200 Subject: [PATCH] feat(client/functions): notification based on resource --- client/functions.lua | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/client/functions.lua b/client/functions.lua index bd18218..9cd34f2 100644 --- a/client/functions.lua +++ b/client/functions.lua @@ -26,6 +26,14 @@ function NDCore.getPlayersFromCoords(distance, coords) return closePlayers end +function NDCore.notify(...) + if GetResourceState("ModernHUD") == "started" then + exports["ModernHUD"]:notify(...) + elseif GetResourceState("ox_lib") == "started" then + lib.notify(...) + end +end + for name, func in pairs(NDCore) do if type(func) == "function" then exports(name, func)