• DerpRP Inv - Advanced DarkRP Inventory System
    252 replies, posted
  • Avatar of Andriko1
  • So, if I add the model in hungermod, then it'll work? :D Basically, can you put a tutorial on how to add things so you can add them to your inventory
  • Avatar of Crap-Head
  • [QUOTE=jakegadget;22742313] Also your css weapons look like they were added correctly.[/QUOTE] I also have this, I added ALL of the CSS Weapons correctly but they still seems to be picked up as normal :( Could you please take a look on that.
  • Avatar of jakegadget
  • Ok I updated the OP with a tutorial. Just remember that items is for sents, weapons is for sweps, and food is for hungermod foods. [editline]12:29PM[/editline] Also to pick weapons up they must have been spawned through the f4 menu or from a gunlab. Guns from the qmenu will not work.
  • Avatar of Vinze
  • Sweet, we need more scripters like you, instead of the regular, bitter, obviously impotent kind going "hurp durp drp sux lol i r gonnan meak my own kewl skript cuz urs sux lol".
  • Avatar of Mortson
  • Shame I don't have my server anymore. I wanted this so badly when I had it.
  • Avatar of Crap-Head
  • [QUOTE=jakegadget;22756727]Ok I updated the OP with a tutorial. Just remember that items is for sents, weapons is for sweps, and food is for hungermod foods. [editline]12:29PM[/editline] Also to pick weapons up they must have been spawned through the f4 menu or from a gunlab. Guns from the qmenu will not work.[/QUOTE] Could you do an exaple of a CSS weapon from CSS Realistic Weapons please :P Thank you ;) (Also please test if it even works with CSS Realistic Weapons)
  • Avatar of Vinze
  • [CODE]Hook 'DrpPlyUse' Failed: ...\lua\autorun\server\drpinv.lua:61: attempt to index global 'items' (a nil value)[/CODE] Any idea how to fix this? It refuses ANY item to be added to the inventory.
  • Avatar of jakegadget
  • [QUOTE=Crap-Head;22773915]Could you do an exaple of a CSS weapon from CSS Realistic Weapons please :P Thank you ;) (Also please test if it even works with CSS Realistic Weapons)[/QUOTE] It works with all sweps. If I remember this should add the glock: [lua] --register your sweps here weps = { --[[...]]-- ls_sniper = { name = "Silenced Sniper", -- Print name desc = "How did you even get this?" -- description }, weapon_real_glock = { name = "Realistic Glock", -- Print name desc = "A civilian weapon." -- description } --commands on all closing brackets except the last one } [/lua] [QUOTE=Vinze;22779141][CODE]Hook 'DrpPlyUse' Failed: ...\lua\autorun\server\drpinv.lua:61: attempt to index global 'items' (a nil value)[/CODE] Any idea how to fix this? It refuses ANY item to be added to the inventory.[/QUOTE] This means you defined one of the items wrong. Look higher up for errors relating to the actual error.
  • Avatar of Vinze
  • [QUOTE=jakegadget;22780795]It works with all sweps. If I remember this should add the glock: --register your sweps here weps = { --[[...]]-- ls_sniper = { name = "Silenced Sniper", -- Print name desc = "How did you even get this?" -- description }, weapon_real_glock = { name = "Realistic Glock", -- Print name desc = "A civilian weapon." -- description } --commands on all closing brackets except the last one } This means you defined one of the items wrong. Look higher up for errors relating to the actual error.[/QUOTE] Oh, thanks. I'll do that. ALSO: Must the SWEPs be in the gamemode folder? Like, darkrp/entities? May seem stupid, but, I only know the very basics of Lua, so it can't hurt asking.
  • Avatar of redx475
  • You need to add a tab for other inventory items (like normal ents and such)
  • Avatar of Vinze
  • [CODE]-- item definitions -- These are for custom ents. Default shipments, weapons, and food are already handled -- forbidden ent classnames (these will break the addon): --[[ sweps ships foods _size ]]-- --register your normal ents here items = { food = { -- classname name = "Chinese Food", -- Print name desc = "Healthy chinese food, fills your whole hunger bar.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_junk/garbage_takeoutcarton001a.mdl" -- model }, drug = { -- classname name = "Drugs", -- Print name desc = "Duuuuuuuude this stuff makes you BUFF.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/jar01a.mdl" -- model } --commands on all closing brackets except the last one } --register your sweps here weps = { }, weapon_sim_p38 = { name = "Walter P38", -- Print name desc = "German basic sidearm, common amongst troops." -- description }, weapon_sim_panzernoshield = { name = "Panzershreck", -- Print name desc = "German anti-tank weapon." -- description }, weapon_sim_panzerschreck = { name = "Panzershreck", -- Print name desc = "German anti-tank weapon." -- description }, weapon_sim_ppsh41 = { name = "PPSH 41", -- Print name desc = "Highly effective midrange SMG." -- description }, weapon_sim_ru_snade = { name = "Russian Smoke Grenade", -- Print name desc = "Used for distracting the enemy." -- description }, weapon_sim_shotty = { name = "Shortened Trenchgun", -- Print name desc = "Multi-purpouse shotgun." -- description }, weapon_sim_silbolt = { name = "De Lisle Carbine", -- Print name desc = "Silenced sniper rifle." -- description }, weapon_sim_spade = { name = "A Spade", -- Print name desc = "Short shaft, sharp edges." -- description }, weapon_sim_springfield = { name = "Springfield M1903A4", -- Print name desc = "Long ranged sniper rifle." -- description }, weapon_sim_stenne = { name = "Sten Gun", -- Print name desc = "Cheap shortrange SMG." -- description }, weapon_sim_thompson1921 = { name = "Thompson 1921", -- Print name desc = "Highly effective SMG." -- description }, weapon_sim_thompson1944= { name = "Thompson 1944", -- Print name desc = "Militarized version, smaller clip." -- description }, weapon_sim_thompsonM1A1 = { name = "Thompson 1921", -- Print name desc = "Militarized version, smaller clip." -- description }, weapon_sim_toka = { name = "Tokarev TT-33", -- Print name desc = "Basic shortrange Russian sidearm." -- description }, weapon_sim_Trenchgun = { name = "Trenchgun", -- Print name desc = "Heavy pump-action shotgun." -- description }, weapon_sim_us_nade = { name = "Pineapple Grenade", -- Print name desc = "Standard handgrenade." -- description }, weapon_sim_us_snade = { name = "Smoke Grenade", -- Print name desc = "Good for distractions." -- description }, weapon_snark = { name = "Illeagal: Snark", -- Print name desc = "A small, mean little bug who attacks humans." -- description }, weapon_sporelauncher = { name = "Illeagal: Sporefish", -- Print name desc = "A nice little green petfish." -- description }, weapon_tripmine = { name = "Illeagal: Tripmine", -- Print name desc = "Laser-triggered explosive." -- description }, weapon_fireextinguisher = { name = "Fire Extinguisher", -- Print name desc = "Useful in general." -- description } --commands on all closing brackets except the last one } weapon_knife = { name = "Combat Knife", -- Print name desc = "A basic, multi-purpouse melee weapon." -- description }, weapon_pipewrench = { name = "Pipewrench", -- Print name desc = "Proves good as an improvised bulgeon weapon." -- description }, weapon_satchel = { name = "Stachel Charge", -- Print name desc = "A basic remote explosive." -- description }, weapon_sim_BAR = { name = "M1918 BAR", -- Print name desc = "It packs heavy calibur, but lacks in magazine capacity." -- description }, weapon_sim_Bazooka = { name = "Bazooka", -- Print name desc = "The most basic within anti-tank weaponry." -- description }, weapon_sim_browning = { name = "Browling", -- Print name desc = "The Browling HP is an effective midrange sidearm." -- description }, weapon_sim_c96 = { name = "C96 Mauser", -- Print name desc = "One of the first automatic pistols avalible." -- description }, weapon_sim_Colt1911 = { name = "Colt 1911", -- Print name desc = "The Colt 1911 is a very common sidearm." -- description }, weapon_sim_dbarel = { name = "Double-Barreled Shotgun", -- Print name desc = "Very dangerous, but slow." -- description }, weapon_sim_dp30 = { name = "Degtyarev DP 27", -- Print name desc = "What keeps the lines in the glourious red army." -- description }, weapon_sim_endfield = { name = "Enfield Revolver", -- Print name desc = "A basic sidearm." -- description desc = "Deadly German rifle, mid to long range." -- description }, weapon_sim_Luger = { name = "P08 Luger", -- Print name desc = "Heavy German sidearm, common amongst officers." -- description }, weapon_sim_M1carbine = { name = "M1 Carbine", -- Print name desc = "The carbine version of M1 Garand." -- description }, weapon_sim_M1Garand = { name = "M1 Garand", -- Print name desc = "Midrange rifle." -- description }, weapon_sim_M2carbine = { name = "M2 Carbine", -- Print name desc = "Automatic version of the M1 Carbine." -- description }, weapon_sim_m1919A3 = { name = "M1919A3 30Cal", -- Print name desc = "Midrange LMG, with high recoil." -- description }, weapon_sim_mg42 = { name = "MG42", -- Print name desc = "Long-Midrange LMG, with high recoil." -- description }, weapon_sim_mosins = { name = "M91/30 Scoped Mosin Nagant", -- Print name desc = "Long range bolt-action siperrifle." -- description }, weapon_sim_mp40 = { name = "MP40", -- Print name desc = "MP-40, German midrange SMG." -- description }, weapon_sim_mp44 = { name = "STG44", -- Print name desc = "Sturmgewher 44, heavy German assaultrifle." -- description }, weapon_sim_nambu = { name = "Nambu Type 14", -- Print name desc = "Closerange Japaneese Sidearm" -- description }, weapon_sim_p38 = { name = "Walter P38", -- Print name desc = "German basic sidearm, common amongst troops." -- description }, weapon_sim_panzernoshield = { name = "Panzershreck", -- Print name desc = "German anti-tank weapon." -- description }, weapon_sim_panzerschreck = { name = "Panzershreck", -- Print name desc = "German anti-tank weapon." -- description }, weapon_sim_ppsh41 = { name = "PPSH 41", -- Print name desc = "Highly effective midrange SMG." -- description }, weapon_sim_ru_snade = { name = "Russian Smoke Grenade", -- Print name desc = "Used for distracting the enemy." -- description }, weapon_sim_shotty = { name = "Shortened Trenchgun", -- Print name desc = "Multi-purpouse shotgun." -- description }, weapon_sim_silbolt = { name = "De Lisle Carbine", -- Print name desc = "Silenced snip
  • Avatar of jakegadget
  • [QUOTE=Vinze;22785513] -snip- Anything wrong here?[/QUOTE] Many many things. I highlighted the parts where you messed up. You may want to have your server's lua coder add things in the future so you don't mess up the table. [url]http://pastebin.com/bZRGtHPM[/url] [QUOTE=redx475;22783569]You need to add a tab for other inventory items (like normal ents and such)[/QUOTE] That's what the items table is for...
  • Avatar of Vinze
  • [QUOTE=jakegadget;22785999]Many many things. I highlighted the parts where you messed up. You may want to have your server's lua coder add things in the future so you don't mess up the table. [/QUOTE] Sure, thanks for the help. [editline]11:01AM[/editline] Vince... [editline]11:01AM[/editline] What? [editline]11:01AM[/editline] Fix this, please. [editline]11:02AM[/editline] Sure, just a sec.
  • Avatar of robby
  • Thank you for this, I'm working on a great new and fresh idea for DarkRP and it's barely even using DarkRP, the least mingiest (is that even a word :V) server using DarkRP. We have NPCs and shit, and this inventory I'm going to highly modify and use in my gamemode. Thanks a whole load, you saved me a bunch of time! (I had item adding and shit working with pocket, but pocket is shit.) Thanks. Also, what went on with the post above me.
  • Got an error after trying to retrieve a stored entity in the inventory: addons\DerpRP Inv\lua\autorun\server\drpinv.lua:442: attempt to index field 'dt' (a nil value) This happens when I press "drop".Although when I press "use" it strangely drops the item without any error. The item I am using is a radio.
  • Avatar of Andriko1
  • [QUOTE=iggiz;22835705]Got an error after trying to retrieve a stored entity in the inventory: addons\DerpRP Inv\lua\autorun\server\drpinv.lua:442: attempt to index field 'dt' (a nil value) This happens when I press "drop".Although when I press "use" it strangely drops the item without any error. The item I am using is a radio.[/QUOTE] ...paste the code or noone can help you, here have a box
  • [CODE]-- item definitions -- These are for custom ents. Default shipments, weapons, and food are already handled -- forbidden ent classnames (these will break the addon): --[[ sweps ships foods _size ]]-- --register your normal ents here items = { food = { -- classname name = "Chinese Food", -- Print name desc = "Healthy chinese food, fills your whole hunger bar.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_junk/garbage_takeoutcarton001a.mdl" -- model }, drug = { -- classname name = "Drugs", -- Print name desc = "Duuuuuuuude this stuff makes you BUFF.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/jar01a.mdl" -- model }, radios = { -- classname name = "Radio", -- Print name desc = "Radio that plays crap music.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/citizenradio.mdl" -- model } } --register your sweps here weps = { weapon_deagle2 = { name = "Desert Eagle", -- Print name desc = "\"BOOM! Headshot!\"" -- description }, weapon_fiveseven2 = { name = "Fiveseven", -- Print name desc = "It shoots bullets, what else need be said?" -- description }, weapon_glock2 = { name = "Glock", -- Print name desc = "The crappiest gun in the game. Leave it for the popo." -- description }, weapon_p2282 = { name = "P228", -- Print name desc = "Why does it have numbers in its name? Who cares!" -- description }, weapon_ak472 = { name = "AK47", -- Print name desc = "Stereotypical weapon of the terrorist." -- description }, weapon_mp52 = { name = "MP5", -- Print name desc = "Baby-gun used by those SWAT guys." -- description }, weapon_m42 = { name = "M4", -- Print name desc = "Iraqi nightmare." -- description }, weapon_mac102 = { name = "Mac 10", -- Print name desc = "An automatic weapon for the rest of us." -- description }, weapon_pumpshotgun2 = { name = "Pump Shotty", -- Print name desc = "\"Get off my lawn...\"" -- description }, ls_sniper = { name = "Silenced Sniper", -- Print name desc = "How did you even get this?" -- description } --commands on all closing brackets except the last one } --register your foods foodies = { ["models/props/cs_italy/bananna.mdl"] = { -- model name = "Banana", -- Print name desc = "Yummy single banana." -- description }, ["models/props/cs_italy/bananna_bunch.mdl"] = { -- model name = "Banana Bunch", -- Print name desc = "A whole bunch of 'nanas!" -- description }, ["models/props_junk/watermelon01.mdl"] = { -- model name = "Melon", -- Print name desc = "A melon from Garry's own farm." -- description }, ["models/props_junk/glassbottle01a.mdl"] = { -- model name = "Vodka", -- Print name desc = "In Soviet Russia, items put YOU in inventory!" -- description }, ["models/props_junk/popcan01a.mdl"] = { -- model name = "Soda", -- Print name desc = "Straight from Dr. Breen's private reserve." -- description }, ["models/props_junk/garbage_plasticbottle003a.mdl"] = { -- model name = "2-Liter Soda", -- Print name desc = "Don't forget the mentos!" -- description }, ["models/props_junk/garbage_milkcarton002a.mdl"] = { -- model name = "Melk", -- Print name desc = "It's good for your bones or sumthing." -- description }, ["models/props_junk/garbage_glassbottle001a.mdl"] = { -- model name = "B33R", -- Print name desc = "Now you can be just like Mastur Cheef!" -- description }, ["models/props_junk/garbage_glassbottle002a.mdl"] = { -- model name = "Bagged Bud Light", -- Print name desc = "BYOB?" -- description }, ["models/props_junk/garbage_glassbottle003a.mdl"] = { -- model name = "Dos Equis", -- Print name desc = "\"When it is raining, it is because he is sad.\"" -- description }, ["models/props/cs_italy/orange.mdl"] = { -- model name = "Orange", -- Print name desc = "An Orange a day keep der fuhror away." -- description } --commands on all closing brackets except the last one }[/CODE] This is the only file I have edited. Edit: Never mind fixed it myself now.
  • Avatar of weasal167
  • When I Add A Money Printer To The drpshared.lua I Cant put it in my inv in game. idk why. heres the code: --register your normal ents here items = { food = { -- classname name = "Chinese Food", -- Print name desc = "Healthy chinese food, fills your whole hunger bar.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_junk/garbage_takeoutcarton001a.mdl" -- model }, drug = { -- classname name = "Drugs", -- Print name desc = "Duuuuuuuude this stuff makes you BUFF.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/jar01a.mdl" -- model }, microwave = { -- classname name = "Microwave", -- Print name desc = "Try not to burn your self, k?", -- description useable = false, --can they use it from the invenotry? max = 1, --max that can be carried, 0 for infinate model = "models/props/cs_office/microwave.mdl" -- model }, money_printer = { -- classname name = "Money Printer", -- Print name desc = "Don't let it blow up in ur pocket...", -- description useable = false, --can they use it from the invenotry? max = 2,--max that can be carried, 0 for infinate model = "models/props_c17/consolebox01a.mdl" -- model } } Edit: Srry for not reading post's above and posting this 2nd Edit: Fixed it. idk what was wrong. [editline]02:37AM[/editline] Any way to add durgz mod to this? i tried but no success.
  • Avatar of kill3r
  • [QUOTE=ManolisV;22711211]silly[/QUOTE] Says the one who can't use correct grammar, or spell.
  • Avatar of h4rDm0d
  • sometimes the items in the inventory dont show up or get deleted / mixed up with other players its annoying
  • Avatar of weasal167
  • oh and another thing, this breaks your "Money Printer" limit. The limit on my server and and my friends server is 2, but when we put the money printer in the INV you can buy Another printer. and again and again etc. i saw some guy who was hiding in the map with 30 printers. :o
  • Avatar of robby
  • [QUOTE=weasal167;22880449]oh and another thing, this breaks your "Money Printer" limit. The limit on my server and and my friends server is 2, but when we put the money printer in the INV you can buy Another printer. and again and again etc. i saw some guy who was hiding in the map with 30 printers. :o[/QUOTE] If they guy doesn't update it to fix this I can fix it for you guys.
  • I get an error when i start what do i do: [code]-- item definitions -- These are for custom ents. Default shipments, weapons, and food are already handled -- forbidden ent classnames (these will break the addon): --[[ sweps ships foods _size ]]-- --register your normal ents here items = { food = { -- classname name = "Chinese Food", -- Print name desc = "Healthy chinese food, fills your whole hunger bar.", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_junk/garbage_takeoutcarton001a.mdl" -- model }, drug = { -- classname name = "Drugs", -- Print name desc = "Duuuuuuuude...", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/jar01a.mdl" -- model } , money_printer_mini = { -- classname name = "Money Printer - Mini", -- Print name desc = "It prints less money!", -- description useable = false, --can they use it from the invenotry? max = 4, --max that can be carried, 0 for infinate model = "models/props_c17/consolebox05a.mdl" -- model } , money_printer = { -- classname name = "Money Printer - Normal", -- Print name desc = "It prints money!", -- description useable = false, --can they use it from the invenotry? max = 3, --max that can be carried, 0 for infinate model = "models/props_c17/consolebox01a.mdl" -- model } , money_printer_medium = { -- classname name = "Money Printer - Medium", -- Print name desc = "It prints more money!", -- description useable = false, --can they use it from the invenotry? max = 2, --max that can be carried, 0 for infinate model = "models/props_lab/powerbox01a.mdl" -- model } , money_printer_large = { -- classname name = "Money Printer - Large", -- Print name desc = "It prints even more money!", -- description useable = false, --can they use it from the invenotry? max = 1, --max that can be carried, 0 for infinate model = "models/props_lab/reciever_cart.mdl" -- model } , money_printer_cooler = { -- classname name = "Money Printer Cooler", -- Print name desc = "It cools your printer!", -- description useable = false, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/reciever01a.mdl" -- model } , money_printer_collector = { -- classname name = "Money Printer Collector", -- Print name desc = "It collects your money!", -- description useable = false, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_lab/box01b.mdl" -- model } , microwave = { -- classname name = "Microwave", -- Print name desc = "feed your face!", -- description useable = false, --can they use it from the invenotry? max = 1, --max that can be carried, 0 for infinate model = "models/props/cs_office/microwave.mdl" -- model } , letter = { -- classname name = "Letter", -- Print name desc = "Ooo a letter!", -- description useable = true, --can they use it from the invenotry? max = 0, --max that can be carried, 0 for infinate model = "models/props_c17/paper01.mdl" -- model } , gunlab = { -- classname name = "Gunlab", -- Print name desc = "Makes guns!", -- description useable = false, --can they use it from the invenotry? max = 1, --max that can be carried, 0 for infinate model = "models/props_c17/TrapPropeller_Engine.mdl" -- model } } --register your sweps here weps = { stunstick = { name = "Stun Baton", -- Print name desc = "Bzzzzzttt!" -- description }, med_kit = { name = "Medkit", -- Print name desc = "Heal's people..." -- description }, lockpick = { name = "Lockpick", -- Print name desc = "Opens doors..." -- description }, keypad_cracker = { name = "Keypad Cracker", -- Print name desc = "Hacks keypads..." -- description }, door_ram = { name = "Battering Ram", -- Print name desc = "Go Go Go!" -- description }, arrest_stick = { name = "Arrest Baton", -- Print name desc = "Sends people to jail!" -- description }, unarrest_stick = { name = "Unarrest Baton", -- Print name desc = "Takes people out of jail!" -- description }, weapon_real_cs_desert_eagle = { name = "DESERT EAGLE .50", -- Print name desc = "Damage: 50% \nRecoil: 60% \nPrecision: 86% \nType: Semi-Automatic" -- description }, weapon_real_cs_five-seven = { name = "FN FIVE-SEVEN", -- Print name desc = "Damage: 10% \nRecoil: 6% \nPrecision: 89% \nType: Semi-Automatic" -- description }, weapon_real_cs_glock18 = { name = "GLOCK 18", -- Print name desc = "Damage: 12% \nRecoil: 15% \nPrecision: 86% \nType: Semi-Automatic and Burst \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_p228 = { name = "SIG-SAUER P228", -- Print name desc = "Damage: 15% \nRecoil: 8% \nPrecision: 87.5% \nType: Semi-Automatic" -- description }, weapon_real_cs_ak47 = { name = "KALASHNIKOV AK-47", -- Print name desc = "Damage: 33% \nRecoil: 10% \nPrecision: 77% \nType: Automatic \nRate of Fire: 600 rounds per minute \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_mp5a5 = { name = "HK MP-5A5", -- Print name desc = "Damage: 17% \nRecoil: 6% \nPrecision: 83% \nType: Automatic \nRate of Fire: 800 rounds per minute \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_m4a1 = { name = "COLT M4A1", -- Print name desc = "Damage: 20% \nRecoil: 5% \nPrecision: 88% \nType: Automatic \nRate of Fire: 780 rounds per minute \n\nChange Mode: E + Right Click \nSilence Mode: E + Left Click" -- description }, weapon_real_cs_mac10 = { name = "INGRAM MAC M10", -- Print name desc = "Damage: 20% \nRecoil: 7% \nPrecision: 76% \nType: Automatic \nRate of Fire: 1000 rounds per minute \n\nChange Mode: E + Right Clic" -- description }, weapon_real_cs_pump_shotgun = { name = "BENELLI M3 SUPER 90", -- Print name desc = "Buckshot Damage (Per buckshot lead): 9% \nSlug Damage (Per slug): 88% \nRecoil: 50% \nBuckshot Precision: 55% \nSlug Precision: 85% \nType: Pump-Action \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_aug = { name = "STEYR AUG A1", -- Print name desc = "Damage: 22% \nRecoil: 12% \nPrecision: 93% \nType: Automatic \nRate of Fire: 650 rounds per minute \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_awp = { name = "UTG L96 AWP SNIPER", -- Print name desc = "Damage: 96% \nRecoil: 80% \nPrecision: 99.9% \nType: Bolt Action" -- description }, weapon_real_cs_elites = { name = "DUAL BERETTA ELITES", -- Print name desc = "Damage: 15% \nRecoil: 5% \nPrecision: 84% \nType: Semi-Automatic \n\nLeft click to shoot from the left \nRight click to shoot from the right" -- description }, weapon_real_cs_famas = { name = "FAMAS F1", -- Print name desc = "Damage: 17% \nRecoil: 4% \nPrecision: 85% \nType: Automatic and Burst \nRate of Fire: 875 rounds per minute \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_flash = { name = "FLASH GRENADE", -- Print name desc = "Stun grenades are used to confuse, disorient, \nor distract a potential threat. \nA stun grenade can seriously degrade the \ncombat effectiveness of affected personnel \nfor up to a minute. \n\nLeft click to throw your grenade on a long distance \nRight click to throw your grenade on a short distance" -- description }, weapon_real_cs_galil = { name = "GALIL SAR 5.56MM", -- Print name desc = "Damage: 25% \nRecoil: 6.5% \nPrecision: 83% \nType: Automatic \nRate of Fire: 650 rounds per minute \n\nChange Mode: E + Right Click" -- description }, weapon_real_cs_grenade = { name = "EXPLOSIVE GRENADE", -- Print name desc = "The grenade is an anti-personnel device \nthat is designed to damage its target with\n explosive power alone. \n\nLeft click to throw your grenade on a long distance \nRight click to throw your grenade on a short distance" -- description }, weapon_real_cs_knife = { name = "KNIFE",
  • Avatar of robby
  • -snip- Tried to tell the guy above to use lua tags, then noticed the code was huge.
  • Avatar of jakegadget
  • [QUOTE=weasal167;22880449]oh and another thing, this breaks your "Money Printer" limit. The limit on my server and and my friends server is 2, but when we put the money printer in the INV you can buy Another printer. and again and again etc. i saw some guy who was hiding in the map with 30 printers. :o[/QUOTE] The main problem with that is that there is a different limit variable for each item, I believe drugs have one, money printers have one, etc. Most of the people here wouldn't know how to find that variable if I did add it to the system. I'll try to think of a fix and if anyone has any ideas, I'm all ears.
  • Avatar of yokko
  • [QUOTE=iggiz;22845873] Edit: Never mind fixed it myself now.[/QUOTE] Can you tell me how did you fixed it? i got that error too. :\ \lua\autorun\server\drpinv.lua:442: attempt to index field 'dt' (a nil value) EDIT: oh i fixed it (lol) the error in the entity, just include it into entity's shared.lua [CODE]function ENT:SetupDataTables() self:DTVar("Entity",1,"owning_ent") end[/CODE]
  • Avatar of robby
  • [QUOTE=jakegadget;23039025]The main problem with that is that there is a different limit variable for each item, I believe drugs have one, money printers have one, etc. Most of the people here wouldn't know how to find that variable if I did add it to the system. I'll try to think of a fix and if anyone has any ideas, I'm all ears.[/QUOTE] Easy, the way I was going to do it was make it so if they pick up a money printer it just re-adds it to the amount that the player has. [lua] ply["maxmoneyprinter"] = ply["maxmoneyprinter"]+1 [/lua] Something like that. I'm not sure of what the table name is. If you go/search through the code you could easily find it.