🛠ī¸Installation

RxHousing

Welcome to our RxHousing installation page. Here you can find the dependencies you need, instructions on how to start RxHousing, how to implement the appearance and garage script in client/opensource.lua, and Frequently Asked Questions(FAQ). If you still can't install the script or encounter any errors, don't hesitate to create a ticket in our discord.

Install dependencies

Make sure you have installed all the dependencies. Without these scripts the RxHousing script will not work properly.

You can find out which frameworks we support here

Ensuring scripts

To make sure RxHousing works properly we need to make sure all scripts start in the right order in your server.cfg. Below you can find an example of how it can look like:

Your shells also need to start before the housing script to make sure everything works properly.

You can also create a folder called [rx] in your resource folder. If you have multiple scripts from us, you don't need to add them all to your server.cfg one by one. :)

-- First, we need to start "oxmysql"
ensure oxmysql

-- After oxmysql, start your framework
ensure es_extended/qb-core

-- Don't forget to include ox_lib!
ensure ox_lib

-- After these three ^^^, you can start your inventory, appearance and garage script
ensure your_inventory
ensure your_appearance_script
ensure your_garage

-- Start your shells
ensure your_shells

-- Finally, we can start RxHousing :)
ensure RxHousing or [rx]

Database

To ensure that a house you have created is saved, you need to make sure the .sql file is imported into your database. If you restart your server without doing this, the house will not be saved, and you will lose it.

Appearance and garage

Make sure your garage and appearance scripts have an event to open the menu and an event to store your vehicle in the garage. Otherwise, your script won't be compatible with our housing script.

As you can see, we have a number of pre-configured scripts. If you want to use another garage or appearance script, you can add it yourself by removing the code in the function and inserting your event.

-- function to open garage menu
function OpenGarage(coords)
    if OKOKG then
        TriggerEvent("okokGarage:OpenPrivateGarageMenu", vector3(coords.x, coords.y, coords.z), coords.w)
    else
        Error("No garage resource found (client/opensource.lua:OpenGarage)")
    end
end

-- function store vehicle
function StoreVehicleInGarage()
    if OKOKG then
        TriggerEvent("okokGarage:StoreVehiclePrivate")
    else
        Error("No garage resource found (client/opensource.lua:StoreVehicleInGarage)")
    end
end

-- function openwardrobe
function OpenWardrobe(propertyId)
    if FMAPP then
        exports["fivem-appearance"]:openWardrobe()
    elseif ILA then
        TriggerEvent("illenium-appearance:client:openOutfitMenu")
    elseif QBClothing then
        TriggerEvent('qb-clothing:client:openMenu')
    else
        Error("No wardrobe resource found (client/opensource.lua:OpenWardrobe)")
    end
end

Below, you can see two examples of how the code might look. If you add your own event, make sure to remove the old code from the function.

function OpenGarage()
    TriggerEvent('codem-garage:openHouseGarage')
end

function StoreVehicleInGarage()
    house = 'House garage'

    TriggerEvent('codem-garage:storeVehicle', house)
end

Shells

The shells you saw on the preview are not included! You can download them from k4mb1. We have pre-configured free and paid shells from him.

We don't have a tool to decorate your home with furniture. So we advise to use a furnished shell.

You can easily add a shell in RxHousing. You can do that in the shells.lua, there you will also find a number of shells that we have pre-configured. Below you can find what the file looks like, and how you can add new shells.

--[[
BY RX Scripts Š rxscripts.xyz
--]]

Config.Shells = {}

--[[ K4MB1 STARTER SHELLS ]]--
Config.Shells["standardmotel_shell"] = {
    offsets = {
        door = vector3(-0.397827, -2.530762, -1.556461),
        doorHeading = 274.00531005859,
        laptop = vector3(1.451294, -3.258057, 0.216225),
        laptopHeading = -5.9250378608704,
        stash = vector3(-0.530762, 1.204346, -0.555267),
        clothing = vector3(1.264404, 2.504395, -0.556389),
    },
}
Config.Shells["modernhotel_shell"] = {
    offsets = {
        door = vector3(4.920410, 4.077881, -1.817928),
        doorHeading = 178.88801574707,
        laptop = vector3(0.147583, 1.938477, -0.349930),
        laptopHeading = 13.525725364685,
        stash = vector3(-4.238403, 3.557617, -0.817917),
        clothing = vector3(3.026489, -3.417236, -0.817917),
    },
}
Config.Shells["furnitured_midapart"] = {
    offsets = {
        door = vector3(1.511230, -9.875488, -0.521904),
        doorHeading = 14.050617218018,
        laptop = vector3(-5.873413, 1.514404, 0.247147),
        laptopHeading = 340.99652099609,
        stash = vector3(0.181519, 6.426270, -0.521912),
        clothing = vector3(6.112793, 9.284424, -0.521912),
    },
}

