Skip to content

Commit ef4a583

Browse files
committed
Use no draw instead of transparent color
1 parent 431d937 commit ef4a583

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

lua/entities/ucs_mineable/init.lua

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,9 @@ end
3131
function ENT:Show()
3232
self:SetSolid( SOLID_VPHYSICS )
3333
self:SetMoveType( MOVETYPE_VPHYSICS )
34-
self:SetColor( color_white )
3534
self:SetNWBool( "IsHidden", false )
3635
self:SetHealth( self:GetMaxHealth() )
37-
self:DrawShadow( true )
36+
self:SetNoDraw( false )
3837
local phys = self:GetPhysicsObject()
3938
if phys:IsValid() then
4039
phys:EnableMotion( false )
@@ -44,12 +43,10 @@ end
4443

4544
function ENT:Hide()
4645
local tbl = self:GetData()
47-
local color = self:GetColor()
4846
self:SetSolid( SOLID_NONE )
4947
self:SetMoveType( MOVETYPE_NONE )
50-
self:SetColor( ColorAlpha( color, 0 ) )
5148
self:SetNWBool( "IsHidden", true )
52-
self:DrawShadow( false )
49+
self:SetNoDraw( true )
5350
timer.Create( "Hidden_"..self:EntIndex(), tbl.Respawn or 300, 1, function()
5451
if IsValid( self ) then self:Show() end
5552
end )

0 commit comments

Comments
 (0)