This commit is contained in:
Nordi98 2025-07-14 16:42:23 +02:00
parent a730434314
commit 109cfdabcc
91 changed files with 167 additions and 852 deletions

Binary file not shown.

View file

@ -0,0 +1,11 @@
DC Customz Prop Attachment Tool V2 for developers discord.gg/dccustomz

https://dc-customz.gitbook.io/dc-customz-documentation/scripts/prop-attachment-tool-v2

Type /props to open the main menu

The options are pretty much self explanatory.

Once you're done placing the prop where you want, Remember to select the format & then Click 'Copy Data' so the attach coords can get copied to your clipboard.

If you want a few more addon animations to use consider the Everyday Animations pack: https://store.dccustomz.com/product/6379040

Binary file not shown.

View file

@ -0,0 +1,36 @@
Config = {}
Config.Framework = "esx" -- "esx", "qb", "none"
Config.OnlyAdmins = true -- Set to true to restrict to admins only
Config.Command = 'props' -- Command to open ui

-- Preset Props
Config.Props = {
'prop_cs_burger_01',
}

-- Preset Animations
Config.Animations = {
{ label = 'Eat Burger', dict = 'mp_player_inteat@burger', anim = 'mp_player_int_eat_burger', flags = 49 },
{ label = 'Drink Cup', dict = 'mp_player_intdrink', anim = 'loop_bottle', flags = 49 },
-- Everyday Anims (Uncomment if you have the DC Everyday Animations pack)
--{ label = 'Rollup', dict = 'custom@rollingupanim', anim = 'rollingup_clip', flags = 2 },
--{ label = 'Hold Drink', dict = 'custom@drinkingbottlehold', anim = 'drinkingbottlehold_clip', flags = 49 },
--{ label = 'Sip Drink', dict = 'custom@drinkingbottle', anim = 'drinkingbottle_clip', flags = 49 },
--{ label = 'Plate Eat', dict = 'custom@eatplate', anim = 'eatplate_clip', flags = 49 },
--{ label = 'Plate Eat Hold', dict = 'custom@eatplate', anim = 'eatplatehold_clip', flags = 49 },
--{ label = 'Chips Eat', dict = 'custom@chipseat', anim = 'chipseat_clip', flags = 49 },
--{ label = 'Chips Eat Hold', dict = 'custom@chipseathold', anim = 'chipseathold_clip', flags = 49 },
--{ label = 'Brush Teeth', dict = 'custom@brushteeth', anim = 'brushteeth_clip', flags = 49 },
}

-- Preset Bones
Config.Bones = {
{ name = "Left Hand", id = 18905 },
{ name = "Right Hand", id = 57005 },
{ name = "Head", id = 31086 },
{ name = "Lip", id = 47419 },
{ name = "Pelvis", id = 11816 },
{ name = "Right Leg", id = 36864 },
{ name = "Left Leg", id = 63931 },
}

View file

@ -0,0 +1,33 @@
fx_version 'cerulean'
games { 'gta5' }
lua54 'yes'

author 'DC Customz'
description 'DC Customz Prop Attach Tool V2'
version '1.0.1'

ui_page 'nui/index.html'

files {
'nui/index.html',
'nui/style.css',
'nui/script.js'
}

shared_scripts {
'config.lua',
}

client_scripts {
"client/cl_main.lua",
}

server_scripts {
"server/sv_main.lua",
}

escrow_ignore {
'config.lua',
'server/sv_main.lua'
}
dependency '/assetpacks'

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,41 @@
local QBCore, ESX = nil, nil

CreateThread(function()
if Config.Framework == "qb" then
QBCore = exports['qb-core']:GetCoreObject()
elseif Config.Framework == "esx" then
ESX = exports["es_extended"]:getSharedObject()
end
end)

RegisterNetEvent('dc_propattach:server:checkAdmin', function()
local src = source
local canUse = false
if not Config.OnlyAdmins then
canUse = true
else
if Config.Framework == "qb" then
if QBCore then
local Player = QBCore.Functions.GetPlayer(source)
if Player then
if QBCore.Functions.HasPermission(src, 'admin') or QBCore.Functions.HasPermission(src, 'god') then
canUse = true
end
end
end
elseif Config.Framework == "esx" then
if ESX then
local xPlayer = ESX.GetPlayerFromId(src)
if xPlayer then
local playerGroup = xPlayer.getGroup()
if playerGroup == "admin" or playerGroup == "superadmin" then
canUse = true
end
end
end
elseif Config.Framework == "none" then
canUse = true
end
end
TriggerClientEvent('dc_propattach:client:admincheck', src, canUse)
end)