Files
md-drugs/readme.md
T

234 lines
10 KiB
Markdown
Raw Normal View History

2024-10-28 14:11:49 -07:00
# MD-Drugs
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-11-12 01:19:37 -08:00
<img align="center" src="https://i.imgur.com/t65G9Z0.png" width="200">
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
2024-10-28 14:11:49 -07:00
# Credits
2023-12-07 15:45:48 -08:00
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!
- 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!
- 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-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
- [jixeltay](https://jixeltay.tebex.io/category/scripts) for putting out banger after banger. These people help the community learn so much more
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.
2024-11-12 01:19:37 -08:00
- Thanks to Kamaryn for this [install guide video](https://youtu.be/zvuYnUfrqaA?si=FGJuBO5krZMC14Nd) join their [discord](https://discord.gg/KPRmZqFS) for other videos updates.
2024-05-18 14:08:25 -07:00
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
# Dependencies
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
- [ox_lib](https://github.com/overextended/ox_lib/releases/tag/v3.12.0)
2024-05-02 18:34:49 -07:00
2024-10-28 14:11:49 -07:00
- [qb-target](https://github.com/qbcore-framework/qb-target) **or** [ox_target](https://github.com/overextended/ox_target)
- emote script that uses the animations event
- for example one of these
- [dpemotes](https://github.com/andristum/dpemotes) -- should use RP instead
- [rpemotes](https://github.com/alberttheprince/rpemotes-reborn)
- [scully_emotemenu](https://github.com/Scullyy/scully_emotemenu)
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
- [read](https://letters.hookedonphonics.com/us/read-guaranteed-G14.html?vc=HPG1&pc=SHPGBR&tracking_id=102917836048989658da259e8c83e6&url_id=5586&oid=707&vid=1855&cid=4194&hid=14509&utm_source=1855&aff_id2={aff_id2}&utm_campaign=PracticePackHOS&utm_medium=S&utm_content=BrandDollarPacks&gc_id=184380999&h_ad_id=374941048206&src=O&qid=3&msvid=v2)
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
- GAME BUILD 2944 OR LATER
2024-07-11 17:52:33 -07:00
2023-12-11 15:22:52 -08:00
2024-10-28 14:11:49 -07:00
# Preview
2023-12-11 15:22:52 -08:00
2024-10-28 14:11:49 -07:00
### [Preview link](https://www.youtube.com/watch?v=I_x7_oz_SAU)
2023-12-16 23:35:43 -06:00
2024-10-28 14:11:49 -07:00
# How to install like a fuckin boss
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
### STEP 1
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
- 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-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
### STEP 2
- delete `qb-drugs`
2023-12-07 15:45:48 -08:00
2024-10-28 14:11:49 -07:00
### STEP 3
2024-11-12 01:19:37 -08:00
- all locations are in the server files now utilizing callbacks to build targets
- shops.lua
- travelling merchant
- Weed Store
- Dealer Shops
- locations.lua
- holds all old config options for locations. edit what you need in here
- if you previously had them in the config copy and paste the <strong> INTERIOR </strong> guts of the options. example below
```lua
Config.MakePowder = {
{loc = vector3(1086.20, -3195.30, -39.20), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
{loc = vector3(1090.15, -3199.5, -39.18), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
{loc = vector3(1093.09, -3199.53, -39.05), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
}
```
is now
```lua
local Target = {
MakePowder = {
{loc = vector3(1086.20, -3195.30, -39.20), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
{loc = vector3(1090.15, -3199.5, -39.18), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
{loc = vector3(1093.09, -3199.53, -39.05), l = 1.0, w = 1.0, rot = 45.0, gang = ""},
}
}
```
- see its a simple change.
- recipes.lua
- handles the vast majority of remove X get Y
- Cornerselling.lua
- now the drug table is inserted into this file.
- copy and paste your data inside of the
```lua
local Drugs = {
2023-12-17 01:02:02 +01:00
2024-11-12 01:19:37 -08:00
}
```
- all plant locations i.e. coke, heroin, weed, shrooms, mescaline are in the respective server files
2024-10-28 14:11:49 -07:00
### STEP 4
2024-05-18 14:01:26 -07:00
- Head to your emote script search for **uncuff** if it's missing add it
2024-10-28 14:11:49 -07:00
- if rpemotes do this
- go to client/animationListCustom.lua
- add these to the CustomDP.Emotes = {}
```lua
["uncuff"] = {"mp_arresting","a_uncuff","Uncuff", AnimationOptions = { EmoteLoop = true, EmoteMoving = true } },
["edible"] = { "mp_player_inteat@burger", "mp_player_int_eat_burger", "edible", AnimationOptions = { EmoteLoop = false, EmoteMoving = true }},
```
- Add This to CustomDP.PropEmotes = {}
```lua
["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},}}
```
- elseif dpemotes add this to client/AnimationList.lua
- add these to DP.Emotes = {}
```lua
["uncuff"] = {"mp_arresting","a_uncuff","Uncuff", AnimationOptions = { EmoteLoop = true, EmoteMoving = true } },
["edible"] = { "mp_player_inteat@burger", "mp_player_int_eat_burger", "edible", AnimationOptions = { EmoteLoop = false, EmoteMoving = true }},
```
- add these to DP.PropEmotes = {}
```lua
["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},}}
```
- elseif scullyemotes then
- add this to emotes.lua
```lua
{
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
```lua
{
Label = 'Shoot Up',
Command = 'shootup',
Animation = "miranda_shooting_up",
Dictionary = "rcmpaparazzo1ig_4",
Options = {
Flags = {
Loop = true,
},
Props = {
{
Bone = 18905,
Name = 'prop_syringe_01',
Placement = {
vector3(0.11, 0.03, 0.0),
vector3( -124.0, 0.0, 0.0),
},
},
},
2024-05-02 18:34:49 -07:00
},
},
2024-10-28 14:11:49 -07:00
```
# STEP 5
- check `qb-smallresources/config.lua` and if this exists, delete it
- look for this code
```lua
[2] = { --Coke Processing Enter/Exit
[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-02 18:34:49 -07:00
2024-10-28 14:11:49 -07:00
# STEP 6
- Run SQL
2024-05-02 18:34:49 -07:00
2024-07-16 14:17:27 -07:00
2024-10-28 14:11:49 -07:00
# OPTIONAL STEPS
## Fivemerr
2024-07-19 00:11:11 -07:00
This is NOT a requirement but something I personally use and believe in.
- to integrate with fivemerr make sure you have ```set fivemerrLogs "API_KEY"``` in your server.cfg
2024-07-16 14:23:16 -07:00
2024-07-19 01:57:14 -07:00
- Head to /server/functions.lua turn local logs = true
2024-07-19 00:11:11 -07:00
- profit
Why integrate with Fivemerr? Its a great place to store logs as it doesnt rely on discord webhooks and its far easier to search through
2024-07-16 14:17:27 -07:00
2024-07-19 00:11:11 -07:00
As well as a place to offload images and videos from fivem that doesnt rely on discord since discord API will be automatically deleting images and videos after a certain amount of time If you need an invite to their server look below
- [Fivemerr Discord](https://discord.com/invite/fivemerr)
- [Fivemerr Docs](https://docs.fivemerr.com/)
2024-07-16 14:17:27 -07:00
2024-10-28 14:11:49 -07:00
# Radial Menu
- head to `qb-radial/config.lua` and search for the following event
2024-07-11 17:58:10 -07:00
```lua
event = 'qb-drugs:client:cornerselling',
```
2024-10-28 14:11:49 -07:00
- and change it to this
2024-07-11 17:58:10 -07:00
```lua
event = 'md-drugs:client:cornerselling',
```
2024-07-16 14:43:05 -07:00
2024-10-28 14:11:49 -07:00
# For Qb-shops users
2024-07-11 17:52:33 -07:00
2024-10-28 14:11:49 -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
2024-07-11 17:52:33 -07: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'},
```
2024-10-28 14:11:49 -07:00
# Tier System
- Turn On Config.TierSystem after you run the sql file
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.