This commit is contained in:
lifestorm
2024-08-04 23:54:45 +03:00
parent 0e770b2b49
commit df294d03aa
7526 changed files with 4011945 additions and 15 deletions

View 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/
--]]
AddCSLuaFile("shared.lua")
include('shared.lua')
/*-----------------------------------------------
*** Copyright (c) 2012-2023 by DrVrej, All rights reserved. ***
No parts of this code or any of its contents may be reproduced, copied, modified or adapted,
without the prior written consent of the author, unless otherwise indicated for stand-alone materials.
-----------------------------------------------*/
ENT.Model = {"models/vj_hlr/hl1/tank_cannon_new.mdl"} -- The game will pick a random model from the table when the SNPC is spawned | Add as many as you want
ENT.StartHealth = 0
ENT.VJ_NPC_Class = {"CLASS_UNITED_STATES"} -- NPCs with the same class with be allied to each other
ENT.HasDeathRagdoll = false -- If set to false, it will not spawn the regular ragdoll of the SNPC
-- Tank Base
ENT.Tank_SoundTbl_Turning = {"vj_hlr/hl1_npc/tanks/abrams_turret_rot.wav"}
ENT.Tank_SoundTbl_ReloadShell = {"vj_hlr/hl1_npc/tanks/tank_reload.wav"}
ENT.Tank_SoundTbl_FireShell = {"vj_hlr/hl1_npc/tanks/shoot.wav"}
ENT.Tank_AngleDiffuseNumber = 0
ENT.Tank_Shell_SpawnPos = Vector(221.83, 1.24, 95.09)
ENT.Tank_Shell_EntityToSpawn = "obj_vj_hlr1_rocket" -- The entity that is spawned when the shell is fired
ENT.Tank_Shell_VelocitySpeed = 3000 -- How fast should the tank shell travel?
ENT.Tank_Shell_DynamicLightPos = Vector(267.83, 1.24, 91.09)
ENT.Tank_Shell_MuzzleFlashPos = Vector(267.83, 1.24, 91.09)
ENT.Tank_Shell_ParticlePos = Vector(267.83, 1.24, 91.09)
util.AddNetworkString("vj_hlr1_m1a1abrams_shooteffects")
---------------------------------------------------------------------------------------------------------------------------------------------
function ENT:StartShootEffects()
net.Start("vj_hlr1_m1a1abrams_shooteffects")
net.WriteEntity(self)
net.Broadcast()
end

View File

@@ -0,0 +1,46 @@
--[[
| 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/
--]]
ENT.Base = "npc_vj_tankg_base"
ENT.Type = "ai"
ENT.PrintName = "M1A1 Abrams"
ENT.Author = "DrVrej"
ENT.Contact = "http://steamcommunity.com/groups/vrejgaming"
ENT.Purpose = "Spawn it and fight with it!"
ENT.Instructions = "Click on the spawnicon to spawn it."
ENT.Category = "Half-Life Resurgence"
if CLIENT then
local Name = "M1A1 Abrams"
local LangName = "npc_vj_hlr1_m1a1abrams_gun"
language.Add(LangName, Name)
killicon.Add(LangName,"HUD/killicons/default",Color(255,80,0,255))
language.Add("#"..LangName, Name)
killicon.Add("#"..LangName,"HUD/killicons/default",Color(255,80,0,255))
end
---------------------------------------------------------------------------------------------------------------------------------------------
local vec = Vector(267.83, 1.24, 91.09)
--
net.Receive("vj_hlr1_m1a1abrams_shooteffects", function()
local ent = net.ReadEntity()
if IsValid(ent) then
ent.Emitter = ParticleEmitter(ent:GetPos())
ent.SmokeEffect2 = ent.Emitter:Add("particles/smokey", ent:LocalToWorld(vec))
ent.SmokeEffect2:SetVelocity(ent:GetForward()*math.Rand(0, -50) + Vector(0, -30, math.Rand(-10, -20)) + ent:GetVelocity())
ent.SmokeEffect2:SetDieTime(2)
ent.SmokeEffect2:SetStartAlpha(30)
ent.SmokeEffect2:SetEndAlpha(0)
ent.SmokeEffect2:SetStartSize(3)
ent.SmokeEffect2:SetEndSize(50)
ent.SmokeEffect2:SetRoll(math.Rand(-0.2, 0.2))
ent.SmokeEffect2:SetColor(150, 150, 150, 255)
ent.Emitter:Finish()
end
end)