if CLIENT then return end local AmmoList = { "item_ammo_pistol", "item_ammo_smg1", "item_ammo_ar2", "item_ammo_357", "item_ammo_crossbow", "item_box_buckshot", "item_rpg_round" } local PistList = { "weapon_ttt_glock" "weapon_zm_pistol" } local SMGList = { "weapon_zm_mac10", "weapon_ttt_mp5" } local RifList = { "weapon_zm_rifle", "weapon_ttt_m16" } local FoodList = { "item_battery", "item_healthkit", "item_healthvial", "weapon_pistol", "weapon_smg1", "weapon_frag" } local MedList = { "weapon_ar2", "weapon_shotgun", "item_ammo_ar2_altfire", "item_ammo_smg1_grenade" } local FlimMelList = { "weapon_ttt_flimsy_axe", "weapon_ttt_flimsy_bat", "weapon_ttt_flimsy_katana", "weapon_ttt_flimsy_keyboard", "weapon_ttt_flimsy_plank", "weapon_ttt_flimsy_shovel", "weapon_ttt_flimsy_sledgehammer" } local SturMelList = { "weapon_ttt_sturdy_axe", "weapon_ttt_sturdy_bat", "weapon_ttt_sturdy_katana", "weapon_ttt_sturdy_keyboard", "weapon_ttt_sturdy_plank", "weapon_ttt_sturdy_shovel", "weapon_ttt_sturdy_sledgehammer" } local HighList = { "weapon_zm_shotgun", "weapon_ttt_pump_shotgun", "weapon_ttt_awp", "weapon_ttt_ak47" } hook.Add("OnNPCKilled", "DropWeaponOnNPCKilled", function(npc, killer) local rndweapon = nil chance = math.random(1,100) if chance < 50 then return end if chance > 51 && chance < 70 then rndweapon = table.Random(AmmoList) end if chance > 71 && chance < 85 then rndweapon = table.Random(PistList) end if chance > 86 && chance < 95 then rndweapon = table.Random(SMGList) end if chance > 96 && chance < 100 then rndweapon = table.Random(RifList) end if chance > 51 && chance < 70 then rndweapon = table.Random(FoodList) end if chance > 71 && chance < 85 then rndweapon = table.Random(MedList) end if chance > 86 && chance < 95 then rndweapon = table.Random(FlimMelList) end if chance > 96 && chance < 100 then rndweapon = table.Random(SturMelList) end if chance > 96 && chance < 100 then rndweapon = table.Random(HighList) end weapon = ents.Create(rndweapon) weapon:SetPos(npc:LocalToWorld(npc:OBBCenter())) weapon:Spawn() end