mirror of
https://github.com/lifestorm/wnsrc.git
synced 2025-12-17 05:43:46 +03:00
Upload
This commit is contained in:
56
lua/tfa/att/am_gib.lua
Normal file
56
lua/tfa/att/am_gib.lua
Normal file
@@ -0,0 +1,56 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "G.I.B Ammunition"
|
||||
ATTACHMENT.ShortName = "GIB" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Always gibs enemies", TFA.Attachments.Colors["+"], "10% more damage", TFA.Attachments.Colors["-"], "20% more recoil", TFA.Attachments.Colors["-"], "10% more spread" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_gib.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["DamageType"] = function(wep,stat) return bit.bor( stat or DMG_BULLET, DMG_ALWAYSGIB ) end,
|
||||
["Damage"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["Spread"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.2 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 1.2 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
55
lua/tfa/att/am_magnum.lua
Normal file
55
lua/tfa/att/am_magnum.lua
Normal file
@@ -0,0 +1,55 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Magnum Ammunition"
|
||||
ATTACHMENT.ShortName = "MAG" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "10% more damage", TFA.Attachments.Colors["-"], "15% more recoil", TFA.Attachments.Colors["-"], "10% more spread" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_magnum.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["Damage"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["Spread"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 1.15 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
54
lua/tfa/att/am_match.lua
Normal file
54
lua/tfa/att/am_match.lua
Normal file
@@ -0,0 +1,54 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Match Ammunition"
|
||||
ATTACHMENT.ShortName = "Match" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "20% lower spread kick", "10% lower recoil", TFA.Attachments.Colors["-"], "20% lower spread recovery" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_match.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["SpreadIncrement"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["SpreadRecovery"] = function( wep, stat ) return stat * 0.8 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 0.9 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
37
lua/tfa/att/ammo_dragonbreath_shells.lua
Normal file
37
lua/tfa/att/ammo_dragonbreath_shells.lua
Normal file
@@ -0,0 +1,37 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Dragon's Breath Shells"
|
||||
ATTACHMENT.ShortName = "Fire" -- Abbreviation, 5 chars or less please
|
||||
ATTACHMENT.Icon = "entities/dragon_breach_shell.png" -- Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
|
||||
ATTACHMENT.Description = {
|
||||
TFA.Attachments.Colors["+"], "Ignites enemies or objects",
|
||||
TFA.Attachments.Colors["+"], "Stun enemies with fire",
|
||||
TFA.Attachments.Colors["+"], "+8 Pellets",
|
||||
TFA.Attachments.Colors["-"], "+100% Spread", "-50% Damage" }
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["DamageType"] = function(wep,stat) return bit.bor( stat or 0, DMG_BURN ) end,
|
||||
["NumShots"] = function( wep, stat ) return stat + 8 end,
|
||||
["Spread"] = function(wep,stat) return stat * 2 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.5 end,
|
||||
["Damage"] = function(wep,stat) return stat * 0.5 end,
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
38
lua/tfa/att/ammo_flechette_shells.lua
Normal file
38
lua/tfa/att/ammo_flechette_shells.lua
Normal file
@@ -0,0 +1,38 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Flechette Shells" -- Fully attachment name
|
||||
ATTACHMENT.ShortName = "Flechette" -- Abbreviation, 5 chars or less please
|
||||
ATTACHMENT.Icon = "entities/flechetterounds.png" -- Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["="], "Flechette Darts",
|
||||
TFA.AttachmentColors["+"], "Improves the accuracy",
|
||||
TFA.AttachmentColors["+"], "Improves the penetration",
|
||||
TFA.AttachmentColors["+"], "+8 Pellets",
|
||||
TFA.AttachmentColors["-"], "-50% Damage"}
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["IronAccuracy"] = function( wep, stat ) return math.max( stat * 0.75 ) end,
|
||||
["Spread"] = function( wep, stat ) return math.max( stat * 0.75 ) end,
|
||||
["PenetrationMultiplier"] = function( wep, stat ) return stat * 2 end,
|
||||
["NumShots"] = function( wep, stat ) return stat + 8 end,
|
||||
["Damage"] = function(wep,stat) return stat * 0.50 end,
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
57
lua/tfa/att/ar15_ext_mag_60.lua
Normal file
57
lua/tfa/att/ar15_ext_mag_60.lua
Normal file
@@ -0,0 +1,57 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Extended Magazine"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "Increases magazine capacity to 60 rounds."
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/ins2_att_mag_ext_carbine_30rd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "MAG+"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["mag"] = {
|
||||
["active"] = false,
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["active"] = true,
|
||||
}
|
||||
},
|
||||
["WElements"] = {
|
||||
["mag"] = {
|
||||
["active"] = false,
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["active"] = true,
|
||||
}
|
||||
},
|
||||
|
||||
["Primary"] = {
|
||||
["ClipSize"] = function(wep, val)
|
||||
return wep.Primary.ClipSize_Drum or 60
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
69
lua/tfa/att/ar15_ext_ris_barrel.lua
Normal file
69
lua/tfa/att/ar15_ext_ris_barrel.lua
Normal file
@@ -0,0 +1,69 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "RIS Extended Handguard"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "Activates Laser Sight and GL", "5% lower recoil", TFA.AttachmentColors["-"], "25% lower base accuracy", "Somewhat slower movespeed" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_ris_e.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "RISE"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basebarrel"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["risextbarrel"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[2] = 4
|
||||
},
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(1.1, 1.1, 1.1), pos = Vector(0, -13, -0.1), angle = Angle(0, 180, 0) },
|
||||
},
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(0.7, 0.7, 0.7), pos = Vector(14, -1.4, 0.75), angle = Angle(0, 180, 0) },
|
||||
},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Spread"] = function(wep,stat) return stat * 1.5 end,
|
||||
},
|
||||
["MoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
["IronSightsMoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
if wep.WorldModelKitOld then
|
||||
wep.WorldModel = wep.WorldModelKitOld
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
67
lua/tfa/att/ar15_m16_barrel.lua
Normal file
67
lua/tfa/att/ar15_m16_barrel.lua
Normal file
@@ -0,0 +1,67 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "M16 Handguard"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "60% less vertical recoil", "20% less horizontal recoil", TFA.AttachmentColors["-"], "10% lower base accuracy", "Somewhat slower movespeed" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_m16_b.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "M16B"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basebarrel"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["m16barrel"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[2] = 3
|
||||
},
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(1.1, 1.1, 1.1), pos = Vector(0, -13, -0.1), angle = Angle(0, 180, 0) },
|
||||
},
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(0.7, 0.7, 0.7), pos = Vector(14, -1.4, 0.75), angle = Angle(0, 180, 0) },
|
||||
},
|
||||
["Primary"] = {
|
||||
["Spread"] = function(wep,stat) return stat * 1.2 end,
|
||||
["IronAccuracy"] = function(wep,stat) return stat * 0.9 end,
|
||||
},
|
||||
["MoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
["IronSightsMoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
if wep.WorldModelKitOld then
|
||||
wep.WorldModel = wep.WorldModelKitOld
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
62
lua/tfa/att/ar15_m16_stock.lua
Normal file
62
lua/tfa/att/ar15_m16_stock.lua
Normal file
@@ -0,0 +1,62 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "M16 Stock"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "70% less vertical recoil", "30% less horizontal recoil", TFA.AttachmentColors["-"], "Somewhat slower movespeed" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_m16_s.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "M16S"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basestock"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["m16stock"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[1] = 1
|
||||
},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function(wep,stat) return stat * 0.3 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.3 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.7 end
|
||||
},
|
||||
["MoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
["IronSightsMoveSpeed"] = function(wep,stat) return stat * 0.95 end,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
62
lua/tfa/att/ar15_magpul_barrel.lua
Normal file
62
lua/tfa/att/ar15_magpul_barrel.lua
Normal file
@@ -0,0 +1,62 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Magpul Handguard"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "60% less vertical recoil", "20% less horizontal recoil", "10% more ironsight accuracy", TFA.AttachmentColors["-"], "20% lower base accuracy" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_moe_b.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "MOEB"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basebarrel"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["magpulbarrel"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[2] = 2
|
||||
},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function(wep,stat) return stat * 0.3 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.3 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.7 end,
|
||||
["Spread"] = function(wep,stat) return stat * 1.1 end,
|
||||
["IronAccuracy"] = function(wep,stat) return stat * 1.1 end
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
60
lua/tfa/att/ar15_magpul_stock.lua
Normal file
60
lua/tfa/att/ar15_magpul_stock.lua
Normal file
@@ -0,0 +1,60 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Magpul Stock"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "30% less vertical recoil", "10% less horizontal recoil" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_moe_s.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "MOE"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basestock"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["magpulstock"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[1] = 2
|
||||
},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function(wep,stat) return stat * 0.7 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.7 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.9 end
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
58
lua/tfa/att/ar15_ris_barrel.lua
Normal file
58
lua/tfa/att/ar15_ris_barrel.lua
Normal file
@@ -0,0 +1,58 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "RIS Handguard"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "Activates Laser Sight and GL", TFA.AttachmentColors["-"], "5% lower base accuracy" }
|
||||
ATTACHMENT.Icon = "entities/ar15_att_ris.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "RIS"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["basebarrel"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["risbarrel"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Bodygroups_W"] = {
|
||||
[2] = 1
|
||||
},
|
||||
["Primary"] = {
|
||||
["Spread"] = function(wep,stat) return stat * 0.8 end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
45
lua/tfa/att/ar15_si_folded.lua
Normal file
45
lua/tfa/att/ar15_si_folded.lua
Normal file
@@ -0,0 +1,45 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Folded Sights"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "Easier to aim", TFA.AttachmentColors["-"], "5% higher zoom time" }
|
||||
ATTACHMENT.Icon = "entities/ins2_att_fsi.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "FSI"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["sights_folded"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["sight_fsi"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WElements"] = {
|
||||
["sights_folded"] = {
|
||||
["active"] = false
|
||||
},
|
||||
["sight_fsi"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1.05 end
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
101
lua/tfa/att/at_grip.lua
Normal file
101
lua/tfa/att/at_grip.lua
Normal file
@@ -0,0 +1,101 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Foregrip"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "30% lower H-recoil", TFA.Attachments.Colors["+"], "10% lower V-recoil", TFA.Attachments.Colors["-"], "10% higher spread recovery" }
|
||||
ATTACHMENT.Icon = "entities/tfa_si_eotech.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "FGRIP"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
local defaultbl = { scale = Vector(1, 1, 1), pos = Vector(0, 0, 0), angle = Angle(0, 0, 0) }
|
||||
|
||||
local function LerpBoneMods( t, b1, b2 )
|
||||
local tbl = table.Copy(b1)
|
||||
for k,v in pairs(b2) do
|
||||
if not tbl[k] then
|
||||
tbl[k] = table.Copy(defaultbl)
|
||||
end
|
||||
tbl[k].scale = LerpVector( t, tbl[k].scale, v.scale )
|
||||
tbl[k].pos = LerpVector( t, tbl[k].pos, v.pos )
|
||||
tbl[k].angle = LerpAngle( t, tbl[k].angle, v.angle )
|
||||
end
|
||||
return tbl
|
||||
end
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelElements"] = {
|
||||
["foregrip"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WorldModelElements"] = {
|
||||
["foregrip"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Primary"] = {
|
||||
["SpreadRecovery"] = function(wep,stat) return stat * 1.1 end,
|
||||
["KickUp"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.7 end,
|
||||
},
|
||||
["ViewModelBoneMods"] = function(wep,tbl)
|
||||
if wep.GripBoneMods then
|
||||
wep.GripFactor = wep.GripFactor or 0
|
||||
local CanGrip = true
|
||||
if wep.GripBadActivities and wep.GripBadActivities[ wep:GetLastActivity() ] and wep:VMIV() then
|
||||
local cyc = wep.OwnerViewModel:GetCycle()
|
||||
if cyc > wep.GripBadActivities[ wep:GetLastActivity() ][1] and cyc < wep.GripBadActivities[ wep:GetLastActivity() ][2] then
|
||||
CanGrip = false
|
||||
end
|
||||
end
|
||||
wep.GripFactor = math.Approach( wep.GripFactor, CanGrip and 1 or 0, ( ( CanGrip and 1 or 0 ) - wep.GripFactor ) * TFA.FrameTime() * ( wep.GripLerpSpeed or 20 ) )
|
||||
return LerpBoneMods( wep.GripFactor, tbl, wep.GripBoneMods )
|
||||
end
|
||||
end
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.GripFactor = 0
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.GripFactor = 0
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
66
lua/tfa/att/base.lua
Normal file
66
lua/tfa/att/base.lua
Normal file
@@ -0,0 +1,66 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
-- ATTACHMENT.TFADataVersion = 1 -- Uncomment this in your attachment file
|
||||
-- If it is undefined, if fallback to 0 and WeaponTable gets migrated like SWEPs do
|
||||
|
||||
ATTACHMENT.Name = "Base Attachment"
|
||||
ATTACHMENT.ShortName = nil --Abbreviation, 5 chars or less please
|
||||
ATTACHMENT.Description = {} --TFA.Attachments.Colors["+"], "Does something good", TFA.Attachments.Colors["-"], "Does something bad" }
|
||||
ATTACHMENT.Icon = nil --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.WeaponTable = {} --put replacements for your SWEP talbe in here e.g. ["Primary"] = {}
|
||||
|
||||
ATTACHMENT.DInv2_GridSizeX = nil -- DInventory/2 Specific. Determines attachment's width in grid.
|
||||
ATTACHMENT.DInv2_GridSizeY = nil -- DInventory/2 Specific. Determines attachment's height in grid.
|
||||
ATTACHMENT.DInv2_Volume = nil -- DInventory/2 Specific. Determines attachment's volume in liters.
|
||||
ATTACHMENT.DInv2_Mass = nil -- DInventory/2 Specific. Determines attachment's mass in kilograms.
|
||||
ATTACHMENT.DInv2_StackSize = nil -- DInventory/2 Specific. Determines attachment's maximal stack size.
|
||||
|
||||
ATTACHMENT.TFADataVersion = nil -- TFA.LatestDataVersion, specifies version of TFA Weapon Data this attachment utilize in `WeaponTable`
|
||||
-- 0 is original, M9K-like data, and is the fallback if `TFADataVersion` is undefined
|
||||
|
||||
function ATTACHMENT:CanAttach(wep)
|
||||
return true --can be overridden per-attachment
|
||||
end
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
68
lua/tfa/att/br_supp.lua
Normal file
68
lua/tfa/att/br_supp.lua
Normal file
@@ -0,0 +1,68 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Suppressor"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Less firing noise", TFA.Attachments.Colors["-"], "10% less spread", TFA.Attachments.Colors["-"], "5% less damage", TFA.Attachments.Colors["-"], "10% less vertical recoil" }
|
||||
ATTACHMENT.Icon = "entities/tfa_br_supp.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SUPP"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WorldModelElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Primary"] = {
|
||||
["Damage"] = function(wep,stat) return stat * 0.95 end,
|
||||
["KickUp"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Spread"] = function(wep,stat) return stat * 0.9 end,
|
||||
["IronAccuracy"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Sound"] = function(wep,stat) return wep.Primary.SilencedSound or stat end
|
||||
},
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_silenced",
|
||||
["MuzzleAttachmentMod"] = function(wep,stat) return wep.MuzzleAttachmentSilenced or stat end
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
35
lua/tfa/att/fas2tfa_acc_bayonet.lua
Normal file
35
lua/tfa/att/fas2tfa_acc_bayonet.lua
Normal file
@@ -0,0 +1,35 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Unfolded Bayonet"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["="], "Use with suitzoom bind (+zoom)",
|
||||
TFA.AttachmentColors["+"], "+75% melee damage",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2sksunfld.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "UNFLD"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[1] = 2},
|
||||
["Bodygroups_W"] = {[2] = 3},
|
||||
["Secondary"] = {
|
||||
["BashDamage"] = function( wep, stat ) return stat * 1.75 end,
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
28
lua/tfa/att/fas2tfa_acc_bayonetfolded.lua
Normal file
28
lua/tfa/att/fas2tfa_acc_bayonetfolded.lua
Normal file
@@ -0,0 +1,28 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Folded Bayonet"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfafas2sksfld.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "FOLD"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[1] = 1},
|
||||
["Bodygroups_W"] = {[2] = 1},
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
32
lua/tfa/att/fas2tfa_ammo_frag.lua
Normal file
32
lua/tfa/att/fas2tfa_ammo_frag.lua
Normal file
@@ -0,0 +1,32 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Magnum Shells"
|
||||
ATTACHMENT.ShortName = "MGNM" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Increases critical damage", "+60% damage", TFA.Attachments.Colors["-"], "Decreases hit chance at range", "-5 pellets" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_fragshell.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["StaticRecoilFactor"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["PenetrationMultiplier"] = function( wep, stat ) return wep.Primary.NumShots * stat * 1 end,
|
||||
["Damage"] = function(wep,stat) return stat * 1.60 end,
|
||||
["NumShots"] = function(wep,stat) return stat / 2 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
37
lua/tfa/att/fas2tfa_ammo_incn.lua
Normal file
37
lua/tfa/att/fas2tfa_ammo_incn.lua
Normal file
@@ -0,0 +1,37 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Pyro Shells"
|
||||
ATTACHMENT.ShortName = "PYRO" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Ignites flammable objects", "Fun with VFire", "+7 pellets", "-35% overall recoil", TFA.Attachments.Colors["-"], "+200% spread", "-55% total damage" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_incenshell.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * .65 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * .65 end,
|
||||
["KickHorizontal"] = function( wep, stat ) return stat * .65 end,
|
||||
["StaticRecoilFactor"] = function( wep, stat ) return stat * .8 end,
|
||||
["DamageType"] = function(wep,stat) return bit.bor( stat or 0, DMG_BURN ) end,
|
||||
["Spread"] = function(wep,stat) return stat * 2 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 3 end,
|
||||
["Damage"] = function(wep,stat) return stat / 2.55 end,
|
||||
["NumShots"] = function(wep,stat) return stat * 1.7 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
43
lua/tfa/att/fas2tfa_ammo_slug.lua
Normal file
43
lua/tfa/att/fas2tfa_ammo_slug.lua
Normal file
@@ -0,0 +1,43 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Slug Shells"
|
||||
ATTACHMENT.ShortName = "SLUG" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Increases accuracy", "Standard with the KS23's rifled barrel", TFA.Attachments.Colors["-"], "-20% total damage", "-9 pellets" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_slug.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["Damage"] = function( wep, stat ) return wep.Primary.NumShots * stat * 0.8 end,
|
||||
["PenetrationMultiplier"] = function( wep, stat ) return wep.Primary.NumShots * stat * 3 end,
|
||||
["NumShots"] = function( wep, stat ) return 1, true end,
|
||||
["Spread"] = function( wep, stat ) return stat - 0.025 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat - 0.04 end,
|
||||
["Range"] = function( wep, stat ) return stat + 100 * 39.370 end
|
||||
},
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_generic",
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.Type = "Pump-action carbine, 23×75mmR"
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.Type = "Pump-action shotgun, 23×75mmR"
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
41
lua/tfa/att/fas2tfa_g3_adjstock.lua
Normal file
41
lua/tfa/att/fas2tfa_g3_adjstock.lua
Normal file
@@ -0,0 +1,41 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Adjustable Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "-10% overall recoil", "-30% aim recoil",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2adjstk.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "ADJ."
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[2] = 1},
|
||||
["Bodygroups_W"] = {[2] = 2},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["KickHorizontal"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["IronRecoilMultiplier"] = function( wep, stat ) return stat * 0.7 end,
|
||||
["StaticRecoilFactor"] = function( wep, stat ) return stat * 0.9 end,
|
||||
},
|
||||
["BlowbackVector"] = Vector(0,-3,-.02),
|
||||
--["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.975 end,
|
||||
--["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 0.85 end,
|
||||
|
||||
}
|
||||
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
50
lua/tfa/att/fas2tfa_g3_cqb.lua
Normal file
50
lua/tfa/att/fas2tfa_g3_cqb.lua
Normal file
@@ -0,0 +1,50 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "CQB Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+10% movement speed",
|
||||
TFA.AttachmentColors["-"], "+20% recoil", "-20% accuracy"
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2g3barcqb.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "CQB"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.8, .8, .8), pos = Vector(-14.75, .85, .41), angle = Angle(-90, 90, 0) },
|
||||
["A_Underbarrel"] = { scale = Vector(.6, .6, .6), pos = Vector(-12.5, .85, 3.41), angle = Angle(-90, 90, 0) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(9, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(6.5, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["Left Polex Phalange1"] = { scale = Vector(1, 1, 1), pos = Vector(0, 0, 0), angle = Angle(-12, 1, 25) },
|
||||
},
|
||||
["Bodygroups_V"] = {[1] = 1},
|
||||
["Bodygroups_W"] = {[1] = 1},
|
||||
["IronSightsPos"] = Vector(-2.658, -5, -.022),
|
||||
["IronSightsAng"] = Vector(0.515, 0.002, 0),
|
||||
["Primary"] = {
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["Spread"] = function( wep, stat ) return stat * 1.2 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.2 end,
|
||||
["Sound"] = function(wep,stat) return "FAS2TFA_G3.2" or stat end,
|
||||
["SilencedSound"] = function(wep,stat) return "FAS2TFA_G3.4" or stat end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.9 end,
|
||||
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
44
lua/tfa/att/fas2tfa_g3_fullstock.lua
Normal file
44
lua/tfa/att/fas2tfa_g3_fullstock.lua
Normal file
@@ -0,0 +1,44 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Full Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+20% accuracy", "-20% overall recoil", "-70% aim recoil",
|
||||
TFA.AttachmentColors["-"], "-10% aim speed",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2g3fulstk.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "FULL"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[2] = 2},
|
||||
["Bodygroups_W"] = {[2] = 1},
|
||||
["Primary"] = {
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 0.5 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 0.8 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 0.8 end,
|
||||
["KickHorizontal"] = function( wep, stat ) return stat * 0.8 end,
|
||||
["IronRecoilMultiplier"] = function( wep, stat ) return stat * 0.3 end,
|
||||
["StaticRecoilFactor"] = function( wep, stat ) return stat * 0.9 end,
|
||||
},
|
||||
["BlowbackVector"] = Vector(0,-2.25,.005),
|
||||
["IronSightTime"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 0.975 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 0.9 end,
|
||||
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
42
lua/tfa/att/fas2tfa_ks23_7rnd.lua
Normal file
42
lua/tfa/att/fas2tfa_ks23_7rnd.lua
Normal file
@@ -0,0 +1,42 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Extended Tube, 6rnd"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "Increases internal magazine capacity", TFA.Attachments.Colors["-"],"Attaching & detaching empties magazine",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/ks23tube.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "+MAG"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[2] = 1},
|
||||
["Bodygroups_W"] = {[2] = 1},
|
||||
["Primary"] = {
|
||||
["ClipSize"] = function(wep, val)
|
||||
return wep.Primary.ClipSize_ExtRifle or 6
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
37
lua/tfa/att/fas2tfa_ks23_plrclr.lua
Normal file
37
lua/tfa/att/fas2tfa_ks23_plrclr.lua
Normal file
@@ -0,0 +1,37 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Colorable Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "Corresponds with your gmod physgun color",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/ks23plrstock.png"
|
||||
ATTACHMENT.ShortName = "RGB"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Skin"] = 1,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:SetSkin(1)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:SetSkin(0)
|
||||
end
|
||||
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
52
lua/tfa/att/fas2tfa_ks23_short.lua
Normal file
52
lua/tfa/att/fas2tfa_ks23_short.lua
Normal file
@@ -0,0 +1,52 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "KS23M Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+10% movement speed",
|
||||
TFA.AttachmentColors["-"], "+35% recoil", "+170% spread",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/ks23short.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SBS"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.85, .85, .85), pos = Vector(13.75, 13.55, 4.27), angle = Angle(180, -90, 90) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(-9, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(-5, 0, 0), angle = Angle(0, 0, 0) }, },
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(.9, .9, .9), pos = Vector(0, 8.25, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
["VElements"] = {
|
||||
["short"] = {
|
||||
["active"] = true
|
||||
},
|
||||
},
|
||||
["IronSightsPos"] = Vector(-2.7285, -7.035, 1.847),
|
||||
["IronSightsAng"] = Vector(1.05, 0.015, 0),
|
||||
["Bodygroups_V"] = {[1] = 1},
|
||||
["Bodygroups_W"] = {[1] = 1},
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["Spread"] = function(wep,stat) return stat * 1.7 end,
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.7 end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.9 end,
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
65
lua/tfa/att/fas2tfa_ks23_supp.lua
Normal file
65
lua/tfa/att/fas2tfa_ks23_supp.lua
Normal file
@@ -0,0 +1,65 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Suppressor"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "Less firing noise", TFA.AttachmentColors["+"], "+10% vertical recoil", "-10% spread", TFA.AttachmentColors["-"], "-30% damage" }
|
||||
ATTACHMENT.Icon = "entities/ins2_att_br_supp.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SUPP"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["standard_barrel"] = {
|
||||
["active"] = false
|
||||
}
|
||||
},
|
||||
["WElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["standard_barrel"] = {
|
||||
["active"] = false
|
||||
}
|
||||
},
|
||||
["IronSightsPos"] = Vector(-2.7285, -7.035, 1.8975),
|
||||
["IronSightsAng"] = Vector(-.2, 0.015, 0),
|
||||
["Primary"] = {
|
||||
["Damage"] = function(wep,stat) return stat * 0.7 end,
|
||||
["KickUp"] = function(wep,stat) return stat * 0.9 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Spread"] = function(wep,stat) return stat * 0.9 end,
|
||||
["IronAccuracy"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Sound"] = function(wep,stat) return wep.Primary.SilencedSound or stat end,
|
||||
},
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_silenced",
|
||||
["MuzzleAttachmentMod"] = function(wep,stat) return wep.MuzzleAttachmentSilenced or stat end,
|
||||
["Silenced"] = true,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.Silenced = true
|
||||
wep:SetSilenced(wep.Silenced)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.Silenced = false
|
||||
wep:SetSilenced(wep.Silenced)
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
35
lua/tfa/att/fas2tfa_mp5_adjstock.lua
Normal file
35
lua/tfa/att/fas2tfa_mp5_adjstock.lua
Normal file
@@ -0,0 +1,35 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Retractable Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+5% aiming speed", "-15% spread"
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2adjstk.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "RETR"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[5] = 1},
|
||||
["Bodygroups_W"] = {[2] = 1},
|
||||
["Primary"] = {
|
||||
["Spread"] = function(wep,stat) return stat * .85 end,
|
||||
},
|
||||
["BlowbackVector"] = Vector(0,-1.5,-.075),
|
||||
["IronSightTime"] = function( wep, stat ) return stat * 1.05 end,
|
||||
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
140
lua/tfa/att/fas2tfa_mp5_pdw.lua
Normal file
140
lua/tfa/att/fas2tfa_mp5_pdw.lua
Normal file
@@ -0,0 +1,140 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "MP5K Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "Increases RPM to 975", "+5% movement speed",
|
||||
TFA.AttachmentColors["-"], "+20% recoil",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2mp5k.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "PDW"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.75, 1, .75), pos = Vector(10.25, .82, 0), angle = Angle(180, -90, 0) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(-3.75, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(-2, 0, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(-4, 0, -.29), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["Bodygroups_V"] = {[1] = 1, [3] = 1, [4] = 2},
|
||||
["Bodygroups_W"] = {[1] = 1},
|
||||
|
||||
["Animations"] = {
|
||||
["draw"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_deploy"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["holster"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_holster"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["idle"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_idle"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["idle_empty"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_idle"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["shoot1"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_shoot"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["reload"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_reload"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["reload_empty"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "mp5k_"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "mp5k_reload_empty"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
},
|
||||
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.20 end,
|
||||
["Sound"] = function(wep,stat) return "FAS2TFA_MP5.2" or stat end,
|
||||
["SilencedSound"] = function(wep,stat) return "FAS2TFA_MP5.4" or stat end,
|
||||
["RPM"] = function( wep, stat ) return stat + 125 end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 1.05 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 1.05 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.95 end,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach( wep )
|
||||
if TFA.Enum.ReadyStatus[wep:GetStatus()] then
|
||||
wep:ChooseIdleAnim()
|
||||
if game.SinglePlayer() then
|
||||
wep:CallOnClient("ChooseIdleAnim","")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
37
lua/tfa/att/fas2tfa_mp5_pdwstock.lua
Normal file
37
lua/tfa/att/fas2tfa_mp5_pdwstock.lua
Normal file
@@ -0,0 +1,37 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "PDW Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+10% aiming speed", "-5% spread",
|
||||
TFA.AttachmentColors["-"], "+10% horizontal recoil",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2pdwstk.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "PDW"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[5] = 2},
|
||||
["Bodygroups_W"] = {[2] = 2},
|
||||
["Primary"] = {
|
||||
["KickHorizontal"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["Spread"] = function( wep, stat ) return stat * .95 end,
|
||||
},
|
||||
["BlowbackVector"] = Vector(0,-1.5,-.075),
|
||||
["IronSightTime"] = function( wep, stat ) return stat * 1.10 end,
|
||||
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
50
lua/tfa/att/fas2tfa_mp5_sd.lua
Normal file
50
lua/tfa/att/fas2tfa_mp5_sd.lua
Normal file
@@ -0,0 +1,50 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "MP5SD Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["-"], "Decreases RPM to 800",
|
||||
TFA.AttachmentColors["+"], "-15% recoil",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2mp5sd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SD"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.75, 1, .75), pos = Vector(10.25, .82, 0), angle = Angle(180, -90, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(-1.5, 0, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(.75, .75, .75), pos = Vector(-3, 0, -.29), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["Bodygroups_V"] = {[1] = 2, [3] = 1, [4] = 3},
|
||||
["Bodygroups_W"] = {[1] = 2},
|
||||
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * .85 end,
|
||||
["SilencedSound"] = function(wep,stat) return "FAS2TFA_MP5.3" or stat end,
|
||||
["RPM"] = function( wep, stat ) return stat - 50 end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
64
lua/tfa/att/fas2tfa_mp5_supp.lua
Normal file
64
lua/tfa/att/fas2tfa_mp5_supp.lua
Normal file
@@ -0,0 +1,64 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Suppressor"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["+"], "Less firing noise", TFA.AttachmentColors["+"], "-5% overall recoil", "-10% spread", TFA.AttachmentColors["-"], "-7% damage" }
|
||||
ATTACHMENT.Icon = "entities/ins2_att_br_supp.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SUPP"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["VElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["standard_barrel"] = {
|
||||
["active"] = false
|
||||
}
|
||||
},
|
||||
["WElements"] = {
|
||||
["suppressor"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["standard_barrel"] = {
|
||||
["active"] = false
|
||||
}
|
||||
},
|
||||
["Primary"] = {
|
||||
["Damage"] = function(wep,stat) return stat * 0.93 end,
|
||||
["KickUp"] = function(wep,stat) return stat * 0.95 end,
|
||||
["KickDown"] = function(wep,stat) return stat * 0.95 end,
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.95 end,
|
||||
["Spread"] = function(wep,stat) return stat * 0.9 end,
|
||||
["IronAccuracy"] = function(wep,stat) return stat * 0.9 end,
|
||||
["Sound"] = function(wep,stat) return wep.Primary.SilencedSound or stat end,
|
||||
},
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_silenced",
|
||||
["MuzzleAttachmentMod"] = function(wep,stat) return wep.MuzzleAttachmentSilenced or stat end,
|
||||
["Silenced"] = true,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.Silenced = true
|
||||
wep:SetSilenced(wep.Silenced)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.Silenced = false
|
||||
wep:SetSilenced(wep.Silenced)
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
57
lua/tfa/att/fas2tfa_sg550_cqb.lua
Normal file
57
lua/tfa/att/fas2tfa_sg550_cqb.lua
Normal file
@@ -0,0 +1,57 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "553 Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+5% movement speed",
|
||||
TFA.AttachmentColors["-"], "+15% overall recoil",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/sgshort.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "CQB"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.86, 1, .86), pos = Vector(1.672, -7.25, 2.825), angle = Angle(180, 0, 180) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(-11, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(-9, 0, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(.9, .9, .9), pos = Vector(-13, .05, -.1), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["VElements"] = { ["cqb"] = { ["active"] = true},
|
||||
|
||||
},
|
||||
["IronSightsPos"] = Vector(-2.3012, -2.5, .956),
|
||||
["IronSightsAng"] = Vector(-.15, 0.008, 0),
|
||||
["Bodygroups_V"] = {[3] = 1, [4] = 2, [8] = 1, [7] = 1},
|
||||
["Bodygroups_W"] = {[1] = 1, [3] = 2, [4] = 1},
|
||||
|
||||
["Primary"] = {
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["KickHorizontal"] = function( wep, stat ) return stat * 1.15 end,
|
||||
["StaticRecoilFactor"] = function( wep, stat ) return stat * 1.05 end,
|
||||
["Sound"] = function(wep,stat) return "FAS2TFA_SG550.3" or stat end,
|
||||
["SilencedSound"] = function(wep,stat) return "FAS2TFA_SG550.4" or stat end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 1.4 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.6 end,
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
55
lua/tfa/att/fas2tfa_sg550_hbar.lua
Normal file
55
lua/tfa/att/fas2tfa_sg550_hbar.lua
Normal file
@@ -0,0 +1,55 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "550-1 Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "-15% vertical recoil", "+35% aiming accuracy",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/ins2_att_br_heavy.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "HBAR"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.88, 1, .88), pos = Vector(1.672, -24.5, 2.825), angle = Angle(180, 0, 180) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(5, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(10, 0, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(.9, .9, .9), pos = Vector(5, .05, -.1), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
|
||||
["Bodygroups_V"] = {[4] = 1},
|
||||
["Bodygroups_W"] = {[3] = 1},
|
||||
["Primary"] = {
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.35 end,
|
||||
["IronRecoilMultiplier"] = function( wep, stat ) return stat * 1.35 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["KickDown"] = function( wep, stat ) return stat * 0.9 end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 0.95 end,
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_generic",
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.Type = "Select-fire sniper rifle, 5.56×45mm"
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.Type = "Assault rifle, 5.56×45mm"
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
35
lua/tfa/att/fas2tfa_sg550_prstock.lua
Normal file
35
lua/tfa/att/fas2tfa_sg550_prstock.lua
Normal file
@@ -0,0 +1,35 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Precision Stock"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "-10% horizontal recoil",
|
||||
TFA.AttachmentColors["-"], "+25% aiming speed",
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/sgstk2.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "+STK"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[1] = 1},
|
||||
["Bodygroups_W"] = {[2] = 1},
|
||||
["Primary"] = {
|
||||
["KickHorizontal"] = function(wep,stat) return stat * 0.88 end,
|
||||
},
|
||||
["IronSightTime"] = function( wep, stat ) return stat * 1.25 end,
|
||||
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
45
lua/tfa/att/fas2tfa_sg55x_scope.lua
Normal file
45
lua/tfa/att/fas2tfa_sg55x_scope.lua
Normal file
@@ -0,0 +1,45 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "SG550/1 Scope"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "10x zoom", TFA.AttachmentColors["-"], "40% higher zoom time", TFA.AttachmentColors["-"], "10% slower aimed walking" }
|
||||
ATTACHMENT.Icon = "entities/ins2_si_mx4.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SG"
|
||||
ATTACHMENT.Base = "ins2_scope_base"
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[5] = 1, [7] = 1},
|
||||
["BlowbackVector"] = Vector(0,-1,0),
|
||||
["VElements"] = {
|
||||
["rail_sights"] = {
|
||||
["active"] = false,},
|
||||
["pso1_lens"] = {
|
||||
["active"] = true,
|
||||
},
|
||||
},
|
||||
["WElements"] = {
|
||||
["scope_mx4"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Secondary"] = {
|
||||
|
||||
["ScopeZoom"] = function(wep, val) return 10 end
|
||||
},
|
||||
["INS2_SightSuffix"] = "SG"
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
64
lua/tfa/att/fas2tfa_sks_20rnd.lua
Normal file
64
lua/tfa/att/fas2tfa_sks_20rnd.lua
Normal file
@@ -0,0 +1,64 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Detachable 20rnd"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfafas2sks20rnd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "20DM"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[2] = 2},
|
||||
["Bodygroups_W"] = {[1] = 1},
|
||||
["Animations"] = {
|
||||
["reload"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["reload_empty"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_empty_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
},
|
||||
["Primary"] = {
|
||||
["ClipSize"] = function(wep, val)
|
||||
return wep.Primary.ClipSize_ExtRifle or 20
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
|
||||
|
||||
62
lua/tfa/att/fas2tfa_sks_30rnd.lua
Normal file
62
lua/tfa/att/fas2tfa_sks_30rnd.lua
Normal file
@@ -0,0 +1,62 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Detachable 30rnd"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfafas2sks30rnd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "30DM"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[2] = 3},
|
||||
["Bodygroups_W"] = {[1] = 2},
|
||||
["Animations"] = {
|
||||
["reload"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["reload_empty"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_empty_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
},
|
||||
["Primary"] = {
|
||||
["ClipSize"] = function(wep, val)
|
||||
return wep.Primary.ClipSize_ExtRifle or 30
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
63
lua/tfa/att/fas2tfa_sks_40rnd.lua
Normal file
63
lua/tfa/att/fas2tfa_sks_40rnd.lua
Normal file
@@ -0,0 +1,63 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Detachable 40rnd"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfafas2sks40rnd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "40RPK"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["CanJam"] = true,
|
||||
["Bodygroups_V"] = {[2] = 4},
|
||||
["Bodygroups_W"] = {[1] = 3},
|
||||
["Animations"] = {
|
||||
["reload"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
["reload_empty"] = function(wep, _val)
|
||||
local val = table.Copy(_val)
|
||||
if val.type == TFA.Enum.ANIMATION_SEQ then
|
||||
val.value = val.value .. "_stanag"
|
||||
else
|
||||
val.type = TFA.Enum.ANIMATION_SEQ --Sequence or act
|
||||
val.value = "Reload_30_empty_nmc"
|
||||
end
|
||||
return (wep:CheckVMSequence(val.value) and val or _val), true, true
|
||||
end,
|
||||
},
|
||||
["Primary"] = {
|
||||
["ClipSize"] = function(wep, val)
|
||||
return wep.Primary.ClipSize_ExtRifle or 40
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep:Unload()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
35
lua/tfa/att/fas2tfa_sks_bf.lua
Normal file
35
lua/tfa/att/fas2tfa_sks_bf.lua
Normal file
@@ -0,0 +1,35 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Full-auto conversion"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = nil --"entities/ins2_att_mag_ext_rifle_30rd.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "AUTO"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.Primary.Automatic = true
|
||||
wep.Type = "Automatic rifle, 7.62×39mm"
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.Primary.Automatic = false
|
||||
wep.Type = "Semi-automatic rifle, 7.62×39mm"
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
50
lua/tfa/att/fas2tfa_svd_sbr.lua
Normal file
50
lua/tfa/att/fas2tfa_svd_sbr.lua
Normal file
@@ -0,0 +1,50 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "SBR Barrel"
|
||||
ATTACHMENT.Description = {
|
||||
TFA.AttachmentColors["+"], "+10% movement speed",
|
||||
TFA.AttachmentColors["-"], "+20% recoil", "-30% accuracy", "-5% damage"
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfafas2svdsbr.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "SBR"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelBoneMods"] = {
|
||||
["A_Suppressor"] = { scale = Vector(.8, .8, .8), pos = Vector(9, .5, 0), angle = Angle(0, -90, 0) },
|
||||
["A_Muzzle"] = { scale = Vector(1, 1, 1), pos = Vector(-13.8, 0, 0), angle = Angle(0, 0, 0) },
|
||||
["A_MuzzleSupp"] = { scale = Vector(1, 1, 1), pos = Vector(-10.5, 0, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
["WorldModelBoneMods"] = {
|
||||
["ATTACH_Muzzle"] = { scale = Vector(.9, .9, .9), pos = Vector(-14, .2, 0), angle = Angle(0, 0, 0) },
|
||||
},
|
||||
["Bodygroups_V"] = {[2] = 1},
|
||||
["Bodygroups_W"] = {[1] = 1},
|
||||
["Primary"] = {
|
||||
["IronAccuracy"] = function( wep, stat ) return stat * 1.3 end,
|
||||
["Damage"] = function( wep, stat ) return stat * .95 end,
|
||||
["Spread"] = function( wep, stat ) return stat * 1.3 end,
|
||||
["KickUp"] = function( wep, stat ) return stat * 1.2 end,
|
||||
["Sound"] = function(wep,stat) return "FAS2TFA_SVD.3" or stat end,
|
||||
["SilencedSound"] = function(wep,stat) return "FAS2TFA_SVD.4" or stat end,
|
||||
},
|
||||
["MoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsMoveSpeed"] = function( wep, stat ) return stat * 1.1 end,
|
||||
["IronSightsSensitivity"] = function( wep, stat ) return stat * 0.9 end,
|
||||
["MuzzleFlashEffect"] = "tfa_muzzleflash_generic",
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
45
lua/tfa/att/fas2tfa_svd_scope.lua
Normal file
45
lua/tfa/att/fas2tfa_svd_scope.lua
Normal file
@@ -0,0 +1,45 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "PSO-1 Scope"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "4x zoom", TFA.AttachmentColors["-"], "30% higher zoom time", TFA.AttachmentColors["-"], "15% slower aimed walking" }
|
||||
ATTACHMENT.Icon = "entities/ins2_si_mx4.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "PSO-1"
|
||||
ATTACHMENT.Base = "ins2_scope_base"
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Bodygroups_V"] = {[1] = 1},
|
||||
["BlowbackVector"] = Vector(0,-1,0),
|
||||
["VElements"] = {
|
||||
["rail_sights"] = {
|
||||
["active"] = false,},
|
||||
["pso1_lens"] = {
|
||||
["active"] = true,
|
||||
},
|
||||
},
|
||||
["WElements"] = {
|
||||
["scope_mx4"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["Secondary"] = {
|
||||
|
||||
["ScopeZoom"] = function(wep, val) return 4 end
|
||||
},
|
||||
["INS2_SightSuffix"] = "PSO"
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
68
lua/tfa/att/hl2r_ar2_legacy_is.lua
Normal file
68
lua/tfa/att/hl2r_ar2_legacy_is.lua
Normal file
@@ -0,0 +1,68 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Ironsight-less"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["-"], "Removes the ironsight on the AR2.", TFA.AttachmentColors["+"], "Appreciate all the intricate mechanisms of the AR2." }
|
||||
ATTACHMENT.Icon = "entities/hl2r_ar2_legacy_is.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
function ATTACHMENT:Attach(wep)
|
||||
local mag = wep:Clip1()
|
||||
wep.DrawCrosshairIS = true
|
||||
wep.ViewModelKitOld = wep.ViewModelKitOld or wep.ViewModel
|
||||
wep.ViewModel = wep:GetStat("ViewModel_LEG") or wep.ViewModel
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
if mag == 0 then
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE_EMPTY)
|
||||
elseif mag == 1 then
|
||||
wep:SendViewModelSeq("idle_midempty")
|
||||
else
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
local mag = wep:Clip1()
|
||||
wep.DrawCrosshairIS = false
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
if mag == 0 then
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE_EMPTY)
|
||||
elseif mag == 1 then
|
||||
wep:SendViewModelSeq("idle_midempty")
|
||||
else
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
43
lua/tfa/att/hl2r_crossbow_legacy_is.lua
Normal file
43
lua/tfa/att/hl2r_crossbow_legacy_is.lua
Normal file
@@ -0,0 +1,43 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "No-scope"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["-"], "Don't aim with the scope." }
|
||||
ATTACHMENT.Icon = "entities/hl2r_ar2_legacy_is.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
--["RTMaterialOverride"] = 0;
|
||||
}
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.DrawCrosshairIS = true
|
||||
wep:ClearStatCache()
|
||||
--wep.RTMaterialOverride = 0;
|
||||
wep:ClearStatCache()
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.DrawCrosshairIS = false
|
||||
wep:ClearStatCache()
|
||||
--wep.RTMaterialOverride = 2;
|
||||
wep:ClearStatCache()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
36
lua/tfa/att/hl2r_pistol_legacy_is.lua
Normal file
36
lua/tfa/att/hl2r_pistol_legacy_is.lua
Normal file
@@ -0,0 +1,36 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Ironsight-less"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Changes the aim to look like MMOD", TFA.AttachmentColors["-"], "Doesn't use the sights." }
|
||||
ATTACHMENT.Icon = "entities/hl2r_ar2_legacy_is.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.DrawCrosshairIS = true
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.DrawCrosshairIS = false
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
36
lua/tfa/att/hl2r_shotgun_legacy_is.lua
Normal file
36
lua/tfa/att/hl2r_shotgun_legacy_is.lua
Normal file
@@ -0,0 +1,36 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Ironsight-less"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Changes the aim to look like MMOD", TFA.AttachmentColors["-"], "Doesn't use the sights." }
|
||||
ATTACHMENT.Icon = "entities/hl2r_ar2_legacy_is.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.DrawCrosshairIS = true
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.DrawCrosshairIS = false
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
58
lua/tfa/att/hl2r_smg1_legacy_is.lua
Normal file
58
lua/tfa/att/hl2r_smg1_legacy_is.lua
Normal file
@@ -0,0 +1,58 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "HOLO Off"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["-"], "Shuts down the Holo sight", TFA.AttachmentColors["+"], "Train your aim!"}
|
||||
ATTACHMENT.Icon = "entities/hl2r_ar2_legacy_is.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
|
||||
ATTACHMENT.MaterialTable = {
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
local mag = wep:Clip1()
|
||||
wep.ViewModelKitOld = wep.ViewModelKitOld or wep.ViewModel
|
||||
wep.ViewModel = wep:GetStat("ViewModel_LEG") or wep.ViewModel
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
local mag = wep:Clip1()
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
61
lua/tfa/att/hl2r_smg1_mmod_ret.lua
Normal file
61
lua/tfa/att/hl2r_smg1_mmod_ret.lua
Normal file
@@ -0,0 +1,61 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "MMod Reticle"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Uses the MMod SMG Reticle.", TFA.AttachmentColors["+"], "This one can be colored." }
|
||||
ATTACHMENT.Icon = "entities/hl2r_si_smg_ret.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "RET"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_MM or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_MM or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.ViewModelKitOld = wep.ViewModelKitOld or wep.ViewModel
|
||||
wep.WorldModelKitOld = wep.WorldModelKitOld or wep.WorldModel
|
||||
wep.ViewModel = wep:GetStat("ViewModel_RET") or wep.ViewModel
|
||||
wep.WorldModel = wep:GetStat("WorldModel_RET") or wep.WorldModel
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep:SetModel(wep.WorldModel)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
if wep.WorldModelKitOld then
|
||||
wep.WorldModel = wep.WorldModelKitOld
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
63
lua/tfa/att/ins2_pm_alt.lua
Normal file
63
lua/tfa/att/ins2_pm_alt.lua
Normal file
@@ -0,0 +1,63 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Alternative Look"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfa_ins2_pm_alt.png"
|
||||
ATTACHMENT.ShortName = "ALT"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["MaterialTable_V"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
},
|
||||
["VElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["MaterialTable_W"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
},
|
||||
["WElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/alt/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["WepSelectIcon_Override"] = "vgui/hud/tfa_ins2_pm_alt"
|
||||
}
|
||||
|
||||
local function resetMatCache(att, wep)
|
||||
wep:ClearMaterialCache()
|
||||
end
|
||||
|
||||
ATTACHMENT.Attach = resetMatCache
|
||||
ATTACHMENT.Detach = resetMatCache
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
66
lua/tfa/att/ins2_pm_honorary.lua
Normal file
66
lua/tfa/att/ins2_pm_honorary.lua
Normal file
@@ -0,0 +1,66 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Honorary"
|
||||
ATTACHMENT.Description = {
|
||||
"«For succesful execution of highly dangerous state orders,",
|
||||
"as well as valor and courage shown in the line of duty.»"
|
||||
}
|
||||
ATTACHMENT.Icon = "entities/tfa_ins2_pm_honorary.png"
|
||||
ATTACHMENT.ShortName = "HONOR"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["MaterialTable_V"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
},
|
||||
["VElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["MaterialTable_W"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
},
|
||||
["WElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/honorary/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["WepSelectIcon_Override"] = "vgui/hud/tfa_ins2_pm_honorary"
|
||||
}
|
||||
|
||||
local function resetMatCache(att, wep)
|
||||
wep:ClearMaterialCache()
|
||||
end
|
||||
|
||||
ATTACHMENT.Attach = resetMatCache
|
||||
ATTACHMENT.Detach = resetMatCache
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
63
lua/tfa/att/ins2_pm_soviet.lua
Normal file
63
lua/tfa/att/ins2_pm_soviet.lua
Normal file
@@ -0,0 +1,63 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Classic Soviet Vintage"
|
||||
ATTACHMENT.Description = {}
|
||||
ATTACHMENT.Icon = "entities/tfa_ins2_pm_soviet.png"
|
||||
ATTACHMENT.ShortName = "OLD"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["MaterialTable_V"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
},
|
||||
["VElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["MaterialTable_W"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
},
|
||||
["WElements"] = {
|
||||
["mag"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
}
|
||||
},
|
||||
["mag_ext"] = {
|
||||
["materials"] = {
|
||||
[1] = "models/weapons/tfa_ins2/pm/soviet/pm",
|
||||
}
|
||||
}
|
||||
},
|
||||
["WepSelectIcon_Override"] = "vgui/hud/tfa_ins2_pm_soviet"
|
||||
}
|
||||
|
||||
local function resetMatCache(att, wep)
|
||||
wep:ClearMaterialCache()
|
||||
end
|
||||
|
||||
ATTACHMENT.Attach = resetMatCache
|
||||
ATTACHMENT.Detach = resetMatCache
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
79
lua/tfa/att/mmod_ar2_greg.lua
Normal file
79
lua/tfa/att/mmod_ar2_greg.lua
Normal file
@@ -0,0 +1,79 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "HD AR2"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Overhauled textures."}
|
||||
ATTACHMENT.Icon = "entities/mmod_ar2_greg.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "HD"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
}
|
||||
|
||||
ATTACHMENT.MaterialTable = {
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
local mag = wep:Clip1()
|
||||
wep.ViewModelKitOld = wep.ViewModelKitOld or wep.ViewModel
|
||||
wep.WorldModelKitOld = wep.WorldModelKitOld or wep.WorldModel
|
||||
wep.ViewModel = wep:GetStat("ViewModel_HD") or wep.ViewModel
|
||||
wep.WorldModel = wep:GetStat("WorldModel_HD") or wep.WorldModel
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
if mag == 0 then
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE_EMPTY)
|
||||
elseif mag == 1 then
|
||||
wep:SendViewModelSeq("idle_midempty")
|
||||
else
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end
|
||||
end)
|
||||
end
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.MaterialTable = wep.MaterialTable or {}
|
||||
wep.MaterialTable[2] = self.MaterialTable[2]
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
local mag = wep:Clip1()
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
if mag == 0 then
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE_EMPTY)
|
||||
elseif mag == 1 then
|
||||
wep:SendViewModelSeq("idle_midempty")
|
||||
else
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
if wep.WorldModelKitOld then
|
||||
wep.WorldModel = wep.WorldModelKitOld
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
wep.MaterialTable = wep.MaterialTable or {}
|
||||
wep.MaterialTable[2] = nil
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
36
lua/tfa/att/mmod_si_legacy.lua
Normal file
36
lua/tfa/att/mmod_si_legacy.lua
Normal file
@@ -0,0 +1,36 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Legacy Irons"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Ironsights inspired by MMod." }
|
||||
ATTACHMENT.Icon = "entities/mmod_si_legacy.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "LEGACY"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["IronSightsPos"] = function( wep, val ) return wep.IronSightsPos_LEG or val end,
|
||||
["IronSightsAng"] = function( wep, val ) return wep.IronSightsAng_LEG or val end,
|
||||
["IronSightTime"] = function( wep, val ) return val * 1 end,
|
||||
}
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.DrawCrosshairIS = true
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
wep.DrawCrosshairIS = false
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
58
lua/tfa/att/mmod_si_smg_ret.lua
Normal file
58
lua/tfa/att/mmod_si_smg_ret.lua
Normal file
@@ -0,0 +1,58 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Legacy Reticle"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.AttachmentColors["="], "Uses old SMG reticle.", TFA.AttachmentColors["-"], "Cannot be colored." }
|
||||
ATTACHMENT.Icon = "entities/mmod_si_smg_ret.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "RET"
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
}
|
||||
|
||||
function ATTACHMENT:Attach(wep)
|
||||
wep.ViewModelKitOld = wep.ViewModelKitOld or wep.ViewModel
|
||||
wep.WorldModelKitOld = wep.WorldModelKitOld or wep.WorldModel
|
||||
wep.ViewModel = wep:GetStat("ViewModel_RET") or wep.ViewModel
|
||||
wep.WorldModel = wep:GetStat("WorldModel_RET") or wep.WorldModel
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep:SetModel(wep.WorldModel)
|
||||
end
|
||||
|
||||
function ATTACHMENT:Detach(wep)
|
||||
if wep.ViewModelKitOld then
|
||||
wep.ViewModel = wep.ViewModelKitOld
|
||||
if IsValid(wep.OwnerViewModel) then
|
||||
wep.OwnerViewModel:SetModel(wep.ViewModel)
|
||||
timer.Simple(0, function()
|
||||
wep:SendViewModelAnim(ACT_VM_IDLE)
|
||||
end)
|
||||
end
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
if wep.WorldModelKitOld then
|
||||
wep.WorldModel = wep.WorldModelKitOld
|
||||
wep:SetModel(wep.WorldModel)
|
||||
wep.ViewModelKitOld = nil
|
||||
end
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
53
lua/tfa/att/sg_frag.lua
Normal file
53
lua/tfa/att/sg_frag.lua
Normal file
@@ -0,0 +1,53 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Frag Ammunition"
|
||||
ATTACHMENT.ShortName = "Frag" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Explosive Damage", "2x damage", TFA.Attachments.Colors["-"], "0.5x pellets" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_fragshell.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["DamageType"] = function(wep,stat) return bit.bor( stat or 0, DMG_BLAST ) end,
|
||||
["Damage"] = function(wep,stat) return stat * 2 end,
|
||||
["NumShots"] = function(wep,stat) return stat / 2 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
55
lua/tfa/att/sg_slug.lua
Normal file
55
lua/tfa/att/sg_slug.lua
Normal file
@@ -0,0 +1,55 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Slug Ammunition"
|
||||
ATTACHMENT.ShortName = "Slug" --Abbreviation, 5 chars or less please
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["+"], "Much lower spread", TFA.Attachments.Colors["+"], "100m higher range", TFA.Attachments.Colors["-"], "30% less damage", "One pellet" }
|
||||
ATTACHMENT.Icon = "entities/tfa_ammo_slug.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["Primary"] = {
|
||||
["Damage"] = function( wep, stat ) return wep.Primary_TFA.NumShots * stat * 0.7 end,
|
||||
["NumShots"] = function( wep, stat ) return 1, true end,
|
||||
["Spread"] = function( wep, stat ) return math.max( stat - 0.015, stat * 0.5 ) end,
|
||||
["IronAccuracy"] = function( wep, stat ) return math.max( stat - 0.03, stat * 0.25 ) end,
|
||||
["Range"] = function( wep, stat ) return stat + 100 * 39.370 end
|
||||
}
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
79
lua/tfa/att/si_acog.lua
Normal file
79
lua/tfa/att/si_acog.lua
Normal file
@@ -0,0 +1,79 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Base = "si_rt_base"
|
||||
ATTACHMENT.Name = "ACOG"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["="], "4x zoom", TFA.Attachments.Colors["-"], "20% higher zoom time", TFA.Attachments.Colors["-"], "10% slower aimed walking" }
|
||||
ATTACHMENT.Icon = "entities/tfa_si_acog.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "ACOG"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
local fov = 90 / 4 / 2 -- Default FOV / Scope Zoom / screenscale
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelElements"] = {
|
||||
["acog"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["rtcircle_acog"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WorldModelElements"] = {
|
||||
["acog"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["IronSightsPosition"] = function( wep, val ) return wep.IronSightsPos_ACOG or val, true end,
|
||||
["IronSightsAngle"] = function( wep, val ) return wep.IronSightsAng_ACOG or val, true end,
|
||||
["IronSightsSensitivity"] = function(wep,val) return TFA.CalculateSensitivtyScale( fov, wep:GetStatL("Secondary.OwnerFOV"), wep.ACOGScreenScale ) end ,
|
||||
["Secondary"] = {
|
||||
["OwnerFOV"] = function( wep, val ) return val * 0.7 end
|
||||
},
|
||||
["IronSightTime"] = function( wep, val ) return val * 1.20 end,
|
||||
["IronSightMoveSpeed"] = function(stat) return stat * 0.9 end,
|
||||
["RTOpaque"] = true,
|
||||
["RTMaterialOverride"] = -1,
|
||||
|
||||
["RTScopeFOV"] = 90 / 4 / 2, -- Default FOV / Scope Zoom / screenscale
|
||||
|
||||
["RTReticleMaterial"] = Material("scope/gdcw_acog"),
|
||||
["RTReticleScale"] = 1,
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
70
lua/tfa/att/si_aimpoint.lua
Normal file
70
lua/tfa/att/si_aimpoint.lua
Normal file
@@ -0,0 +1,70 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "Aimpoint"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["="], "10% higher zoom", TFA.Attachments.Colors["-"], "10% higher zoom time" }
|
||||
ATTACHMENT.Icon = "entities/tfa_si_aimpoint.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "AIM"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelElements"] = {
|
||||
["aimpoint"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["aimpoint_spr"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WorldModelElements"] = {
|
||||
["aimpoint"] = {
|
||||
["active"] = true
|
||||
},
|
||||
["aimpoint_spr"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["IronSightsPosition"] = function( wep, val ) return wep.IronSightsPos_AimPoint or val, true end,
|
||||
["IronSightsAngle"] = function( wep, val ) return wep.IronSightsAng_AimPoint or val, true end,
|
||||
["Secondary"] = {
|
||||
["OwnerFOV"] = function( wep, val ) return val * 0.9 end
|
||||
},
|
||||
["IronSightTime"] = function( wep, val ) return val * 1.10 end
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
64
lua/tfa/att/si_eotech.lua
Normal file
64
lua/tfa/att/si_eotech.lua
Normal file
@@ -0,0 +1,64 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "EOTech"
|
||||
--ATTACHMENT.ID = "base" -- normally this is just your filename
|
||||
ATTACHMENT.Description = { TFA.Attachments.Colors["="], "10% higher zoom", TFA.Attachments.Colors["-"], "10% higher zoom time" }
|
||||
ATTACHMENT.Icon = "entities/tfa_si_eotech.png" --Revers to label, please give it an icon though! This should be the path to a png, like "entities/tfa_ammo_match.png"
|
||||
ATTACHMENT.ShortName = "EOTEK"
|
||||
ATTACHMENT.TFADataVersion = TFA.LatestDataVersion
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["ViewModelElements"] = {
|
||||
["eotech"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["WorldModelElements"] = {
|
||||
["eotech"] = {
|
||||
["active"] = true
|
||||
}
|
||||
},
|
||||
["IronSightsPosition"] = function( wep, val ) return wep.IronSightsPos_EOTech or val, true end,
|
||||
["IronSightsAngle"] = function( wep, val ) return wep.IronSightsAng_EOTech or val, true end,
|
||||
["Secondary"] = {
|
||||
["OwnerFOV"] = function( wep, val ) return val * 0.9 end
|
||||
},
|
||||
["IronSightTime"] = function( wep, val ) return val * 1.10 end
|
||||
}
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
140
lua/tfa/att/si_rt_base.lua
Normal file
140
lua/tfa/att/si_rt_base.lua
Normal file
@@ -0,0 +1,140 @@
|
||||
--[[
|
||||
| This file was obtained through the combined efforts
|
||||
| of Madbluntz & Plymouth Antiquarian Society.
|
||||
|
|
||||
| Credits: lifestorm, Gregory Wayne Rossel JR.,
|
||||
| Maloy, DrPepper10 @ RIP, Atle!
|
||||
|
|
||||
| Visit for more: https://plymouth.thetwilightzone.ru/
|
||||
--]]
|
||||
|
||||
|
||||
-- Copyright (c) 2018-2020 TFA Base Devs
|
||||
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
-- of this software and associated documentation files (the "Software"), to deal
|
||||
-- in the Software without restriction, including without limitation the rights
|
||||
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
-- copies of the Software, and to permit persons to whom the Software is
|
||||
-- furnished to do so, subject to the following conditions:
|
||||
|
||||
-- The above copyright notice and this permission notice shall be included in all
|
||||
-- copies or substantial portions of the Software.
|
||||
|
||||
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
-- SOFTWARE.
|
||||
|
||||
if not ATTACHMENT then
|
||||
ATTACHMENT = {}
|
||||
end
|
||||
|
||||
ATTACHMENT.Name = "RT Scope Base"
|
||||
ATTACHMENT.Description = {}
|
||||
|
||||
ATTACHMENT.WeaponTable = {
|
||||
["RTDrawEnabled"] = true,
|
||||
|
||||
-- ["RTScopeFOV"] = 90 / 1 / 2, -- Default FOV / Scope Zoom / screenscale
|
||||
-- ["RTScopeAttachment"] = -1,
|
||||
|
||||
-- ["RTReticleMaterial"] = Material("scope/gdcw_acog"),
|
||||
-- ["RTReticleColor"] = color_white,
|
||||
-- ["RTReticleScale"] = 1,
|
||||
|
||||
-- ["RTShadowMaterial"] = Material("vgui/scope_shadowmask_test"),
|
||||
-- ["RTShadowColor"] = color_white,
|
||||
-- ["RTShadowScale"] = 2,
|
||||
}
|
||||
|
||||
local cd = {}
|
||||
|
||||
local fallbackReticle = Material("scope/gdcw_scopesightonly")
|
||||
local fallbackShadow = Material("vgui/scope_shadowmask_test")
|
||||
|
||||
local flipcv = GetConVar("cl_tfa_viewmodel_flip")
|
||||
|
||||
function ATTACHMENT:RTCode(wep, rt, scrw, scrh)
|
||||
if not wep.OwnerIsValid or not wep:VMIV() then return end
|
||||
|
||||
local rtw, rth = rt:Width(), rt:Height()
|
||||
|
||||
-- clearing view
|
||||
render.OverrideAlphaWriteEnable(true, true)
|
||||
surface.SetDrawColor(color_white)
|
||||
surface.DrawRect(-rtw, -rth, rtw * 2, rth * 2)
|
||||
|
||||
local vm = wep.OwnerViewModel
|
||||
|
||||
local ang = vm:GetAngles()
|
||||
|
||||
local isang = wep:GetStatL("IronSightsAngle") * wep:GetIronSightsProgress()
|
||||
|
||||
ang:RotateAroundAxis(ang:Forward(), -isang.z)
|
||||
ang:RotateAroundAxis(ang:Right(), -isang.x)
|
||||
ang:RotateAroundAxis(ang:Up(), -isang.y)
|
||||
|
||||
ang:RotateAroundAxis(ang:Forward(), isang.z)
|
||||
|
||||
local scopeAtt = wep:GetStatL("RTScopeAttachment", -1)
|
||||
|
||||
if scopeAtt > 0 then
|
||||
local AngPos = vm:GetAttachment(scopeAtt)
|
||||
|
||||
if AngPos then
|
||||
ang = AngPos.Ang
|
||||
|
||||
if flipcv:GetBool() then
|
||||
ang.y = -ang.y
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
cd.angles = ang
|
||||
cd.origin = wep:GetOwner():GetShootPos()
|
||||
cd.x = 0
|
||||
cd.y = 0
|
||||
cd.w = rtw
|
||||
cd.h = rth
|
||||
cd.fov = wep:GetStatL("RTScopeFOV", 90 / wep:GetStatL("ScopeZoom", 1) / 2)
|
||||
cd.drawviewmodel = false
|
||||
cd.drawhud = false
|
||||
|
||||
-- main RT render view
|
||||
render.Clear(0, 0, 0, 255, true, true)
|
||||
render.SetScissorRect(0, 0, rtw, rth, true)
|
||||
|
||||
if wep:GetIronSightsProgress() > 0.005 then
|
||||
render.RenderView(cd)
|
||||
end
|
||||
|
||||
render.SetScissorRect(0, 0, rtw, rth, false)
|
||||
render.OverrideAlphaWriteEnable(false, true)
|
||||
|
||||
cam.Start2D()
|
||||
|
||||
-- ADS transition darkening
|
||||
draw.NoTexture()
|
||||
surface.SetDrawColor(ColorAlpha(color_black, 255 * (1 - wep:GetIronSightsProgress())))
|
||||
surface.DrawRect(0, 0, rtw, rth)
|
||||
|
||||
surface.SetMaterial(wep:GetStatL("RTReticleMaterial", fallbackReticle))
|
||||
surface.SetDrawColor(wep:GetStatL("RTReticleColor", color_white))
|
||||
local retScale = wep:GetStatL("RTReticleScale", 1)
|
||||
surface.DrawTexturedRect(rtw / 2 - rtw * retScale / 2, rth / 2 - rth * retScale / 2, rtw * retScale, rth * retScale)
|
||||
|
||||
surface.SetMaterial(wep:GetStatL("RTShadowMaterial", fallbackShadow))
|
||||
surface.SetDrawColor(wep:GetStatL("RTShadowColor", color_white))
|
||||
local shadScale = wep:GetStatL("RTShadowScale", 2)
|
||||
surface.DrawTexturedRect(rtw / 2 - rtw * shadScale / 2, rth / 2 - rth * shadScale / 2, rtw * shadScale, rth * shadScale)
|
||||
|
||||
cam.End2D()
|
||||
end
|
||||
|
||||
if not TFA_ATTACHMENT_ISUPDATING then
|
||||
TFAUpdateAttachments()
|
||||
end
|
||||
Reference in New Issue
Block a user