Custom Shipments Broke.

Hi, i tried to make more gun shipments for the gun dealer, so i went and added some to the addentities.lua file and they show up in the gun dealers buy menu, but when i buy them and then try to pick the gun up and use it, it doesn’t let me pick it up. Here is what i added:

AddCustomShipment(“AWP”, {
model = “models/weapons/w_snip_awp.mdl”,
entity = “w_snip_awp”,
price = 4000,
amount = 10,
seperate = false,
pricesep = nil,
noship = false,
allowed = {TEAM_GUN}
})

AddCustomShipment(“M4A1”, {
model = “models/weapons/w_rif_m4a1.mdl”,
entity = “w_rif_m4a1”,
price = 3000,
amount = 10,
seperate = false,
pricesep = nil,
noship = false,
allowed = {TEAM_GUN}
})

AddCustomShipment(“DualElites”, {
model = “models/weapons/w_pist_elite.mdl”,
entity = “w_pist_elite”,
price = 1000,
amount = 10,
seperate = false,
pricesep = nil,
noship = false,
allowed = {TEAM_GUN}
})

AddCustomShipment(“Para”, {
model = “models/weapons/w_mach_m249para.mdl”,
entity = “w_mach_m249para”,
price = 3500,
amount = 10,
seperate = false,
pricesep = nil,
noship = false,
allowed = {TEAM_GUN}
})

DarkRP wiki says to do it like so



AddCustomShipment("M4A1", "models/weapons/w_rif_m4a1.mdl", "weapon_real_cs_m4a1", 3900, 10, false, 0, false, {TEAM_GUN})


I don’t know if it’s been updated, but it looks like you’re trying to mix the original AddEntity and the AddCustomShipment together. Plus, the DarkRP code doesn’t use entity, it uses ent, at least for the AddEntity code.

Sidenote, i forgot to read your second sentence, so make sure Counter Strike: Source is properly mounted on your server. DarkRP should tell you if it isn’t.

You’re using the correct format for adding shipments. If the wiki says something else, it’s outdated.

The problem probably is that the entities isn’t existing.