Advertisement
Guest User

Untitled

a guest
May 25th, 2015
217
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.57 KB | None | 0 0
  1. hook.Add("OnPlayerChat", "AddDeadAndTeamTags", function(ply, strText, bTeamOnly, bPlayerIsDead)
  2.     local tab = {}
  3.     if ( !ply:Alive() ) then
  4.         table.insert( tab, Color( 255, 30, 40 ) )
  5.         table.insert( tab, "*DEAD* " )
  6.     end
  7.     if ( Chatbox.TeamChat ) then
  8.         table.insert( tab, Color( 255, 255, 255 ) )
  9.         table.insert( tab, "[TEAM] " )
  10.     end
  11.     if ( IsValid( ply ) ) then
  12.         table.insert( tab, ply )
  13.     else
  14.         table.insert( tab, "Console" )
  15.     end
  16.     table.insert( tab, Color( 255, 255, 255 ) )
  17.     table.insert( tab, ": " .. strText )
  18.     chat.AddText( unpack(tab) )
  19.     return true
  20. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement