Skip to main content

Client Exports V2

Use these exports to integrate it to your scripts! Feel free to reach me to have your scripts to be put into integrations.

GetOwnedHomes​

This export will return the owned homes of the player.

    exports.bcs_housing:GetOwnedHomes()

Returned Data (Object)​

KeyData TypeDescription
identifierstringThe home identifier
namestringThe home name / label
type'mlo' or 'shell' or 'ipl'The home type
pricenumberThe home price
garageObject (x, y, z)The coordinate of the garage (if there is any)
entryObject (x,y,z)The coordinate of the entrance
lockedbooleanStatus of the house lock for SHELL

LockHome​

Export this function to lock the home based on the identifier

    exports.bcs_housing:LockHome(identifier)

Parameter​

  • identifier it accepts the house identifier

isLocked​

Export this function to get the status of the house (Shell) lock

    -- returned data is boolean (true/false)
exports.bcs_housing:isLocked(identifier)

Parameter​

  • identifier the house identifier

GiveKey​

Export this function to give a key to a target (Server Id) with the house ID

    exports.bcs_housing:GiveKey(identifier, GetPlayerServerId(targetPed))

Parameter​

  • identifier it accepts the house identifier
  • source the player server id

RemoveKey​

Export this function to remove a key to a target (Server Id / Player Identifier) with the house ID

    exports.bcs_housing:RemoveKey(identifier, TargetIdentifier)

Parameter​

  • identifier it accepts the house identifier
  • TargetIdentifier it accepts the player identifier, citizenid for QB

HasKey​

Export this function to check if player has key with the house ID

    exports.bcs_housing:HasKey(identifier) -- home identifier

Parameter​

  • identifier it accepts the house identifier

GetKeyHolders​

This export will return the key holders of a home.

    exports.bcs_housing:GetKeyHolders(identifier) -- home identifier

Parameter​

  • identifier it accepts the house identifier

Returned Data (Array of Objects)​

KeyData TypeDescription
identifierstringThe player identifier
namestringThe player name

SetWaypoint​

Export this function to set your waypoint to the entrance of the home

    exports.bcs_housing:SetWaypoint(identifier) -- home identifier