You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 3, 2024. It is now read-only.
The only problem i found with this scripts is that you can fish anywhere you want even where there isn't any waters. Like in the sand, road, buildings and etc. The best fix would be to make an check wich will check if you're poiting into the waters or something like that. For now i made the -3.0 on the checkcoords to -45.0 Z but theres still some places like mountains where you can abuse this bug. This scripts is amazing but because of this bug it's kinda ruins all the point of it.
The text was updated successfully, but these errors were encountered:
"Found" a sample code to fix this problem. Goes into qb-core/client/functions.lua
function QBCore.Functions.SpawnObject(model, coords, cb)
local model = (type(model) == 'number' and model or GetHashKey(model))
Citizen.CreateThread(function()
RequestModel(model)
local obj = CreateObject(model, coords.x, coords.y, coords.z, true, false, true)
SetModelAsNoLongerNeeded(model)
if cb then
cb(obj)
end
end)
end
function QBCore.Functions.SpawnLocalObject(model, coords, cb)
local model = (type(model) == 'number' and model or GetHashKey(model))
Citizen.CreateThread(function()
RequestModel(model)
local obj = CreateObject(model, coords.x, coords.y, coords.z, false, false, true)
SetModelAsNoLongerNeeded(model)
if cb then
cb(obj)
end
end)
end
function QBCore.Functions.DeleteObject(object)
SetEntityAsMissionEntity(object, false, true)
DeleteObject(object)
end
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The only problem i found with this scripts is that you can fish anywhere you want even where there isn't any waters. Like in the sand, road, buildings and etc. The best fix would be to make an check wich will check if you're poiting into the waters or something like that. For now i made the -3.0 on the checkcoords to -45.0 Z but theres still some places like mountains where you can abuse this bug. This scripts is amazing but because of this bug it's kinda ruins all the point of it.
The text was updated successfully, but these errors were encountered: