diff --git a/client/cl_property.lua b/client/cl_property.lua index f01b275..89c7f2c 100644 --- a/client/cl_property.lua +++ b/client/cl_property.lua @@ -707,7 +707,7 @@ function Property:RemoveBlip() self.blip = nil end -function Property:RemoveProperty() +function Property:RemoveProperty(doors) if Config.Target == "ox" then Framework[Config.Target].RemoveTargetZone(self.entranceTarget) else @@ -738,7 +738,7 @@ function Property:RemoveProperty() self:RemoveBlip() self:LeaveShell() self:UnregisterGarageZone() - TriggerEvent('ps-housing:client:DeleteOxDoors',self.property_id) + if doors then TriggerEvent('ps-housing:client:DeleteOxDoors', self.property_id) end --@@ comeback to this -- Think it works now if self.propertyData.apartment then diff --git a/client/client.lua b/client/client.lua index 3792d14..3cd4c9a 100644 --- a/client/client.lua +++ b/client/client.lua @@ -11,7 +11,7 @@ RegisterNetEvent('ps-housing:client:removeProperty', function (property_id) local property = Property.Get(property_id) if property then - property:RemoveProperty() + property:RemoveProperty(true) end PropertiesTable[property_id] = nil