From b7dcfde372b28f54559a9fc4debe76649436a11e Mon Sep 17 00:00:00 2001 From: solareon <769465+solareon@users.noreply.github.com> Date: Sun, 23 Jun 2024 16:17:45 +0200 Subject: [PATCH 1/2] refactor(client): release anims --- client/powerstation.lua | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/client/powerstation.lua b/client/powerstation.lua index bedadf8..53017ec 100644 --- a/client/powerstation.lua +++ b/client/powerstation.lua @@ -45,8 +45,7 @@ RegisterNetEvent('thermite:UseThermite', function() if dist < 1.5 then if CurrentCops >= config.minThermitePolice then if not powerStationConfig[closestStation].hit then - lib.requestAnimDict('weapon@w_sp_jerrycan') - TaskPlayAnim(cache.ped, 'weapon@w_sp_jerrycan', 'fire', 3.0, 3.9, 180, 49, 0, false, false, false) + lib.playAnim(cache.ped, 'weapon@w_sp_jerrycan', 'fire', 3.0, 3.9, 180, 49, 0, false, false, false) SetNuiFocus(true, true) SendNUIMessage({ action = 'openThermite', @@ -65,8 +64,7 @@ RegisterNetEvent('thermite:UseThermite', function() TriggerServerEvent('evidence:server:CreateFingerDrop', pos) if CurrentCops >= config.minThermitePolice then currentGate = CurrentThermiteGate - lib.requestAnimDict('weapon@w_sp_jerrycan') - TaskPlayAnim(cache.ped, 'weapon@w_sp_jerrycan', 'fire', 3.0, 3.9, -1, 49, 0, false, false, false) + lib.playAnim(cache.ped, 'weapon@w_sp_jerrycan', 'fire', 3.0, 3.9, -1, 49, 0, false, false, false) SetNuiFocus(true, true) SendNUIMessage({ action = 'openThermite', From bf9de3e70920a8b2af1bb4e9f6bff043d69c038f Mon Sep 17 00:00:00 2001 From: solareon <769465+solareon@users.noreply.github.com> Date: Sun, 23 Jun 2024 16:36:20 +0200 Subject: [PATCH 2/2] fix(server): linter errors --- server/main.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/server/main.lua b/server/main.lua index 6d14a19..233f22b 100644 --- a/server/main.lua +++ b/server/main.lua @@ -2,7 +2,6 @@ local config = require 'config.server' local sharedConfig = require 'config.shared' local robberyBusy = false local timeOut = false -local ITEMS = exports.ox_inventory:Items() --- This will convert a table's keys into an array --- @param tbl table @@ -395,7 +394,7 @@ end) lib.callback.register('thermite:server:check', function(source) local player = exports.qbx_core:GetPlayer(source) if not player then return false end - if exports.ox_inventory:RemoveItem(src, 'thermite', 1) then + if exports.ox_inventory:RemoveItem(source, 'thermite', 1) then return true else return false