Skip to content

Commit

Permalink
refactor(client/vehicleProperties): remove entity owner check
Browse files Browse the repository at this point in the history
May revert - let's see what happens.
  • Loading branch information
thelindat committed Apr 19, 2024
1 parent 18f8e89 commit 58021e7
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions resource/vehicleProperties/client.lua
Original file line number Diff line number Diff line change
Expand Up @@ -287,13 +287,7 @@ end
---@return boolean?
function lib.setVehicleProperties(vehicle, props, fixVehicle)
if not DoesEntityExist(vehicle) then
error(("Unable to set vehicle properties for '%s' (entity does not exist)"):
format(vehicle))
end

if NetworkGetEntityIsNetworked(vehicle) and NetworkGetEntityOwner(vehicle) ~= cache.playerId then
error((
"Unable to set vehicle properties for '%s' (client is not entity owner)"):format(vehicle))
error(("Unable to set vehicle properties for '%s' (entity does not exist)"):format(vehicle))
end

local colorPrimary, colorSecondary = GetVehicleColours(vehicle)
Expand Down

0 comments on commit 58021e7

Please sign in to comment.