28 lines
764 B
Lua
28 lines
764 B
Lua
ENT.Type = "anim"
|
|
ENT.Base = "base_gmodentity"
|
|
ENT.PrintName = "Wire Entity"
|
|
ENT.Author = "Erkle"
|
|
ENT.Contact = "ErkleMad@gmail.com"
|
|
ENT.Purpose = "Base for all wired SEnts"
|
|
ENT.Instructions = ""
|
|
ENT.Spawnable = false
|
|
ENT.AdminSpawnable = false
|
|
ENT.IsWire = true
|
|
|
|
function ENT:GetOverlayText()
|
|
local name = self.Entity:GetNetworkedString("WireName")
|
|
//local txt = self.BaseClass.BaseClass.GetOverlayText(self) or ""
|
|
local txt = self.Entity:GetNetworkedBeamString("GModOverlayText") or ""
|
|
if (not SinglePlayer()) then
|
|
local PlayerName = self:GetPlayerName()
|
|
txt = txt .. "\n(" .. PlayerName .. ")"
|
|
end
|
|
if(name and name ~= "") then
|
|
if (txt == "") then
|
|
return "- "..name.." -"
|
|
end
|
|
return "- "..name.." -\n"..txt
|
|
end
|
|
return txt
|
|
end
|