> For the complete documentation index, see [llms.txt](https://docs.gunchi.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gunchi.dev/scripts/infrastructure-looting/installation.md).

# Installation

## **1. Add Core Item Configs**

Add the AC salvage part items to:

**`core > shared.gta5.lua`**

All required items and their properties can be found in included 'coreitemconfig' file.

Example entries:

```lua
['condenserfins'] = {
    ['label'] = 'Condenser Fins',
    ['weight'] = 1000,
    ['type'] = 'item',
    ['image'] = 'alucondenserfins.webp',
    ['unique'] = false,
    ['stackable'] = true,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['description'] = 'For cooling systems',
},
['compressor'] = {
    ['label'] = 'Compressor',
    ['weight'] = 1000,
    ['type'] = 'item',
    ['image'] = 'compressor.webp',
    ['unique'] = false,
    ['stackable'] = true,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['description'] = 'For cooling systems',
},
-- (continue adding all items)
```

Add all items exactly as defined.

***

## **2. Add Item Images**

Place all required and included `.webp` images (e.g., `compressor.webp`, `thermostat.webp`, etc.) into your **inventory image directory**.

***

## **3. Add Sell Shop (Optional)**

If you want players to sell AC parts, add the following configuration to:

**`inventory > config.lua > Config.Shops`**

This section is also described in the included README file.

```lua
['acpartsbuyer'] = {
    label = 'Strange Parts Buyer',
    type = 'sell',
    locations = {
        {
            center = vector3(-1149.790039, -1513.183472, 10.632730),
            length = 1.8,
            width = 2.0,
            options = {
                heading = 0,
                minZ = 7.8327304840088,
                maxZ = 11.832730484009
            }
        },
    },
    products = 'acparts'
},
```

Then add the appropriate product list to:

**`Config.ShopProducts`**

```lua
['acparts'] = {
    { name = 'condenserfins', price = 50.0 },
    { name = 'compressor', price = 100.0 },
    { name = 'condensationpump', price = 100.0 },
    { name = 'controlboard', price = 50.0 },
    { name = 'copperwiring', price = 100.0 },
    { name = 'electricmotor', price = 100.0 },
    { name = 'fanblade', price = 50.0 },
    { name = 'heatexchanger', price = 100.0 },
    { name = 'pressureswitch', price = 100.0 },
    { name = 'refrigerant', price = 100.0 },
    { name = 'soundproofing', price = 50.0 },
    { name = 'thermostat', price = 75.0 }
}
```

You may adjust prices as desired.

***

## **4. Add the Infrastructure Resource**

Drop the included **`infrastructure`** folder into your **resources** directory.\
This folder contains the scripts that handle part generation, breakdowns, and interactions.

***

## **5. Configure the Script**

Open:

```
resources/infrastructure/config.lua
```

Configure the script to your server’s needs.

***

## **6. Ensure the Resource**

Add the resource to your server configuration:

```
ensure infrastructure
```

***

## **🎉 Installation Complete**

Once installed:

* AC parts will be recognized by the framework
* Infrastructure logic will run automatically
* You'll be able to loot infrastructure per your config
* Optional sell shop will function if added
* Items will appear in inventory with proper icons


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.gunchi.dev/scripts/infrastructure-looting/installation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
