β›ΊCampement

⚑ Installation

  • Apply the SQL: Run the camps.sql file on your database.

  • Inventory Integration: You can use item_camp_kit.sql and camp_kit.png to add the camp starter item to your inventory system.


πŸ•οΈ Creating a Camp

There are four ways to create the base of a camp:

  1. With an Inventory Item Use the item "camp_kit" (or any item you set in Config.ItemName).

  2. From Client-side Event

    TriggerServerEvent("botivrp-placecraft:CreateCamp", storageModel, pedCoords)
    -- Example:
    TriggerServerEvent("botivrp-placecraft:CreateCamp", "s_re_rcboatbox01x", GetEntityCoords(PlayerPedId()))
  3. From Server-side Event

    TriggerClientEvent("BotivRP:CreateCampBase", source)
  4. Linking With Inventory (example with VORP)

    local VORPInv = exports.vorp_inventory:vorp_inventoryApi()
    VORPInv.RegisterUsableItem("camp_base", function(data)
        VORPInv.subItem(data.source, "camp_base", 1)
        TriggerClientEvent("BotivRP:CreateCampBase", data.source)
        VORPInv.CloseInv(data.source)
    end)

πŸ“¦ What Spawns in the World?

  • Two objects appear near your player: a storage chest and a box of books.

    • Storage Chest:

      • Manages the camp’s storage.

      • Can be upgraded to increase storage capacity and camp radius (reflects camp’s overall level).

      • Can be lockpicked by non-members (if enabled). You may display an alert when a loot attempt is made.

    • Book Box:

      • Used to access the camp management menu.

      • Cannot be moved and remains at the center of the camp.


⚠️ Item Names & "label unknown"

If you see "label unknown" messages, it means you are using item names that don’t exist in your items database. Solution: Make sure every item listed matches an entry in your database:


βš™οΈ Configuration Highlights

Example from config.lua:

Camp levels:

Other features:

  • Camp blip on map (Config.AddBlips = true)

  • Zone blacklists

  • Object recipes (craft requirements)

  • Random camp names (Config.Adjectives / Config.Nouns)

  • Translatable labels and menu (Config.Txt)

  • Member rights and permissions (Config.GROUP_RIGHT)


πŸ“Œ Notes

  • The book box is the camp’s core and cannot be moved or deleted.

  • Camps can be upgraded, customized, and managed by their owners/members.

  • Item names for crafting and upgrades must exist in your items database.

  • You can blacklist camp creation in certain zones.

Last updated