enabled use of weapon_map_base in default ZS
Prevented weapon_map_base from being deleted so that people could use it as a tool for creating map made custom weapons in non-ze game types.
This commit is contained in:
parent
3e23a89326
commit
1f401dba4e
1 changed files with 13 additions and 11 deletions
|
@ -596,7 +596,9 @@ end
|
|||
|
||||
function GM:ReplaceMapWeapons()
|
||||
for _, ent in pairs(ents.FindByClass("weapon_*")) do
|
||||
if string.sub(ent:GetClass(), 1, 10) == "weapon_zs_" then
|
||||
local wepclass = ent:GetClass()
|
||||
if wepclass ~= "weapon_map_base" then
|
||||
if string.sub(wepclass, 1, 10) == "weapon_zs_" then
|
||||
local wep = ents.Create("prop_weapon")
|
||||
if wep:IsValid() then
|
||||
wep:SetPos(ent:GetPos())
|
||||
|
@ -607,10 +609,10 @@ function GM:ReplaceMapWeapons()
|
|||
wep.IsPreplaced = true
|
||||
end
|
||||
end
|
||||
|
||||
ent:Remove()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
local ammoreplacements = {
|
||||
["item_ammo_357"] = "357",
|
||||
|
|
Loading…
Reference in a new issue