--[[ K4MB1 ALL SHELLS PACK ]]--
-- Config.Shells["kambi_furnishedhouse1"] = {
--     offsets = {
--         door = vector3(-0.302299, -2.310595, 1.000000),
--         doorHeading = 269.28866577148,
--         laptop = vector3(2.461346, 0.994795, 1.709068),
--         laptopHeading = 93.704513549805,
--         stash = vector3(-2.224915, 2.173328, 0.999969),
--         clothing = vector3(-3.631947, 3.867060, 1.000023),
--     },
-- }
-- Config.Shells["luxury_housing3_k4mb1"] = {
--     offsets = {
--         door = vector3(-5.918327, -1.069616, -0.700142),
--         doorHeading = 271.65982055664,
--         laptop = vector3(4.359890, -1.811699, -0.371010),
--         laptopHeading = 15.432975769043,
--         stash = vector3(2.209511, 1.106823, -0.700180),
--         clothing = vector3(4.790962, 2.558894, -0.700180),
--     },
-- }
-- Config.Shells["luxury_housing4_k4mb1"] = {
--     offsets = {
--         door = vector3(-5.918327, -1.069616, -0.700142),
--         doorHeading = 271.65982055664,
--         laptop = vector3(4.359890, -1.811699, -0.371010),
--         laptopHeading = 15.432975769043,
--         stash = vector3(2.209511, 1.106823, -0.700180),
--         clothing = vector3(4.790962, 2.558894, -0.700180),
--     },
-- }
-- Config.Shells["modernhotel2_shell"] = {
--     offsets = {
--         door = vector3(4.888165, 4.098339, -0.821373),
--         doorHeading = 173.50604248047,
--         laptop = vector3(0.153008, 2.036717, -0.340164),
--         laptopHeading = 354.2177734375,
--         stash = vector3(-4.196033, 3.586248, -0.821388),
--         clothing = vector3(2.670223, -3.429825, -0.821381),
--     },
-- }
-- Config.Shells["modernhotel3_shell"] = {
--     offsets = {
--         door = vector3(4.888165, 4.098339, -0.821373),
--         doorHeading = 173.50604248047,
--         laptop = vector3(0.153008, 2.036717, -0.340164),
--         laptopHeading = 354.2177734375,
--         stash = vector3(-4.196033, 3.586248, -0.821388),
--         clothing = vector3(2.670223, -3.429825, -0.821381),
--     },
-- }
-- Config.Shells["furnitured_lowapart"] = {
--     offsets = {
--         door = vector3(4.951286, -0.943733, 0.345718),
--         doorHeading = 1.5189808607101,
--         laptop = vector3(-0.914440, 3.064525, 0.791992),
--         laptopHeading = 284.94964599609,
--         stash = vector3(-3.037910, 4.091669, 0.345734),
--         clothing = vector3(2.368061, -2.780310, 0.345718),
--     },
-- }
-- Config.Shells["furnitured_midapart"] = {
--     offsets = {
--         door = vector3(4.951286, -0.943733, 0.345718),
--         doorHeading = 1.5189808607101,
--         laptop = vector3(-0.914440, 3.064525, 0.791992),
--         laptopHeading = 284.94964599609,
--         stash = vector3(-3.037910, 4.091669, 0.345734),
--         clothing = vector3(2.368061, -2.780310, 0.345718),
--     },
-- }
-- Config.Shells["furnitured_motel"] = {
--     offsets = {
--         door = vector3(-1.483879, -3.701548, -0.360237),
--         doorHeading = 357.70227050781,
--         laptop = vector3(1.476959, -3.340054, 0.311470),
--         laptopHeading = 37.169040679932,
--         stash = vector3(-1.833771, 0.192400, -0.360237),
--         clothing = vector3(-1.279999, 2.247858, -0.360237),
--     },
-- }
-- Config.Shells["classicmotel_shell"] = {
--     offsets = {
--         door = vector3(0.304794, -3.666093, -0.337509),
--         doorHeading = 0.68369942903519,
--         laptop = vector3(-2.125351, 2.821413, 0.115730),
--         laptopHeading = 261.10562133789,
--         stash = vector3(4.262878, 0.223864, -0.337494),
--         clothing = vector3(2.957283, 3.064002, -0.337494),
--     },
-- }
-- Config.Shells["highendmotel_shell"] = {
--     offsets = {
--         door = vector3(3.221344, 3.109703, -0.521217),
--         doorHeading = 179.76197814941,
--         laptop = vector3(2.010498, -3.591475, -0.104385),
--         laptopHeading = 187.64874267578,
--         stash = vector3(4.133987, -0.971325, -0.520737),
--         clothing = vector3(-0.569107, 0.631935, -0.521263),
--     },
-- }

Add new shells

You can add a new shell by copying another shell in the shells.lua. You need to change the name and the coords. The name has to be identical to the name of your shell. Once you have copied the shell, you need to spawn it in-game to get the coords. You can use /shell:spawn shellname to spawn the shell and copy the offset coords.

Config.Shells["change_me"] = { -- Change the name of the shell to the name of your shell.
    offsets = {
        door = vector3(1.511230, -9.875488, -0.521904), -- change the offset coords
        doorHeading = 14.050617218018, -- change the heading
        laptop = vector3(-5.873413, 1.514404, 0.247147), -- change the offset coords
        laptopHeading = 340.99652099609, -- change the heading
        stash = vector3(0.181519, 6.426270, -0.521912), -- change the offset coords
        clothing = vector3(6.112793, 9.284424, -0.521912), -- change the offset coords
    },
}

FAQ

Last updated