okokDocs
  • About Us
  • Scripts
    • okokVehicleControl
      • Config file
    • okokMechanicJob
      • Config file
    • okokPoliceJob
      • Config file
      • qb-inventory support
    • okokBossMenu
      • Config file
    • okokMulticharacter
      • Config file
    • okokPhone
    • okokSpawnSelector
      • Config file
      • qb-multicharacter support
    • okokLoadingScreen
      • Config file
    • okokVehicleSales
      • Config file
    • okokShop
      • Config file
    • okokGasStation
      • Config file
    • okokTuning
      • Config file
    • okokGarage
      • Config file
      • RGB vehicle colors
      • Inventories metadata
      • Housing integrations
      • qb-phone support
    • okokVehicleShop
      • Config file
      • Common errors
    • okokBanking
      • Config file
      • Paycheck transactions
      • Registering transactions
    • okokMarketplace
      • Config file
      • Common errors
    • okokChat
      • Config file
      • Export
    • okokBilling
      • Config file
      • Snippets
    • okokCrafting
      • Config file
    • okokContract
      • Config file
    • okokTalkToNPC
      • Config file
    • okokReports
      • Config file
    • okokNotify
      • Config file
      • Snippets
    • okokTextUI
      • Config file
      • Snippets
    • okokRequests
    • okokDeleteVehicles
      • Config file
  • Others
    • Discord Webhook
Powered by GitBook
On this page
  • Loaf Housing
  • esx_property
  1. Scripts
  2. okokGarage

Housing integrations

Loaf Housing

Navigate to loaf_housing/client/main.lua and add the following code:

elseif not shouldAddMarker and GetResourceState("okokGarage") == "started" then
     if not house.garageMarker then
          house.garageMarker = lib.AddMarker({
             coords = house.garage.exit.xyz - vector3(0.0, 0.0, 1.0),
             scale = vector3(3.0, 3.0, 1.0),
             callbackData = {},
             key = "primary",
             text = "Garage",
          }, nil, nil, function()
          if IsPedInAnyVehicle(PlayerPedId()) then
            TriggerEvent("okokGarage:StoreVehiclePrivate")
          else
            TriggerEvent("okokGarage:OpenPrivateGarageMenu", GetEntityCoords(PlayerPedId()), GetEntityHeading(PlayerPedId()))
          end
      end)
   end
end

esx_property

Navigate to esx_property/client/main.lua and add the following code:

function StoreVehicle(PropertyId)
  TriggerEvent("okokGarage:StoreVehiclePrivate")
end

function AccessGarage(PropertyId)
  TriggerEvent("okokGarage:OpenPrivateGarageMenu", GetEntityCoords(PlayerPedId()), GetEntityHeading(PlayerPedId()))
end
PreviousInventories metadataNextqb-phone support

Last updated 1 year ago