mirror of
https://github.com/lifestorm/wnsrc.git
synced 2025-12-17 13:53:45 +03:00
46 lines
983 B
Lua
46 lines
983 B
Lua
--[[
|
|
| 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/
|
|
--]]
|
|
|
|
local AddCSLuaFile = AddCSLuaFile
|
|
local IsValid = IsValid
|
|
local ents = ents
|
|
local Vector = Vector
|
|
local timer = timer
|
|
|
|
AddCSLuaFile()
|
|
|
|
ENT.Type = "anim"
|
|
ENT.PrintName = "Sandbag"
|
|
ENT.Category = "HL2 RP"
|
|
ENT.Spawnable = true
|
|
ENT.AdminOnly = true
|
|
ENT.RenderGroup = RENDERGROUP_BOTH
|
|
ENT.PhysgunDisable = true
|
|
|
|
if (SERVER) then
|
|
function ENT:Initialize()
|
|
self:SetModel("models/mosi/fallout4/props/fortifications/sandbag01.mdl")
|
|
self:SetSolid(SOLID_VPHYSICS)
|
|
self:SetMoveType(MOVETYPE_VPHYSICS)
|
|
self:SetUseType(SIMPLE_USE)
|
|
self:PhysicsInit(SOLID_VPHYSICS)
|
|
|
|
local physObj = self:GetPhysicsObject()
|
|
|
|
if (IsValid(physObj)) then
|
|
physObj:EnableMotion(false)
|
|
physObj:Sleep()
|
|
end
|
|
|
|
end
|
|
|
|
function ENT:OnRemove()
|
|
end
|
|
end |