VIP Weapons Dark RP

SO im trying to setup donator/vip weapons on dark rp, but my code doesnt seen to work…
However the exact same code works for my VIP/Donator jobs :confused:
Help? :L
Heres my code
[lua]AddCustomShipment(“MG42”, “models/weapons/w_mg42bd_f.mdl”, “weapon_sim_mg42”, 2450, 10, true, 900, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“M2 Carbine”, “models/weapons/w_mg42bd_f.mdl”, “weapon_sim_M2carbine”, 2450, 10, true, 900, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“M1 Garand w/ Bayonet”, “models/weapons/w_barand.mdl”, “weapon_sim_M2carbine”, 2450, 10, true, 900, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Bazooka”, “models/weapons/w_bazooka_f.mdl”, “weapon_sim_Bazooka”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Double Barrel Shotgun”, “models/weapons/w_shot_double.mdl”, “weapon_sim_dbarel”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Lee Enfield”, “models/weapons/w_leee.mdl”, “weapon_sim_endfield”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“1919A3 .30 Cal”, “models/weapons/w_30cal_f.mdl”, “weapon_sim_m1919A3”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“German Disk Grenade”, “models/weapons/w_disc.mdl”, “weapon_sim_ger_disc”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Russian Smoke Grenade”, “models/weapons/w_smoke_ru.mdl”, “weapon_sim_ru_snade”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Russian Grenade”, “models/weapons/w_frar.mdl”, “weapon_sim_ru_nade”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)
AddCustomShipment(“Degtyarev DP 27”, “models/weapons/w_d0cal.mdl”, “weapon_sim_dp30”, 2450, 10, true, 1000, true, nil, function(ply) return ply:CheckGroup(“vip”) or ply:IsAdmin() end)[/lua]

If your using ULX try with:

[lua]
AddCustomShipment(“MG42”, “models/weapons/w_mg42bd_f.mdl”, “weapon_sim_mg42”, 2450, 10, true, 900, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“M2 Carbine”, “models/weapons/w_mg42bd_f.mdl”, “weapon_sim_M2carbine”, 2450, 10, true, 900, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“M1 Garand w/ Bayonet”, “models/weapons/w_barand.mdl”, “weapon_sim_M2carbine”, 2450, 10, true, 900, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Bazooka”, “models/weapons/w_bazooka_f.mdl”, “weapon_sim_Bazooka”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Double Barrel Shotgun”, “models/weapons/w_shot_double.mdl”, “weapon_sim_dbarel”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Lee Enfield”, “models/weapons/w_leee.mdl”, “weapon_sim_endfield”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“1919A3 .30 Cal”, “models/weapons/w_30cal_f.mdl”, “weapon_sim_m1919A3”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“German Disk Grenade”, “models/weapons/w_disc.mdl”, “weapon_sim_ger_disc”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Russian Smoke Grenade”, “models/weapons/w_smoke_ru.mdl”, “weapon_sim_ru_snade”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Russian Grenade”, “models/weapons/w_frar.mdl”, “weapon_sim_ru_nade”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
AddCustomShipment(“Degtyarev DP 27”, “models/weapons/w_d0cal.mdl”, “weapon_sim_dp30”, 2450, 10, true, 1000, true, nil, function(ply) return ply:GetUserGroup() == “vip” or ply:IsAdmin() end)
[/lua]

No that didnt work… it seems anyone can see the guns

but … can you see the weapons ? and vips can see the weapons ? because this code is for vips and administration , so if your not Vip or admin , you CAN’T see the weapon

( sorry for my spelling , im from a spanish country )

i remember doing this a while back.

its tricky and depending on how you want it to work you will need to recode some of darkrp.

it was a request for someone and they wanted ULX tied in so that jobs and entities could be chosen for guests, VIPs, Admins, Super admins and owners (pretty much any rank) instead of the default all, admin, super admin.

add me on steam and ill help you out if you like

This is how I add my “VIP moneyprinters”.
[lua]AddEntity(“Elite Money Printer”, “cbc_elite_money_printer”, “models/props_lab/reciever01a.mdl”, 4500, 1, “/buyelitemoneyprinter”, nil, function(ply) return ply:GetUserGroup(“usergroup”) == “bronze_vip” or ply:GetUserGroup(“usergroup”) == “silver_vip” or ply:GetUserGroup(“usergroup”) == “gold_vip” or ply:GetUserGroup(“usergroup”) == “bronze_vipadmin” or ply:GetUserGroup(“usergroup”) == “silver_vipadmin” or ply:GetUserGroup(“usergroup”) == “gold_vipadmin” or ply:GetUserGroup(“usergroup”) == “trusted_admin” or ply:IsSuperAdmin() end)[/lua]
All you have to do it add a “nil,” after each row if you don’t have a job specified required to spawn.
If you do have jobs set up like TEAM_GUN, you would make it show up as this:
[lua]AddCustomShipment("<Name of the shipment(no spaces)>"," <the model that the shipment spawns(should be the world model…)>", “<the classname of the weapon>”, <the price of one shipment>, <how many guns there are in one shipment>, <OPTIONAL: true/false sold seperately>, <OPTIONAL: price when sold seperately>, < true/false OPTIONAL: /buy only = true> , OPTIONAL which classes can buy the shipment, OPTIONAL: the model of the shipment)[/lua]
If you don’t include the last one, the “the model of the shipment” part, you’ll have to type
[lua], nil, function(ply) return ply:GetUserGroup(“usergroup”) == “<rank you want>” or ply:GetUserGroup(“usergroup”) == “<2nd rank you want>” end[/lua]
If you don’t include the “, nil,” you make DarkRP think that you need to get the usergroups to specify shipment models.

Thanks will give it a try… and Coventry… Im not stupid :L i removed my self as admin and re joined to see if there was any change.

[editline]31st August 2012[/editline]

And i dont understand thats what ive done and still no luck :confused:

Listen, all you need to do with your existing script is add another " nil," behind the other “nil” at the end. Right now you’re saying that the usergroup the person has is the model that has to be used for the Shipment, which won’t work.

ahahahaah thank you :’) im a retard at this… 2nd day coding :slight_smile:
Thanks

This is not something you call coding. It’s called filling in variables.