[FREE] [ESX] Clothing as an Item

:tshirt: [ESX] Clothing as an Item Script :tshirt:

:bulb: Bring Immersion to Your Server with Wearable Clothing Items!

:wrench: Key Features:

  • :coat: Wear or Remove Clothing from Inventory: Players can carry, equip, and swap outfits directly from their inventory.
  • :art: Fully Customizable Config: Define clothing types, names, and categories.
  • :closed_lock_with_key: Compatible with ESX Legacy: Smooth integration and fully tested for stability.
  • :no_entry_sign: Anti-Exploit Measures: Secure against item duplication or misuse.
  • :unlock: Open Source Code: Easy to modify and extend. Not Escrow locked.

:fire: Add realism and expand roleplay opportunities by making fashion an interactive part of your server!


Showcase

Free here

Code is accessible Yes
Subscription-based No
Lines (approximately) 61
Requirements skinchanger, Choice of Inventory (will require editing)
Support Yes
4 Likes

Is the inventory UI available for purchase?

It is, is QS-inventory. Super customisable and really good

However, the icons, and medical props themselves are my own

You need a direct link for free scripts :slight_smile:

For free resources, this means you must include a either a link to a public git repository, or upload it directly on the forums, or link to a free Tebex package if you want to distribute it through our Asset Escrow.

This is direct from the Terms and Conditions :slight_smile:

The reason I do it through tebex is because any script updates will be easier to get through CFX rather than me updating these forums every update. Just means no one is missing out :slight_smile:

2 Likes

People don’t understand u don’t use github bcuz people are not susceptible see if update are here.

Code are Open Source on Tebex don’t panic but creator can escrow free assets now.
Not all creator give tebex link with open source code later check description before create reply.

So @Kurlie, thats good script, i will try with OX Inv.

1 Like

do it for qbcore plssss :sob: :rofl:

I can try but I’d need the qbcore inventory coding for that. And someone to test it for me

Added:

  • Now supporting QBCore, ESX, and Standalone! QBCore integration has been added but still requires testing to ensure full compatibility. :rocket:
1 Like

love that, u are the best

1 Like

It’ll be in the Standalone section as a separate script for now until I can confirm the qb works

1 Like

Added:

  • Debugging Option in config

Hello , am i doing it correctly? still unable to use the item…

CreateUsableItem.lua

TriggerEvent('clothesitems:swatoutfit')
TriggerEvent('clothesitems:swathelmet')
TriggerEvent('clothesitems:swatvest')


CreateUsableItem('swatoutfit', function(source, item)
	local source = source
	local xPlayer = ESX.GetPlayerFromId(source)
	xPlayer.removeInventoryItem("swatoutfit", 1)
	TriggerClientEvent('clothesitems:swatoutfit', source, item, 'swatoutfit')
end)

CreateUsableItem('swathelmet', function(source, item)
	local source = source
	local xPlayer = ESX.GetPlayerFromId(source)
	xPlayer.removeInventoryItem("swathelmet", 1)
	TriggerClientEvent('clothesitems:swathelmet', source, item, 'swathelmet')
end)


CreateUsableItem('swatvest', function(source, item)
	local source = source
	local xPlayer = ESX.GetPlayerFromId(source)
	xPlayer.removeInventoryItem("swatvest", 1)
	TriggerClientEvent('clothesitems:swatvest', source, item, 'swatvest')
end)

items.lua

-- kurlie_clothing_item		
['swatoutfit'] = {
	label = 'Clothing',
	weight = 5,
	stack = false, 
	consume = 0,
},

['swathelmet'] = {
	label = 'Clothing',
	weight = 50,
	stack = false, 
	consume = 0,
},

['swatvest'] = {
	label = 'Clothing',
	weight = 50,
	stack = false, 
	consume = 0,
},

config.lua

Config = {
    Ring1 = { 
        Male = { chain_1 = 7, chain_2 = 0 },
        Female = { decals_1 = 52, decals_2 = 1 }
    },

    Necklace = { 
        Male = { chain_1 = 129, chain_2 = 4 },
        Female = { chain_1 = 4, chain_2 = 4 }
    },

    NeckBrace = { 
        Male = { chain_1 = 208, chain_2 = 0 },
        Female = { chain_1 = 180, chain_2 = 0 }
    },

    swatoutfit = { 
        Male = { tshirt_1 = 16, tshirt_2 = 0, torso_1 = 74, torso_2 = 0, arms = 0, pants_1 = 126, pants_2 = 0, shoes_1 = 21, shoes_2 = 0 },
        Female = { tshirt_1 = 14, tshirt_2 = 0, torso_1 = 720, torso_2 = 0, arms = 4, pants_1 = 17, pants_2 = 0, shoes_1 = 5, shoes_2 = 2 }
    },

    swathelmet = { 
        Male = { helmet_1 = 57, helmet_2 = 0 },
        Female = { tshirt_1 = 275, tshirt_2 = 0 }
    },

    swatvest = { 
        Male = { bproof_1 = 11, bproof_2 = 0 },
        Female = { bproof_1 = 63, bproof_2 = 0 }
    }

    -- These are examples. Please make sure to edit these and add more that you want
}

what inventory script do you use?

ox_inventory

So you’ve appeared to use things for qs-inventory. You wanna add the registerusable item where you have them. I think maybe esx or any server side script.

So in any server lua make this:

ESX.RegisterUsableItem(‘swatoutfit’, function(source)
local xPlayer = ESX.GetPlayerFromId(source)

if xPlayer then
    -- Remove the SWAT outfit item from the inventory
    xPlayer.removeInventoryItem('swatoutfit', 1)

    -- Trigger the client event to apply the outfit
    TriggerClientEvent('clothesitems:swatoutfit', source)
end

end)

So it is an actual item. And when used triggers the event

thank you for your time . I copy and paste it to my speed camera script server.lua, , but still not work

connect me on discord and I can help better and easier. Link in my bio

link expired :face_with_peeking_eye: