DeriveGamemode( "fretta" ) include("vgui/continuevote.lua") ---- Continue vote at end of round local cont_chooser = nil local function GetContinueChooser() if IsValid(cont_chooser) then return cont_chooser end cont_chooser = vgui.Create("ContinueVote") return cont_chooser end function GM:ShowContinueChooser() GetContinueChooser():Show() end function GM:HideContinueChooser() GetContinueChooser():Hide() end function GM:ContinueVoted(want) if GetGlobalBool("InContinueVote", false) then RunConsoleCommand("votecontinue", want and 1 or 0) end end ---- Fretta overrides/fixes -- fuck off deathnotice element util.SafeRemoveHook("InitPostEntity", "CreateDeathNotify") function GM:DrawPlayerRing(ply) end util.SafeRemoveHook("PrePlayerDraw", "DrawPlayerRing") function GM:InputMouseApply(cmd, x, y, angle) end function GM:Move(ply, mv) end function GM:KeyPress(ply, key) end function GM:KeyRelease(ply, key) end local logo = surface.GetTextureID("VGUI/ttt/score_logo") local lw, lh = 215 / 2, 220 / 2 local helptxt = {text="If you're new to the game, press F1 for instructions!", font="Trebuchet22", xalign=TEXT_ALIGN_CENTER, color=COLOR_WHITE} local bgcolor = Color(200, 0, 0, 40) function GM:PaintSplashScreen(w, h) draw.RoundedBox(16, w/2 - 230, h/2 - 128, 460, 256, bgcolor) surface.SetTexture( logo ) surface.SetDrawColor( 255, 255, 255, 255 ) surface.DrawTexturedRect( w / 2 - lw, h / 2 - lh, 256, 256 ) helptxt.pos = {w / 2, h / 2 + 80} draw.Text(helptxt) draw.TextShadow(helptxt, 2, 255) end function GM:CalcView( ply, origin, angles, fov ) local view = {origin=origin, angles=angles, fov=fov} local wep = ply:GetActiveWeapon() if ( ValidEntity( wep ) ) then local func = wep.GetViewModelPosition if ( func ) then view.vm_origin, view.vm_angles = func( wep, origin*1, angles*1 ) end local func = wep.CalcView if ( func ) then view.origin, view.angles, view.fov = func( wep, ply, origin*1, angles*1, fov ) end end return view end