AddCustomsShipment HELP HELP

I added custom lockpicks, and keypad crackers to a custom Black Market Dealer job. I want them to single and not shipments. And they work PERFECT, but they appear under the gundealer job instead of the BMD job? I have no idea why. Heres the code if you need to check it out


AddCustomShipment("Lockpick", "models/weapons/w_crowbar.mdl", "lockpick", 200, 10, true, 200, true, TEAM_BMD)
AddCustomShipment("Keypad Cracker", "models/weapons/w_c4_planted.mdl", "keypad_cracker", 250, 10, true, 250, true, TEAM_BMD)

So the problem is, it appears under the gundealer job instead of the black market dealer job. Please tell me a way to fix that if you know. Thanks - Toy Machine

Well, if you want them single, you could use AddEntity instead of AddCustomShipment. Since you dont want them as a shipment. Not sure about the job tho. Maybe there is a typo mistake in the TEAM_BMD?
I dont code DarkRP stuff, so I will reply if I have found a fix for the job bug.
Thats all I can help for now.

EDIT1: So here is the code if you are the lazy kind:


AddEntity("Lockpick", "lockpick", "models/weapons/w_crowbar.mdl", 500, 1, "/buylockpick", TEAM_BMD)


AddEntity("Keypad Cracker", "keypad_cracker", "models/weapons/w_c4_planted.mdl", 1500, 1, "/buykeypadcracker", TEAM_BMD)

Well, it worked under entities but now whenver I spawn it and get the slighest bit close to it it goes straight in my inventory and if I even grav gun it to pick it up it goes straight to my inventory , any fix for the weapons part? it was working absolutely perfect, no problem in coding just under the wrong job for some reason. I’m sure it was coded right.

Sorry I don’t understand what you mean by “inventory”, do you have a custom inventory system or do you mean adds to you weapons ( You press 1,2,3,4,5,6 keys to get a weapon like in every source game ). I remember my friend having this problem with it not selling to the right job. So he asked me for help, I think we fixed it by changeing this


AddEntity("Lockpick", "lockpick", "models/weapons/w_crowbar.mdl", 500, 1, "/buylockpick", TEAM_BMD)
AddEntity("Keypad Cracker", "keypad_cracker", "models/weapons/w_c4_planted.mdl", 1500, 1, "/buykeypadcracker", TEAM_BMD)

to this


AddEntity("Lockpick", "lockpick", "models/weapons/w_crowbar.mdl", 500, 1, "/buylockpick", {TEAM_BMD})
AddEntity("Keypad Cracker", "keypad_cracker", "models/weapons/w_c4_planted.mdl", 1500, 1, "/buykeypadcracker", {TEAM_BMD})

The only jobs you want the entity to be sold in must be in { } so give that a go.

Agreed to E.N.G.I.M.A.

So about your inventory system, what kind of inventory system are you using? DerpRP?

If you use your GravityGun on the item then the problem isnt in the GravityGun itself, its in the inventory system. I think you have a specific range where to pick up your item.

No custom inventory, altough i did use derprp for a while and deleted it. Just normal weapons it goes into

I dont understand how can that be a possible bug? It is built in to Garrysmod for you to pick up your items.

I know, but there is a way to make it so you have to press use on it ‘e’ before.

[editline]3rd July 2012[/editline]

Like, i dont know how to explain it i think its a entity property SIMPLE_USE