gamemode: Implement a fully featured Scoreboard

The original game mode had a Scoreboard and now Prop Hunt Extended also has one. As usual, it has separation by team (Spectator, Hider, Seeker) and has the game mode logo in the top left. This score board is kept very simple and is non-interactive.

Media: https://drive.google.com/uc?id=12uVh2-BSC3p_aPgRSWNRdz3M0zbBj2BZ
This commit is contained in:
Michael Fabian 'Xaymar' Dirks
2017-11-26 14:44:26 +01:00
parent f5dacddd8c
commit 6b2ff0b55f
4 changed files with 353 additions and 0 deletions
@@ -26,6 +26,7 @@
--! Includes
-- ------------------------------------------------------------------------- --
include("sh_init.lua")
include("derma/dscoreboard.lua")
GM.UI = {}
include("client/cl_ui_help.lua")
@@ -54,6 +55,9 @@ function GM:Initialize()
surface.CreateFont("Roboto48Bold", {font="Roboto Bold", extended=true, size=48, weight=500, antialias=true})
surface.CreateFont("RobotoBoldCondensed160", {font="Roboto Bold Condensed", extended=true, size=160, weight=800, antialias=true})
print("Prop Hunt CL: Initializing User Interface...")
self.UI.Scoreboard = vgui.Create("DScoreBoard")
print("Prop Hunt CL: Complete.")
print("-------------------------------------------------------------------------")
end
@@ -177,6 +181,14 @@ function GM:OnSpawnMenuClose()
net.SendToServer()
end
function GM:ScoreboardShow()
self.UI.Scoreboard:Show()
end
function GM:ScoreboardHide()
self.UI.Scoreboard:Hide()
end
function GM:ShowHelpUI()
self.UI.Help:Show()
end