• I need help with my server
    37 replies, posted
I have decided to make a Darkrp server and I made some jobs but my gundealer can't sell any of the M9K guns and I'm sure I put them in right any suggestions?
Post your shipment code.
// PISTOLS // AddCustomShipment("Python", "models/weapons/w_colt_python.mdl", "m9k_coltpython", 2500, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Python Single", "models/weapons/w_colt_python.mdl", "m9k_coltpython", 500, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("Colt 1911", "models/weapons/s_dmgf_co1911.mdl", "m9k_colt1911", 1200, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Colt 1911 Single", "models/weapons/s_dmgf_co1911.mdl", "m9k_colt1911", 150, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("HK 45C", "models/weapons/w_hk45c.mdl", "m9k_hk45", 1500, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("HK 45C Single", "models/weapons/w_hk45c.mdl", "m9k_hk45", 200, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("Luger", "models/weapons/w_luger_p08.mdl", "m9k_luger", 1200, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Luger Single", "models/weapons/w_luger_p08.mdl", "m9k_luger", 100, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("Raging Bull", "models/weapons/w_hk45c.mdl", "m9k_ragingbull", 3000, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Raging Bull Single", "models/weapons/w_hk45c.mdl", "m9k_ragingbull", 600, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W 500", "models/weapons/w_sw_model_500.mdl", "m9k_model500", 2750, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W 500 Single", "models/weapons/w_sw_model_500.mdl", "m9k_model500", 550, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("M29 Satan", "models/weapons/w_m29_satan.mdl", "m9k_m29satan", 3000, 10, false, 0, false, {TEAM_LIGHT}) AddCustomShipment("M29 Satan Single", "models/weapons/w_m29_satan.mdl", "m9k_m29satan", 750, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("Baretta", "models/weapons/w_beretta_m92.mdl", "m9k_m92baretta", 1400, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Baretta Single", "models/weapons/w_beretta_m92.mdl", "m9k_m92baretta", 200, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W Model 3 Russian", "models/weapons/w_model_3_rus.mdl", "m9k_model3russian", 3000, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W Model 3 Russian Single", "models/weapons/w_model_3_rus.mdl", "m9k_model3russian", 400, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W 627", "models/weapons/w_sw_model_627.mdl", "m9k_model627", 3000, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("S&W 627 Single", "models/weapons/w_sw_model_627.mdl", "m9k_model627", 425, 1, false, 0, false, {TEAM_GUN}) // ASSAULT GUNS // AddCustomShipment("Acr", "models/weapons/w_masada_acr.mdl", "m9k_acr", 4000, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("Acr Single", "models/weapons/w_masada_acr.mdl", "m9k_acr", 500, 1, false, 0, false, {TEAM_GUN}) AddCustomShipment("AMD 65", "models/weapons/w_amd_65.mdl", "m9k_amd65", 5000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("AMD 65 Single", "models/weapons/w_amd_65.mdl", "m9k_amd65", 600, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("FN FAL", "models/weapons/w_fn_fal.mdl", "m9k_fal", 4000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("FN FAL Single", "models/weapons/w_fn_fal.mdl", "m9k_fal", 550, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("M14", "models/weapons/w_snip_m14sp.mdl", "m9k_m14sp", 5000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("M14 Single", "models/weapons/w_snip_m14sp.mdl", "m9k_m14sp", 525, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("M16 Scoped", "models/weapons/w_dmg_m16ag.mdl", "m9k_m16a4_acog", 5250, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("M16 Scoped Single", "models/weapons/w_dmg_m16ag.mdl", "m9k_m16a4_acog", 575, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("HK 16", "models/weapons/w_hk_416.mdl", "m9k_m416", 5000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("HK 16 Single", "models/weapons/w_hk_416.mdl", "m9k_m416", 550, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Scar", "models/weapons/w_fn_scar_h.mdl", "m9k_scar", 6000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Scar Single", "models/weapons/w_fn_scar_h.mdl", "m9k_scar", 725, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("TAR-21", "models/weapons/w_imi_tar21.mdl", "m9k_tar21", 5000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("TAR-21 Single", "models/weapons/w_imi_tar21.mdl", "m9k_tar21", 525, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Val", "models/weapons/w_dmg_vally.mdl", "m9k_val", 5575, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Val Single", "models/weapons/w_dmg_vally.mdl", "m9k_val", 550, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("SR-3M Vikhr", "models/weapons/w_dmg_vikhr.mdl", "m9k_vikhr", 5000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("SR-3M Vikhr Single", "models/weapons/w_dmg_vikhr.mdl", "m9k_vikhr", 450, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Winchester 73", "models/weapons/w_winchester_1873.mdl", "m9k_winchester73", 3500, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Winchester 73 Single", "models/weapons/w_winchester_1873.mdl", "m9k_winchester73", 400, 1, false, 123, false, {TEAM_GUN}) // SHOTGUNS // AddCustomShipment("1887 Winchester", "models/weapons/w_winchester_1887.mdl", "m9k_1887winchester", 4000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("1887 Winchester Single", "models/weapons/w_winchester_1887.mdl", "m9k_1887winchester", 500, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Double Barrel", "models/weapons/w_double_barrel_shotgun.mdl", "m9k_dbarrel", 2000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Double Barrel Single", "models/weapons/w_double_barrel_shotgun.mdl", "m9k_dbarrel", 100, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Jack Hammer", "models/weapons/w_pancor_jackhammer.mdl", "m9k_jackhammer", 8000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Jack Hammer Single", "models/weapons/w_pancor_jackhammer.mdl", "m9k_jackhammer", 1000, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Benelli M3", "models/weapons/w_benelli_m3.mdl", "m9k_m3", 4500, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Benelli M3 Single", "models/weapons/w_benelli_m3.mdl", "m9k_m3", 500, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Ithaca M37", "models/weapons/w_ithaca_m37.mdl", "m9k_ithacam37", 3000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Ithaca M37 Single", "models/weapons/w_ithaca_m37.mdl", "m9k_ithacam37", 400, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Mossberg", "models/weapons/w_mossberg_590.mdl", "m9k_mossberg590", 3000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Mossberg Single", "models/weapons/w_mossberg_590.mdl", "m9k_mossberg590", 400, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("Remington 870", "models/weapons/w_remington_870_tact.mdl", "m9k_remington870", 2500, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("Remington 870 Single", "models/weapons/w_remington_870_tact.mdl", "m9k_remington870", 300, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("1897 Winchester", "models/weapons/w_winchester_1897_trench.mdl", "m9k_1897winchester", 4000, 10, false, 123, false, {TEAM_GUN}) AddCustomShipment("1897 Winchester Single", "models/weapons/w_winchester_1897_trench.mdl", "m9k_1897winchester", 425, 1, false, 123, false, {TEAM_GUN}) AddCustomShipment("XM1014", "models/weapons/w_shot_xm1014.mdl", "weapon_mad_xm1014", 9000, 10, false, 0, false, {TEAM_GUN}) AddCustomShipment("XM1014 Single", "models/weapons/w_shot_xm1014.mdl", "weapon_mad_xm1014", 1000, 1, false, 0, false, {TEAM_GUN})
That shipment format is outdated: [url]http://wiki.darkrp.com/index.php/DarkRP:CustomShipmentFields[/url]
Oh okay that's gonna be a lot to do but I guess I don't need all the guns thanks.
Alright so i used that code on the python from M9K and this is my code /*--------------------------------------------------------------------------- DarkRP custom shipments and guns --------------------------------------------------------------------------- This file contains your custom shipments and guns. This file should also contain shipments and guns from DarkRP that you edited. Note: If you want to edit a default DarkRP shipment, first disable it in darkrp_config/disabled_defaults.lua Once you've done that, copy and paste the shipment to this file and edit it. The default shipments and guns can be found here: [url]https://github.com/FPtje/DarkRP/blob/master/gamemode/config/addentities.lua[/url] For examples and explanation please visit this wiki page: [url]http://wiki.darkrp.com/index.php/DarkRP:CustomShipmentFields[/url] Add shipments and guns under the following line: ---------------------------------------------------------------------------*/ // PISTOLS // DarkRP.createShipment("Python Shipment", { model = "models/weapons/w_colt_python.mdl" entity = "m9k_coltpython" price = 2500 amount = 10 separate = true pricesep = 500 noship = false allowed = {TEAM_GUN} shipmodel = "models/items/item_item_crate.mdl" customCheck = function(ply) return ply:Frags() < 10 end, -- weight = 15 spareammo = 10 clip1 = 10 clip2 = 10 buttoncolor = Color(255, 255, 255, 255) label = "Python" )} It doesn't work any ideas?
You don't have any commas after table elements.
[QUOTE=code_gs;46032805]You don't have any commas after table elements.[/QUOTE] I did this is this right? // PISTOLS // DarkRP.createShipment("Python Shipment", { model = "models/weapons/w_colt_python.mdl", entity = "m9k_coltpython", price = 2500, amount = 10, separate = true, pricesep = 500, noship = false, allowed = {TEAM_GUN}, shipmodel = "models/items/item_item_crate.mdl", customCheck = function(ply), return ply:Frags() < 10 end, -- weight = 15 , spareammo = 10, clip1 = 10, clip2 = 10, buttoncolor = Color(255, 255, 255, 255), label = "Python" )}
Not exactly; take the space between 15 and the comma after weight, and make sure you don't have a comma after function(ply).
I removed the space and it still doesn't work.
[QUOTE=RebellionJay;46061375]I removed the space and it still doesn't work.[/QUOTE] Did you fix the second issue?
Here is my updated code // PISTOLS // DarkRP.createShipment("Python Shipment", { model = "models/weapons/w_colt_python.mdl", entity = "m9k_coltpython", price = 2500, amount = 10, separate = true, pricesep = 500, noship = false, allowed = {TEAM_GUN}, shipmodel = "models/items/item_item_crate.mdl", customCheck = function(ply), return ply:Frags() < 10 end, -- weight = 15, spareammo = 10, clip1 = 10, clip2 = 10, buttoncolor = Color(255, 255, 255, 255), label = "Python" )}
[QUOTE=code_gs;46044281]Not exactly; take the space between 15 and the comma after weight,[B] and make sure you don't have a comma after function(ply)[/B].[/QUOTE]
Oh... I feel dumb... I'll fix it tomorrow thanks
Yeah it didn't work new code : // PISTOLS // DarkRP.createShipment("Python Shipment", { model = "models/weapons/w_colt_python.mdl", entity = "m9k_coltpython", price = 2500, amount = 10, separate = true, pricesep = 500, noship = false, allowed = {TEAM_GUN}, shipmodel = "models/items/item_item_crate.mdl", customCheck = function(ply) return ply:Frags() < 10 end, -- weight = 15 spareammo = 10, clip1 = 10, clip2 = 10, buttoncolor = Color(255, 255, 255, 255), label = "Python" )}
Now you deleted the comma after weight.
Alright I'll add that and see if it works after I add that.
I believe the bracket "}" comes before the parenthesis ")" on the last line. Correct me if I'm wrong. Also "buttoncolor" needs to be "buttonColor".
You might be right. .. cause the order of when they are used..
Pretty sure -- table is nested in the function call, I'd change it to that.
I don't nope means I'm new to Lua coding [editline]24th September 2014[/editline] Know*
Try this. [code] DarkRP.createShipment("Python Shipment", { model = "models/weapons/w_colt_python.mdl", entity = "m9k_coltpython", price = 2500, amount = 10, separate = true, pricesep = 500, noship = false, allowed = {TEAM_GUN}, shipmodel = "models/items/item_item_crate.mdl", customCheck = function(ply) return ply:Frags() < 10 end, weight = 15, spareammo = 10, clip1 = 10, clip2 = 10, buttonColor = Color(255, 255, 255, 255), label = "Python" }) [/code]
Isn't that the same as what I just did yeah it is if if it doesn't work I'll just copy and paste that one
[QUOTE=RebellionJay;46066701]Isn't that the same as what I just did yeah it is if if it doesn't work I'll just copy and paste that one[/QUOTE] Similar, but not the same.
All right ill test out the new code I just put in and then if that does not work all use the one you suggested [editline]24th September 2014[/editline] It works but default job doesn't work...
What do you mean default job doesn't work?
Citizen doesn't work [editline]24th September 2014[/editline] It does but it isn't the default
What is the default? That code has nothing to do with your issue.
Nothing is default it says no job you can't access anything weapon wise or physgun and you have a salary. ..
Did it stop working after you implemented that code?
Sorry, you need to Log In to post a reply to this thread.