zombiesurvival-evolved/gamemodes/zombiesurvival/entities/weapons/weapon_zs_pipe.lua
JetBoom 53743b1aee Merge with current nox changes.
Random starting loadouts now include things that aren't weapons (ammo,
traits, etc.).
Added an option to disable the automatic suicide when changing zombie
classes.
Zombies will no longer receive damage resistance when only one human
remains.
Players can no longer claim the arsenal crate that gets spawned in the
human spawn when nobody has one. Any player can pack it up though.
The Ghoul's ghoul touch special ability has been changed. It will no
longer slow targets but will debuff them for the next 10 seconds. They
will take 40% more damage (the extra damage is attributed to the person
who ghoul touched them last) for the next 10 seconds as well as slightly
disorienting them.
The Ghoul movement speed has been reduced from 185 to 170.
Added crafting recipe: 'Waraxe' Handgun. Combine two 'Battleaxe'
Handguns to craft this. Slightly better version of the Owens.
The Flesh Creeper model has been changed to one that doesn't have
severely awkward hitboxes.
The Flesh Creeper can no longer jump and attack at the same time.
The Lead Pipe special trait has been changed from a disorientation to a
severe view punch/snap on a global cooldown of 1.5 seconds.
The Regenerative trait is now 1 health every 6 seconds under 50% health
instead of 1 health every 5 seconds under 50% health.
Fast Zombie Legs have been changed to be a slightly faster but slightly
weaker version of Zombie Legs.
Zombies that have just spawned or enter zombie gas will now have a
temporary buff which gives 25% extra speed and 40% damage resistance.
This buff lasts for 3 seconds and is refreshed by entering the gas. Gas
will no longer heal. Zombies with this buff on will strobe dark green.
Added crafting recipe: Bladehack. Combine a saw blade with a manhack to
get this. Slower but has more health, does more damage, and has less of
a knockback when hitting something.
Resupply Boxes now award the owner a point for every 2 people who use
their box instead of every single person (so half as many points).
Fixed Fast Zombie Legs spawning much more abundantly than intended.
Fixed Flesh Creepers not being able to jump over obstacles due to their
insanely low jump height.
Fixed zombies taking themselves in to account when calculating horde
damage resistance (bosses always had full resistance because of this).
Fixed allowing people to use worth menu after redeeming.
2014-11-07 00:03:40 -05:00

71 lines
2.2 KiB
Lua

AddCSLuaFile()
if CLIENT then
SWEP.PrintName = "Lead Pipe"
SWEP.ViewModelFlip = false
SWEP.ViewModelFOV = 60
SWEP.ShowViewModel = false
SWEP.ShowWorldModel = false
SWEP.VElements = {
["base"] = { type = "Model", model = "models/props_canal/mattpipe.mdl", bone = "ValveBiped.Bip01_R_Hand", rel = "", pos = Vector(2.2, 1, -2.274), angle = Angle(0, 0, 0), size = Vector(1, 1, 1), color = Color(255, 255, 255, 255), surpresslightning = false, material = "", skin = 0, bodygroup = {} }
}
SWEP.WElements = {
["base"] = { type = "Model", model = "models/props_canal/mattpipe.mdl", bone = "ValveBiped.Bip01_R_Hand", rel = "", pos = Vector(2.599, 1, -6), angle = Angle(0, 0, 0), size = Vector(1, 1, 1), color = Color(255, 255, 255, 255), surpresslightning = false, material = "", skin = 0, bodygroup = {} }
}
end
SWEP.Base = "weapon_zs_basemelee"
SWEP.DamageType = DMG_CLUB
SWEP.ViewModel = "models/weapons/c_stunstick.mdl"
SWEP.WorldModel = "models/props_canal/mattpipe.mdl"
SWEP.UseHands = true
SWEP.MeleeDamage = 40
SWEP.MeleeRange = 50
SWEP.MeleeSize = 1.15
SWEP.Primary.Delay = 1.75
SWEP.UseMelee1 = true
SWEP.HitGesture = ACT_HL2MP_GESTURE_RANGE_ATTACK_MELEE
SWEP.MissGesture = SWEP.HitGesture
SWEP.SwingRotation = Angle(30, -30, -30)
SWEP.SwingTime = 0.4
SWEP.SwingHoldType = "grenade"
function SWEP:PlaySwingSound()
self:EmitSound("weapons/iceaxe/iceaxe_swing1.wav", 75, math.random(55, 65))
end
function SWEP:PlayHitSound()
self:EmitSound("physics/metal/metal_canister_impact_hard"..math.random(3)..".wav", 75, math.random(115, 125))
end
if SERVER then
function SWEP:OnMeleeHit(hitent, hitflesh, tr)
if hitent:IsValid() and hitent:IsPlayer() and hitent:GetZombieClassTable().Name ~= "Shade" and CurTime() >= (hitent._NextLeadPipeEffect or 0) then
hitent._NextLeadPipeEffect = CurTime() + 1.5
--hitent:GiveStatus("disorientation")
local x = math.Rand(0.75, 1)
x = x * (math.random(2) == 2 and 1 or -1)
local ang = Angle(1 - x, x, 0) * 38
hitent:ViewPunch(ang)
local eyeangles = hitent:EyeAngles()
eyeangles:RotateAroundAxis(eyeangles:Up(), ang.yaw)
eyeangles:RotateAroundAxis(eyeangles:Right(), ang.pitch)
eyeangles.pitch = math.Clamp(ang.pitch, -89, 89)
eyeangles.roll = 0
hitent:SetEyeAngles(eyeangles)
end
end
end