Files
md-drugs/readme.md
T

220 lines
7.6 KiB
Markdown
Raw Normal View History

2023-12-17 01:02:02 +01:00
<h1>md-drugs</h1>
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
<div align="center">
<a href="https://discord.gg/sAMzrB4DDx">
2024-05-18 14:01:26 -07:00
<img align="center" src="https://i.imgur.com/t65G9Z0.png" width="100">
2023-12-17 01:02:02 +01:00
</a><br>
<a href="https://discord.gg/sAMzrB4DDx">Mustache Scripts Discord</a><br>
</div>
2023-12-07 15:45:48 -08:00
<h1>Credits</h1>
2023-12-17 01:02:02 +01:00
- I used [Samuel's development](https://fivem.samueldev.shop/) Christmas script global states and prop spawning (with permission obtained prior to release) in the development process.
- Shout out to [STACHY225](https://babiczind.tebex.io/category/2103836) for working out the meth network animations!
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- Huge credit to [Bostra](https://discord.gg/5ncbwMNq) for sharing free scripts and providing sanity checks during moments of confusion. Those cute mushrooms? His creation!
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- Special thanks to [Feisty]() for the stunning visuals. If it looks good, she probably had a hand in it.
- Special shoutout to [Beta Testers]()Your feedback has been invaluable!
2023-12-07 15:45:48 -08:00
2023-12-17 01:20:08 +01:00
- Big Credit to [Bostra](https://discord.gg/5ncbwMNq). if you have been around you may have seen him post some free scripts and help people, There was definetly times I dm'd him saying what the fuck am I doing and he helped keep me sane. He also made the cute mushrooms!
2023-12-15 18:50:39 -08:00
- [Jim's Tebex](https://jimathy666.tebex.io/) for putting out open source resources that I was able to break and fix and learn how to code
2023-12-17 01:20:08 +01:00
2023-12-15 18:50:39 -08:00
- [jixeltay](https://jixeltay.tebex.io/category/scripts) for putting out banger after banger. These people help the community learn so much more
2023-12-07 15:45:48 -08:00
2023-12-17 01:07:08 +01:00
- Our partner [1of1 Servers]( https://1of1servers.com/) and their [discord](https://discord.gg/1of1servers) for their amazing server hosting! absolutely top notch.
2023-12-17 01:02:02 +01:00
2024-05-18 14:07:24 -07:00
<h1>Special Thanks To Kamaryn For The Preview</h1>
2024-05-18 14:07:58 -07:00
- Thanks to Kamaryn for this [install guide video](https://youtu.be/zvuYnUfrqaA?si=FGJuBO5krZMC14Nd)
2024-05-18 14:08:25 -07:00
2024-05-18 14:07:58 -07:00
- join their [discord](https://discord.gg/KPRmZqFS) for other videos updates.
2023-12-07 15:45:48 -08:00
<h1>Dependencies</h1>
2024-05-02 18:34:49 -07:00
- [Ox Lib](https://github.com/overextended/ox_lib/releases/tag/v3.12.0)
2024-05-18 14:07:24 -07:00
- [qb-target](https://github.com/qbcore-framework/qb-target) **or** ox_target
2024-05-02 18:34:49 -07:00
- emote script that uses the animations event (rpemotes, dpemotes, scully emotes all work)
2024-05-18 14:07:24 -07:00
2024-05-02 18:34:49 -07:00
2024-02-17 20:54:58 -08:00
- GAME BUILD 2944 OR LATER
2023-12-07 15:45:48 -08:00
2024-05-02 18:34:49 -07:00
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
<h1>Preview</h1>
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- [Preview link](https://www.youtube.com/watch?v=I_x7_oz_SAU)
2023-12-11 15:22:52 -08:00
2023-12-17 01:02:02 +01:00
<h1>How to install like a fuckin boss</h1>
2023-12-11 15:22:52 -08:00
2023-12-17 01:02:02 +01:00
- **STEP 1**
- qb-inventory users go to md-drugs/items_install/qb-inventory and add the Items to `qb-core/shared/items.lua` and - Add items from md-drugs/items_install/images to qb-inventory/html/images
- ox_inventory users go to md-drugs/items_install/ox_inventory and add the Items to `ox_inventory/data/items.lua` and - Add items from md-drugs/items_install/images to ox_inventory/web/images
2023-12-16 23:35:43 -06:00
2023-12-17 01:02:02 +01:00
- **STEP 2**
2023-12-07 15:45:48 -08:00
2024-05-02 18:34:49 -07:00
- delete `qb-drugs`
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- **STEP 3**
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- Inside the config file change **all** the locations for everything.
2024-05-02 18:34:49 -07:00
- **ps: All locations have been changed to make a preview video easier and with how big of a script this is, Im not going to config it for every city. THESE LOCATION DO NOT DO WELL FOR A LIVE SERVER SO CHANGE THEM**
2023-12-07 15:45:48 -08:00
2024-05-02 18:34:49 -07:00
- **STEP 4**
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
- head to `qb-radial/config.lua` and search for the following event
```lua
event = 'qb-drugs:client:cornerselling',
2023-12-07 15:45:48 -08:00
```
2023-12-17 01:02:02 +01:00
![](https://cdn.discordapp.com/attachments/1164709522691076120/1185724912648867940/image.png?ex=6590a760&is=657e3260&hm=51534201d8d3e71f79a5c1678879ed8423f381a4a31c62f1bce6caf73782abe0&)
```lua
event = 'md-drugs:client:cornerselling',
2023-12-07 15:45:48 -08:00
```
2023-12-17 01:02:02 +01:00
![](https://cdn.discordapp.com/attachments/1164709522691076120/1185725132975644753/image.png?ex=6590a795&is=657e3295&hm=97d7f60ec6c4508af92f758c00669b1d52fe673c6481434b586f81cf29c1f292&)
2023-12-07 15:45:48 -08:00
2023-12-17 01:02:02 +01:00
2024-05-02 18:34:49 -07:00
- **STEP 5**
2023-12-17 01:02:02 +01:00
2024-05-18 14:02:46 -07:00
- Head to `qb-shops/config.lua` **Config.Products** and add the folowing items to OR anywhere else you want them. The Only way in this script to get them is to find the travelling merchant
2023-12-17 01:02:02 +01:00
```lua
{name = 'bakingsoda', price = 100, amount = 5000, info = {}, type = 'item'},
{name = 'emptyvial', price = 100, amount = 5000, info = {}, type = 'item'},
{name = 'needle', price = 100, amount = 5000, info = {}, type = 'item'},
2023-12-07 15:45:48 -08:00
```
2023-12-17 01:02:02 +01:00
- **Preview**
![](https://cdn.discordapp.com/attachments/1164709522691076120/1185729686135910582/image.png?ex=6590abd2&is=657e36d2&hm=35c3b2d4f55473d65dd9197a69052b7ec7ac7b28528811f3f59d5f306b7237eb&)
2024-05-02 18:34:49 -07:00
- **STEP 6**
2024-05-18 14:01:26 -07:00
- Head to your emote script search for **uncuff** if it's missing add it
2024-05-18 14:07:24 -07:00
- if rp or dpemotes then do this
2023-12-17 01:02:02 +01:00
```lua
2024-05-18 14:07:24 -07:00
["uncuff"] = {"mp_arresting","a_uncuff","Uncuff", AnimationOptions = { EmoteLoop = true, EmoteMoving = true } },
2024-05-02 18:34:49 -07:00
["edible"] = { "mp_player_inteat@burger", "mp_player_int_eat_burger", "edible", AnimationOptions = { EmoteLoop = false, EmoteMoving = true }},
["shootup"] = { "rcmpaparazzo1ig_4", "miranda_shooting_up", "Shoot Up", AnimationOptions = {EmoteLoop = true,EmoteMoving = true,Prop = 'prop_syringe_01', PansexualPropBone = 18905,PropPlacement = {0.11, 0.03, 0.0, -124.0, 0.0, 0.0},}},
2023-12-07 15:45:48 -08:00
```
2023-12-17 01:02:02 +01:00
2024-05-18 14:07:24 -07:00
- if scully emotes do this in emotes.lua
2024-05-02 18:34:49 -07:00
```
{
Label = 'Uncuff',
Command = 'uncuff',
Animation = 'a_uncuff',
Dictionary = 'mp_arresting',
Options = {
Flags = {
Loop = true,
Move = true,
},
}
},
{
Label = 'Edibles',
Command = 'edible',
Animation = 'mp_player_int_eat_burger',
Dictionary = 'mp_player_inteat@burger',
Options = {
Flags = {
Loop = true,
Move = true,
},
}
},
```
then in prop emotes do
```
{
Label = 'Shoot Up',
Command = 'shootup',
Animation = "miranda_shooting_up",
Dictionary = "rcmpaparazzo1ig_4",
Options = {
Flags = {
Loop = true,
},
Props = {
{
Bone = 18905,
Name = 'prop_syringe_01',
Placement = {
2024-06-22 14:49:46 -07:00
vector3(0.11, 0.03, 0.0),
vector3( -124.0, 0.0, 0.0),
2024-05-02 18:34:49 -07:00
},
},
},
},
},
```
- **STEP 7**
- check `qb-smallresources/config.lua` and if this exists, delete it
2024-05-18 14:01:26 -07:00
```
[2] = { --Coke Processing Enter/Exit
2024-05-02 18:34:49 -07:00
[1] = {
poly = { coords = vector3(909.49, -1589.22, 30.51), heading = 92.24, length = 2, width = 2 },
allowVeh = false,
label = '[E] Enter Coke Processing'
},
[2] = {
poly = { coords = vector3(1088.81, -3187.57, -38.99), heading = 181.7, length = 2, width = 2 },
allowVeh = false,
label = '[E] Leave'
}
}
2024-05-18 14:01:26 -07:00
```
2024-05-02 18:34:49 -07:00
-- **OPTIONAL STEPS**
- **for qb-adminmenu users**
- head to `qb-adminmenu/server/server.lua` search for the following callback
```lua
QBCore.Functions.CreateCallback('test:getdealers', function(_, cb)
cb(exports['qb-drugs']:GetDealers())
end)
```
- and replace it with this
2023-12-17 01:02:02 +01:00
2024-05-02 18:34:49 -07:00
```lua
QBCore.Functions.CreateCallback('test:getdealers', function(_, cb)
cb(exports['md-drugs']:GetDealers())
end)
```
-
2024-05-18 14:01:26 -07:00
- **IF YOU WANT TO USE THE TIER SYSTEM FOR COKE,CRACK, AND HEROIN**
2024-05-02 18:34:49 -07:00
search for
```
PlayerData.metadata['dealerrep'] = PlayerData.metadata['dealerrep'] or 0
```
2024-05-18 14:01:26 -07:00
IF YOUR QB-CORE IS FROM MAY 1ST OR BEFORE GO IN PLAYERS.LUA in QB-CORE/Server/players.lua and add these directly below
2024-05-02 18:34:49 -07:00
```
PlayerData.metadata['coke'] = PlayerData.metadata['coke'] or 0
PlayerData.metadata['heroin'] = PlayerData.metadata['heroin'] or 0
PlayerData.metadata['lsd'] = PlayerData.metadata['lsd'] or 0
```
2024-05-09 01:15:25 -07:00
2024-05-18 14:01:26 -07:00
**IF YOU HAVE THE LATEST QB-CORE THEY RECENTLY UPDATED HOW METADATA IS MADE**
2024-05-09 01:15:25 -07:00
2024-06-28 14:13:27 -07:00
go to the config of qb-core and search metadata, underneath armor = 0, add this
2024-05-09 01:15:25 -07:00
```
lsd = 0,
coke = 0,
heroin = 0,
2024-06-28 14:13:27 -07:00
dealerrep = 0,
2024-05-09 01:15:25 -07:00
```
2024-05-02 18:34:49 -07:00
2024-01-12 12:40:27 -08:00
2024-05-18 14:01:26 -07:00
[mlo i use](https://www.gta5-mods.com/maps/mlo-4x-drug-lab-interiors-sp-fivem) heres an option. use it or dont.