Main/resources/[jobs]/[civ]/wasabi_fishing/client/functions.lua
2025-07-01 11:20:24 +02:00

36 lines
1.2 KiB
Lua

-----------------For support, scripts, and more----------------
--------------- https://discord.gg/wasabiscripts -------------
---------------------------------------------------------------
ShowHelp = function(msg)
BeginTextCommandDisplayHelp('STRING')
AddTextComponentSubstringPlayerName(msg)
EndTextCommandDisplayHelp(0, false, true, -1)
end
WaterCheck = function()
local headPos = GetPedBoneCoords(cache.ped, 31086, 0.0, 0.0, 0.0)
local offsetPos = GetOffsetFromEntityInWorldCoords(cache.ped, 0.0, 50.0, -25.0)
local water, waterPos = TestProbeAgainstWater(headPos.x, headPos.y, headPos.z, offsetPos.x, offsetPos.y, offsetPos.z)
return water, waterPos
end
CreateBlip = function(coords, sprite, colour, text, scale)
local blip = AddBlipForCoord(coords)
SetBlipSprite(blip, sprite)
SetBlipColour(blip, colour)
SetBlipAsShortRange(blip, true)
SetBlipScale(blip, scale)
AddTextEntry(text, text)
BeginTextCommandSetBlipName(text)
EndTextCommandSetBlipName(blip)
return blip
end
TryFish = function(data)
TriggerServerEvent('wasabi_fishing:tryFish', data)
end
FishingSellItems = function()
TriggerServerEvent('wasabi_fishing:sellFish')
end