From 4261e934cb88317582b11595935749976caa9684 Mon Sep 17 00:00:00 2001 From: Blixibon Date: Thu, 24 Jul 2025 11:49:07 -0500 Subject: [PATCH] Add game_timer files --- .../scripts/hudanimations_manifest.txt | 7 + .../scripts/hudlayout.res | 15 + .../scripts/hudanimations.txt | 967 ------------------ .../scripts/hudanimations_manifest.txt | 6 + .../scripts/hudanimations_mapbase_hl2.txt | 210 ++++ .../hl2_mapbase_content/scripts/hudlayout.res | 15 + .../materials/editor/game_timer.vmt | 7 + .../materials/editor/game_timer.vtf | Bin 0 -> 5696 bytes 8 files changed, 260 insertions(+), 967 deletions(-) create mode 100644 VPKs/episodic_mapbase_content/scripts/hudanimations_manifest.txt delete mode 100644 VPKs/hl2_mapbase_content/scripts/hudanimations.txt create mode 100644 VPKs/hl2_mapbase_content/scripts/hudanimations_manifest.txt create mode 100644 VPKs/hl2_mapbase_content/scripts/hudanimations_mapbase_hl2.txt create mode 100644 VPKs/shared_content_v7_0/materials/editor/game_timer.vmt create mode 100644 VPKs/shared_content_v7_0/materials/editor/game_timer.vtf diff --git a/VPKs/episodic_mapbase_content/scripts/hudanimations_manifest.txt b/VPKs/episodic_mapbase_content/scripts/hudanimations_manifest.txt new file mode 100644 index 0000000..99fd754 --- /dev/null +++ b/VPKs/episodic_mapbase_content/scripts/hudanimations_manifest.txt @@ -0,0 +1,7 @@ +hudanimations_manifest +{ + + "file" "scripts/hudanimations.txt" + "file" "scripts/hudanimations_ep2.txt" + "file" "scripts/hudanimations_mapbase_hl2.txt" +} \ No newline at end of file diff --git a/VPKs/episodic_mapbase_content/scripts/hudlayout.res b/VPKs/episodic_mapbase_content/scripts/hudlayout.res index 065a490..31fd553 100644 --- a/VPKs/episodic_mapbase_content/scripts/hudlayout.res +++ b/VPKs/episodic_mapbase_content/scripts/hudlayout.res @@ -740,6 +740,21 @@ "tall" "100" } + //============================== + // + // Mapbase-specific + // + //============================== + HudGenericGameTimer + { + "fieldName" "HudGenericGameTimer" + "visible" "1" + "enabled" "1" + "wide" "640" + "tall" "480" + "zpos" "1" + } + //============================== // // Below is ported from HL2:DM diff --git a/VPKs/hl2_mapbase_content/scripts/hudanimations.txt b/VPKs/hl2_mapbase_content/scripts/hudanimations.txt deleted file mode 100644 index fbd5598..0000000 --- a/VPKs/hl2_mapbase_content/scripts/hudanimations.txt +++ /dev/null @@ -1,967 +0,0 @@ -// sample animation script -// -// -// commands: -// Animate -// variables: -// FgColor -// BgColor -// Position -// Size -// Blur (hud panels only) -// TextColor (hud panels only) -// Ammo2Color (hud panels only) -// Alpha (hud weapon selection only) -// SelectionAlpha (hud weapon selection only) -// TextScan (hud weapon selection only) -// -// interpolator: -// Linear -// Accel - starts moving slow, ends fast -// Deaccel - starts moving fast, ends slow -// -// RunEvent -// starts another even running at the specified time -// -// StopEvent -// stops another event that is current running at the specified time -// -// StopAnimation -// stops all animations refering to the specified variable in the specified panel -// -// StopPanelAnimations -// stops all active animations operating on the specified panel -// -// -// Useful game console commands: -// cl_Animationinfo or -// displays all the animatable variables for the hud element -// - - -event LevelInit -{ -} - -event WeaponHighlight -{ - Animate HudWeaponSelection Blur "7" Linear 0.0 0.0 - Animate HudWeaponSelection Blur "0" Deaccel 0.01 0.75 - - Animate HudWeaponSelection SelectedBoxColor "250 220 0 80" Linear 0.0 0.01 - Animate HudWeaponSelection SelectedBoxColor "BgColor" Deaccel 0.1 1.5 - Animate HudWeaponSelection SelectedFgColor "BrightFg" Linear 0.0 0.1 - Animate HudWeaponSelection SelectedFgColor "FgColor" Linear 5.0 1.5 -} - -event OpenWeaponSelectionMenu -{ - StopEvent CloseWeaponSelectionMenu 0.0 - StopEvent WeaponPickup 0.0 - StopEvent FadeOutWeaponSelectionMenu 0.0 - - // make the display visible - Animate HudWeaponSelection Alpha "128" Linear 0.0 0.1 [$WIN32] - Animate HudWeaponSelection Alpha "192" Linear 0.0 0.1 [$X360] - Animate HudWeaponSelection SelectionAlpha "255" Linear 0.0 0.1 - Animate HudWeaponSelection FgColor "FgColor" Linear 0.0 0.1 - Animate HudWeaponSelection TextColor "BrightFg" Linear 0.0 0.1 - Animate HudWeaponSelection TextScan "1" Linear 0.0 0.1 -} - -event CloseWeaponSelectionMenu -{ - // hide the whole thing near immediately - Animate HudWeaponSelection FgColor "0 0 0 0" Linear 0.0 0.1 - Animate HudWeaponSelection TextColor "0 0 0 0" Linear 0.0 0.1 - Animate HudWeaponSelection Alpha "0" Linear 0.0 0.1 - Animate HudWeaponSelection SelectionAlpha "0" Linear 0.0 0.1 -} - -event FadeOutWeaponSelectionMenu -{ - // slowly hide the whole thing - Animate HudWeaponSelection FgColor "0 0 0 0" Linear 0.5 1.0 - Animate HudWeaponSelection TextColor "0 0 0 0" Linear 0.5 1.0 - Animate HudWeaponSelection Alpha "0" Linear 0.5 1.0 - Animate HudWeaponSelection SelectionAlpha "0" Linear 0.5 1.0 - - Animate HudWeaponSelection WeaponBoxDist1Alpha "0 0 0 0" Linear 0.0 0.5 - Animate HudWeaponSelection WeaponBoxDist2Alpha "0 0 0 0" Linear 0.0 0.5 - Animate HudWeaponSelection WeaponBoxDist3Alpha "0 0 0 0" Linear 0.0 0.5 -} - -event SuitAuxPowerMax -{ - // hide the suit power - Animate HudSuitPower BgColor "0 0 0 0" Linear 0.0 0.4 - Animate HudSuitPower AuxPowerColor "0 0 0 0" Linear 0.0 0.4 -} - -event SuitAuxPowerNotMax -{ - // show suit power - Animate HudSuitPower BgColor "BgColor" Linear 0.0 0.4 - Animate HudSuitPower AuxPowerColor "255 220 0 220" Linear 0.0 0.4 -} - -event SuitAuxPowerDecreasedBelow25 -{ - // make color red - Animate HudSuitPower AuxPowerColor "255 0 0 220" Linear 0.0 0.4 -} - -event SuitAuxPowerIncreasedAbove25 -{ - // make colr bright - Animate HudSuitPower AuxPowerColor "255 220 0 220" Linear 0.0 0.4 -} - -event SuitAuxPowerNoItemsActive -{ - // resize the aux power to be the smallest size - Animate HudSuitPower Size "102 26" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 400" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 32" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 378" Linear 0.0 0.4 [$X360] -} - -event SuitAuxPowerOneItemActive -{ - // resize the aux power to fit one item - Animate HudSuitPower Size "102 36" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 390" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 42" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 368" Linear 0.0 0.4 [$X360] -} - -event SuitAuxPowerTwoItemsActive -{ - // resize the aux power to fit two items - Animate HudSuitPower Size "102 46" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 380" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 52" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 358" Linear 0.0 0.4 [$X360] -} - -event SuitAuxPowerThreeItemsActive -{ - // resize the aux power to fit three items - Animate HudSuitPower Size "102 56" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 370" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 62" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 348" Linear 0.0 0.4 [$X360] -} - -// Mapbase -event SuitAuxPowerFourItemsActive -{ - // resize the aux power to fit four items - Animate HudSuitPower Size "102 66" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 360" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 72" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 338" Linear 0.0 0.4 [$X360] -} - -// Mapbase -event SuitAuxPowerFiveItemsActive -{ - // resize the aux power to fit five items - Animate HudSuitPower Size "102 76" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 350" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 82" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 328" Linear 0.0 0.4 [$X360] -} - -// Mapbase -event SuitAuxPowerSixItemsActive -{ - // resize the aux power to fit six items - Animate HudSuitPower Size "102 86" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Position "16 340" Linear 0.0 0.4 [$WIN32] - Animate HudSuitPower Size "102 92" Linear 0.0 0.4 [$X360] - Animate HudSuitPower Position "48 318" Linear 0.0 0.4 [$X360] -} - -event SuitFlashlightOn -{ - Animate HudFlashlight TextColor "255 220 0 255" Linear 0.0 0.1 - Animate HudFlashlight TextColor "255 220 0 160" Deaccel 0.1 0.75 - Animate HudFlashlight BgColor "BgColor" Linear 0.0 0.75 -} - -event SuitFlashlightOff -{ - StopEvent SuitFlashlightOn 0.0 - Animate HudFlashlight TextColor "0 0 0 0" Linear 0.0 0.4 - Animate HudFlashlight BgColor "0 0 0 0" Linear 0.0 0.4 -} - -event HudTakeDamageFront -{ -} - -event HudTakeDamageLeft -{ - Animate HudDamageIndicator DmgColorLeft "255 88 0 200" Linear 0.0 0.0 - Animate HudDamageIndicator DmgColorLeft "255 0 0 200" Linear 0.0 0.3 - Animate HudDamageIndicator DmgColorLeft "255 0 0 0" Deaccel 0.3 0.5 -} - -event HudTakeDamageRight -{ - Animate HudDamageIndicator DmgColorRight "255 88 0 200" Linear 0.0 0.0 - Animate HudDamageIndicator DmgColorRight "255 0 0 200" Linear 0.0 0.3 - Animate HudDamageIndicator DmgColorRight "255 0 0 0" Deaccel 0.3 0.5 -} - -event HudTakeDamageBehind -{ - RunEvent HudTakeDamageLeft 0.0 - RunEvent HudTakeDamageRight 0.0 -} - -event HudTakeDamageHighLeft -{ - Animate HudDamageIndicator DmgHighColorLeft "255 88 0 255" Linear 0.0 0.0 - Animate HudDamageIndicator DmgHighColorLeft "255 0 0 200" Linear 0.0 0.4 - Animate HudDamageIndicator DmgHighColorLeft "255 0 0 0" Deaccel 0.4 2.4 -} - -event HudTakeDamageHighRight -{ - Animate HudDamageIndicator DmgHighColorRight "255 88 0 255" Linear 0.0 0.0 - Animate HudDamageIndicator DmgHighColorRight "255 0 0 200" Linear 0.0 0.4 - Animate HudDamageIndicator DmgHighColorRight "255 0 0 0" Deaccel 0.4 2.4 -} - -event HudTakeDamageHigh -{ - Animate HudDamageIndicator DmgFullscreenColor "255 88 0 200" Linear 0.0 0.0 - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 200" Linear 0.0 0.4 - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 0" Deaccel 0.4 2.4 -} - -event HudTakeDamageDrown -{ - RunEvent HudTakeDamageBehind 0.0 -} - -event HudTakeDamagePoison -{ - Animate HudDamageIndicator DmgFullscreenColor "255 236 128 240" Linear 0.0 0.0 - Animate HudDamageIndicator DmgFullscreenColor "255 236 128 0" Deaccel 0.4 0.8 -} - -event HudTakeDamageBurn -{ - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 200" Linear 0.0 0.0 - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 0" Deaccel 0.2 0.4 -} - -event HudTakeDamageRadiation -{ - Animate HudDamageIndicator DmgFullscreenColor "255 255 255 128" Deaccel 0.0 0.1 - Animate HudDamageIndicator DmgFullscreenColor "255 255 255 0" Deaccel 0.1 0.4 - RunEvent HudTakeDamageBehind 0.0 -} - -event HudPlayerDeath -{ - StopEvent HealthLoop 0.0 - StopEvent HealthPulse 0.0 - - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 96" Deaccel 0.1 0.2 - Animate HudDamageIndicator DmgFullscreenColor "255 0 0 255" Deaccel 0.3 4.0 -} - -event HealthIncreasedAbove20 -{ - StopEvent HealthLoop 0.0 - StopEvent HealthPulse 0.0 - StopEvent HealthLow 0.0 - - Animate HudHealth BgColor "BgColor" Linear 0.0 0.0 - - Animate HudHealth TextColor "FgColor" Linear 0.0 0.04 - Animate HudHealth FgColor "FgColor" Linear 0.0 0.03 - - Animate HudHealth Blur "3" Linear 0.0 0.1 - Animate HudHealth Blur "0" Deaccel 0.1 2.0 -} - -event HealthIncreasedBelow20 -{ - Animate HudHealth FgColor "BrightFg" Linear 0.0 0.25 - Animate HudHealth FgColor "FgColor" Linear 0.3 0.75 - - Animate HudHealth Blur "3" Linear 0.0 0.1 - Animate HudHealth Blur "0" Deaccel 0.1 2.0 -} - -event SuitPowerIncreasedAbove20 -{ - StopEvent SuitLoop 0.0 - StopEvent SuitPulse 0.0 - StopEvent SuitPowerZero 0.0 - - Animate HudSuit Alpha "255" Linear 0.0 0.0 - - Animate HudSuit BgColor "BgColor" Linear 0.0 0.0 - - Animate HudSuit TextColor "FgColor" Linear 0.0 0.05 - Animate HudSuit FgColor "FgColor" Linear 0.0 0.05 - - Animate HudSuit Blur "3" Linear 0.0 0.1 - Animate HudSuit Blur "0" Deaccel 0.1 2.0 -} - - -event SuitPowerIncreasedBelow20 -{ - StopEvent SuitPowerZero 0.0 - Animate HudSuit Alpha "255" Linear 0.0 0.0 - - Animate HudSuit FgColor "BrightFg" Linear 0.0 0.25 - Animate HudSuit FgColor "FgColor" Linear 0.3 0.75 - - Animate HudSuit Blur "3" Linear 0.0 0.1 - Animate HudSuit Blur "0" Deaccel 0.1 2.0 -} - -event SuitPowerZero -{ - StopEvent SuitLoop 0.0 - StopEvent SuitPulse 0.0 - StopEvent SuitArmorLow 0.0 - StopEvent SuitDamageTaken 0.0 - - Animate HudSuit Alpha "0" Linear 0.0 0.4 -} - -event TestMovement -{ - Animate HudHealth Position "256 120" Linear 0.0 2.0 - Animate HudHealth Size "128 24" Linear 0.0 1.5 -} - -event HealthDamageTaken -{ - Animate HudHealth FgColor "BrightFg" Linear 0.0 0.25 - Animate HudHealth FgColor "FgColor" Linear 0.3 0.75 - - Animate HudHealth Blur "3" Linear 0.0 0.1 - Animate HudHealth Blur "0" Deaccel 0.1 2.0 - - Animate HudHealth TextColor "BrightFg" Linear 0.0 0.1 - Animate HudHealth TextColor "FgColor" Deaccel 0.1 1.2 -} - -event SuitDamageTaken -{ - Animate HudSuit FgColor "BrightFg" Linear 0.0 0.25 - Animate HudSuit FgColor "FgColor" Linear 0.3 0.75 - - Animate HudSuit Blur "3" Linear 0.0 0.1 - Animate HudSuit Blur "0" Deaccel 0.1 2.0 - - Animate HudSuit TextColor "BrightFg" Linear 0.0 0.1 - Animate HudSuit TextColor "FgColor" Deaccel 0.1 1.2 -} - -// health has been damaged to below 20% -event HealthLow -{ - StopEvent HealthDamageTaken 0.0 - StopEvent HealthPulse 0.0 - StopEvent HealthLoop 0.0 - - Animate HudHealth BgColor "DamagedBg" Linear 0.0 0.1 - Animate HudHealth BgColor "BgColor" Deaccel 0.1 1.75 - - Animate HudHealth FgColor "BrightFg" Linear 0.0 0.2 - Animate HudHealth FgColor "DamagedFg" Linear 0.2 1.2 - - Animate HudHealth TextColor "BrightFg" Linear 0.0 0.1 - Animate HudHealth TextColor "DamagedFg" Linear 0.1 1.2 - - Animate HudHealth Blur "5" Linear 0.0 0.1 - Animate HudHealth Blur "3" Deaccel 0.1 0.9 - - RunEvent HealthPulse 1.0 -} - -event HealthPulse -{ - Animate HudHealth Blur "5" Linear 0.0 0.1 - Animate HudHealth Blur "2" Deaccel 0.1 0.8 - Animate HudHealth TextColor "BrightDamagedFg" Linear 0.0 0.1 - Animate HudHealth TextColor "DamagedFg" Deaccel 0.1 0.8 - Animate HudHealth BgColor "100 0 0 80" Linear 0.0 0.1 - Animate HudHealth BgColor "BgColor" Deaccel 0.1 0.8 - - RunEvent HealthLoop 0.8 -} - -// call to loop HealthPulse -event HealthLoop -{ - RunEvent HealthPulse 0.0 -} - - -// suit armor has been damaged to below 20% -event SuitArmorLow -{ - StopEvent SuitDamageTaken 0.0 - StopEvent SuitPulse 0.0 - StopEvent SuitLoop 0.0 - -// removing this effect -- matching it to the event for normal suit damage -// so, there will be no special indication (redness, flashing) -// in the hud that the suit armor is low - -// Animate HudSuit BgColor "DamagedBg" Linear 0.0 0.1 -// Animate HudSuit BgColor "BgColor" Deaccel 0.1 1.75 - - Animate HudSuit FgColor "BrightFg" Linear 0.0 0.25 - Animate HudSuit FgColor "FgColor" Linear 0.3 0.75 - - Animate HudSuit Blur "3" Linear 0.0 0.1 - Animate HudSuit Blur "0" Deaccel 0.1 2.0 - - Animate HudSuit TextColor "BrightFg" Linear 0.0 0.1 - Animate HudSuit TextColor "FgColor" Deaccel 0.1 1.2 - -// RunEvent SuitPulse 1.0 -} - -event SuitPulse -// this even no longer gets called -{ - Animate HudSuit Blur "5" Linear 0.0 0.1 - Animate HudSuit Blur "2" Deaccel 0.1 0.8 - Animate HudSuit TextColor "BrightDamagedFg" Linear 0.0 0.1 - Animate HudSuit TextColor "DamagedFg" Deaccel 0.1 0.8 - Animate HudSuit BgColor "100 0 0 80" Linear 0.0 0.1 - Animate HudSuit BgColor "BgColor" Deaccel 0.1 0.8 - RunEvent SuitLoop 0.8 -} - -event SuitLoop -{ -// this event no longer gets called - RunEvent SuitPulse 0.0 -} - -// ammo has been picked up -event AmmoIncreased -{ - Animate HudAmmo FgColor "BrightFg" Linear 0.0 0.15 - Animate HudAmmo FgColor "FgColor" Deaccel 0.15 1.5 - Animate HudAmmo Blur "5" Linear 0.0 0.0 - Animate HudAmmo Blur "0" Accel 0.01 1.5 -} - -// ammo has been decreased, but there is still some remaining -event AmmoDecreased -{ - StopEvent AmmoIncreased 0.0 - - Animate HudAmmo Blur "7" Linear 0.0 0.0 - Animate HudAmmo Blur "0" Deaccel 0.1 1.5 - - Animate HudAmmo TextColor "BrightFg" Linear 0.0 0.1 - Animate HudAmmo TextColor "FgColor" Deaccel 0.1 0.75 -} - -// primary ammo is zero -event AmmoEmpty -{ - Animate Hudammo FgColor "BrightDamagedFg" Linear 0.0 0.2 - Animate Hudammo FgColor "DamagedFg" Accel 0.2 1.2 -} - -// ammo2 is the total ammo for a weapon that uses clip ammo -event Ammo2Increased -{ - Animate Hudammo ammo2color "BrightFg" Linear 0.0 0.2 - Animate Hudammo ammo2color "FgColor" Accel 0.2 1.2 -} - -// total ammo has been decreased, but there is still some remaining -event Ammo2Decreased -{ - Animate Hudammo ammo2color "BrightFg" Linear 0.0 0.2 - Animate Hudammo ammo2color "FgColor" Accel 0.2 1.2 -} - -// total ammo is zero -event Ammo2Empty -{ - Animate Hudammo ammo2color "BrightDamagedFg" Linear 0.0 0.2 - Animate Hudammo ammo2color "DamagedFg" Accel 0.2 1.2 -} - -event AmmoSecondaryIncreased -{ - Animate HudAmmoSecondary FgColor "BrightFg" Linear 0.0 0.15 - Animate HudAmmoSecondary FgColor "FgColor" Deaccel 0.15 1.5 - Animate HudAmmoSecondary Blur "5" Linear 0.0 0.0 - Animate HudAmmoSecondary Blur "0" Accel 0.01 1.5 -} - -event AmmoSecondaryDecreased -{ - StopEvent AmmoSecondaryIncreased 0.0 - - Animate HudAmmoSecondary Blur "7" Linear 0.0 0.0 - Animate HudAmmoSecondary Blur "0" Deaccel 0.1 1.5 - - Animate HudAmmoSecondary TextColor "BrightFg" Linear 0.0 0.1 - Animate HudAmmoSecondary TextColor "FgColor" Deaccel 0.1 0.75 -} - -event AmmoSecondaryEmpty -{ - Animate HudAmmoSecondary FgColor "BrightDamagedFg" Linear 0.0 0.2 - Animate HudAmmoSecondary FgColor "DamagedFg" Accel 0.2 1.2 - Animate HudAmmoSecondary Blur "7" Linear 0.0 0.0 - Animate HudAmmoSecondary Blur "0" Deaccel 0.1 1.5 - -} - -// current weapon has been changed -event WeaponChanged -{ - Animate HudAmmo BgColor "250 220 0 80" Linear 0.0 0.1 - Animate HudAmmo BgColor "BgColor" Deaccel 0.1 1.0 - Animate HudAmmo FgColor "BrightFg" Linear 0.0 0.1 - Animate HudAmmo FgColor "FgColor" Linear 0.2 1.5 -} - -// ran if we just changed to a weapon that needs clip ammo -event WeaponUsesClips [$WIN32] -{ - Animate HudAmmo Position "r150 432" Deaccel 0.0 0.4 - Animate HudAmmo Size "132 36" Deaccel 0.0 0.4 -} -event WeaponUsesClips [$X360] -{ - Animate HudAmmo Position "r208 416" Deaccel 0.001 0.4 - Animate HudAmmo Size "160 36" Deaccel 0.0 0.4 -} - -// ran if we just changed to a weapon that does not use clip ammo -event WeaponDoesNotUseClips [$WIN32] -{ - Animate HudAmmo Position "r118 432" Deaccel 0.0 0.4 - Animate HudAmmo Size "100 36" Deaccel 0.0 0.4 -} -event WeaponDoesNotUseClips [$X360] -{ - Animate HudAmmo Position "r175 416" Deaccel 0.0 0.4 - Animate HudAmmo Size "125 36" Deaccel 0.0 0.4 -} - -event WeaponUsesSecondaryAmmo -{ - StopAnimation HudAmmo Position 0.0 - StopAnimation HudAmmo Size 0.0 - StopPanelAnimations HudAmmoSecondary 0.0 - //StopPanelAnimations HudAmmo 0.0 - - Animate HudAmmoSecondary BgColor "250 220 0 60" Linear 0.0 0.1 - Animate HudAmmoSecondary BgColor "BgColor" Deaccel 0.1 1.0 - Animate HudAmmoSecondary FgColor "BrightFg" Linear 0.0 0.1 - Animate HudAmmoSecondary FgColor "FgColor" Linear 0.2 1.5 - Animate HudAmmoSecondary Alpha 255 Linear 0.0 0.1 - - Animate HudAmmo Position "r222 432" Deaccel 0.0 0.5 [$WIN32] - Animate HudAmmo Size "132 36" Deaccel 0.0 0.4 [$WIN32] - Animate HudAmmo Position "r279 416" Deaccel 0.0 0.5 [$X360] - Animate HudAmmo Size "155 36" Deaccel 0.0 0.4 [$X360] -} - -event WeaponDoesNotUseSecondaryAmmo -{ - StopPanelAnimations HudAmmoSecondary 0.0 - Animate HudAmmoSecondary FgColor "0 0 0 0" Linear 0.0 0.4 - Animate HudAmmoSecondary BgColor "0 0 0 0" Linear 0.0 0.4 - Animate HudAmmoSecondary Alpha 0 Linear 0.0 0.1 -} - -event CraneMagnetFlash -{ - Animate HudCraneMagnet TextColor "255 220 0 255" Linear 0.0 0.1 - Animate HudCraneMagnet TextColor "255 220 0 160" Deaccel 0.1 0.3 - Animate HudCraneMagnet TextColor "255 170 0 220" Deaccel 0.4 0.3 - Animate HudCraneMagnet TextColor "255 220 0 255" Linear 0.8 0.2 -} - -event HintMessageShow -{ - StopPanelAnimations HudHintDisplay 0.0 - - Animate HudHintDisplay HintSize "1" Deaccel 0.0 0.3 - Animate HudHintDisplay FgColor "FgColor" Linear 0.4 0.4 - - // flash text - Animate HudHintDisplay FgColor "FgColor" Linear 1.5 0.01 - Animate HudHintDisplay FgColor "255 220 0 255" Linear 2.0 0.2 - Animate HudHintDisplay FgColor "FgColor" Linear 2.2 0.2 - Animate HudHintDisplay FgColor "255 220 0 255" Linear 3.0 0.2 - Animate HudHintDisplay FgColor "FgColor" Linear 3.2 0.2 - - // hide the panel after a while - Animate HudHintDisplay FgColor "255 220 0 0" Linear 10.0 0.2 - Animate HudHintDisplay HintSize "0" Deaccel 10.2 0.3 -} - - -event HintMessageHide -{ - Animate HudHintDisplay FgColor "255 220 0 0" Linear 0.0 0.2 - Animate HudHintDisplay HintSize "0" Deaccel 0.2 0.3 -} - -event KeyHintMessageShow -{ - StopPanelAnimations HudHintKeyDisplay 0.0 - - // show the hints - Animate HudHintKeyDisplay Alpha 255 Linear 0.0 0.5 - - // flash text - Animate HudHintKeyDisplay FgColor "FgColor" Linear 0.0 0.01 - Animate HudHintKeyDisplay FgColor "255 220 0 255" Linear 0.5 0.2 - Animate HudHintKeyDisplay FgColor "FgColor" Linear 0.7 0.2 - Animate HudHintKeyDisplay FgColor "255 220 0 255" Linear 1.5 0.2 - Animate HudHintKeyDisplay FgColor "FgColor" Linear 1.7 0.2 - - // hide the panel after a while - Animate HudHintKeyDisplay Alpha 0 Linear 12.0 1.0 -} - -event KeyHintMessageHide -{ - Animate HudHintKeyDisplay Alpha 0 Linear 0.0 0.5 -} - - -event SquadMemberAdded -{ - StopEvent SquadMemberDied 0.0 - StopEvent SquadMemberLeft 0.0 - - // add in the squad member, brighter then normal color - Animate HudSquadStatus LastMemberColor "255 220 0 255" Linear 0.0 0.3 - Animate HudSquadStatus LastMemberColor "255 220 0 160" Linear 0.3 0.3 -} - -event SquadMemberLeft -{ - StopEvent SquadMemberDied 0.0 - StopEvent SquadMemberAdded 0.0 - - // fade out the icon - Animate HudSquadStatus LastMemberColor "255 220 0 0" Linear 0.0 0.5 -} - -event SquadMemberDied -{ - StopEvent SquadMemberAdded 0.0 - StopEvent SquadMemberLeft 0.0 - - // flash red, hold, then disappear - Animate HudSquadStatus LastMemberColor "255 0 0 255" Linear 0.0 0.5 - Animate HudSquadStatus LastMemberColor "255 0 0 0" Linear 2.0 2.0 -} - -event SquadMembersFollowing -{ - StopEvent SquadMembersStationed 0.0 - Animate HudSquadStatus SquadTextColor "255 220 0 255" Linear 0.0 0.2 - Animate HudSquadStatus SquadTextColor "255 220 0 160" Linear 0.2 0.4 -} - -event SquadMembersStationed -{ - StopEvent SquadMembersFollowing 0.0 - Animate HudSquadStatus SquadTextColor "255 220 0 160" Linear 0.5 0.5 -} - -event PoisonDamageTaken -{ - Animate HudPoisonDamageIndicator Alpha 255 Linear 0.0 1.0 - RunEvent PoisonLoop 0.0 -} - -event PoisonDamageCured -{ - StopEvent PoisonDamageTaken 0.0 - StopEvent PoisonLoop 0.0 - StopEvent PoisonPulse 0.0 - Animate HudPoisonDamageIndicator Alpha 0 Linear 0.0 1.0 -} - -event PoisonPulse -{ - Animate HudPoisonDamageIndicator TextColor "BrightFg" Linear 0.0 0.1 - Animate HudPoisonDamageIndicator TextColor "FgColor" Deaccel 0.1 0.8 - Animate HudPoisonDamageIndicator BgColor "100 0 0 80" Linear 0.0 0.1 - Animate HudPoisonDamageIndicator BgColor "BgColor" Deaccel 0.1 0.8 - - RunEvent PoisonLoop 0.8 -} - -// call to loop PoisonLoop -event PoisonLoop -{ - RunEvent PoisonPulse 0.0 -} - -// Commentary hud element -event ShowCommentary -{ - StopEvent HideCommentary 0.0 - Animate HudCommentary Alpha 255 Linear 0.0 0.5 -} - -event HideCommentary -{ - StopEvent ShowCommentary 0.0 - Animate HudCommentary Alpha 0 Linear 0.0 0.5 -} - -// Voting -event PulseOption1 -{ - Animate Option2Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate Option1Background_Selected Alpha 255 Linear 0.0 0.001 - Animate Option1Background_Selected Alpha 128 Linear 0.5 1.5 - - Animate YesLeftLabel Alpha 0 Linear 1.25 1.7 - Animate YesIcon Alpha 0 Linear 1.25 1.7 - Animate YesRightLabel Alpha 0 Linear 1.25 1.7 - - Animate NoLeftLabel Alpha 0 Linear 1.25 1.7 - Animate NoIcon Alpha 0 Linear 1.25 1.7 - Animate NoRightLabel Alpha 0 Linear 1.25 1.7 - - Animate LabelOption2 Alpha 60 Linear 1.25 1.7 - Animate LabelOption3 Alpha 60 Linear 1.25 1.7 - Animate LabelOption4 Alpha 60 Linear 1.25 1.7 - Animate LabelOption5 Alpha 60 Linear 1.25 1.7 -} - -event PulseOption2 -{ - Animate Option1Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate Option2Background_Selected Alpha 255 Linear 0.0 0.001 - Animate Option2Background_Selected Alpha 128 Linear 0.5 1.5 - - Animate YesLeftLabel Alpha 0 Linear 1.25 1.7 - Animate YesIcon Alpha 0 Linear 1.25 1.7 - Animate YesRightLabel Alpha 0 Linear 1.25 1.7 - - Animate NoLeftLabel Alpha 0 Linear 1.25 1.7 - Animate NoIcon Alpha 0 Linear 1.25 1.7 - Animate NoRightLabel Alpha 0 Linear 1.25 1.7 - - Animate LabelOption1 Alpha 60 Linear 1.25 1.7 - Animate LabelOption3 Alpha 60 Linear 1.25 1.7 - Animate LabelOption4 Alpha 60 Linear 1.25 1.7 - Animate LabelOption5 Alpha 60 Linear 1.25 1.7 -} - -event PulseOption3 -{ - Animate Option1Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option2Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate Option3Background_Selected Alpha 255 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 128 Linear 0.5 1.5 - - Animate YesLeftLabel Alpha 0 Linear 1.25 1.7 - Animate YesIcon Alpha 0 Linear 1.25 1.7 - Animate YesRightLabel Alpha 0 Linear 1.25 1.7 - - Animate NoLeftLabel Alpha 0 Linear 1.25 1.7 - Animate NoIcon Alpha 0 Linear 1.25 1.7 - Animate NoRightLabel Alpha 0 Linear 1.25 1.7 - - Animate LabelOption1 Alpha 60 Linear 1.25 1.7 - Animate LabelOption2 Alpha 60 Linear 1.25 1.7 - Animate LabelOption4 Alpha 60 Linear 1.25 1.7 - Animate LabelOption5 Alpha 60 Linear 1.25 1.7 -} - -event PulseOption4 -{ - Animate Option1Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option2Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate Option4Background_Selected Alpha 255 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 128 Linear 0.5 1.5 - - Animate YesLeftLabel Alpha 0 Linear 1.25 1.7 - Animate YesIcon Alpha 0 Linear 1.25 1.7 - Animate YesRightLabel Alpha 0 Linear 1.25 1.7 - - Animate NoLeftLabel Alpha 0 Linear 1.25 1.7 - Animate NoIcon Alpha 0 Linear 1.25 1.7 - Animate NoRightLabel Alpha 0 Linear 1.25 1.7 - - Animate LabelOption1 Alpha 60 Linear 1.25 1.7 - Animate LabelOption2 Alpha 60 Linear 1.25 1.7 - Animate LabelOption3 Alpha 60 Linear 1.25 1.7 - Animate LabelOption5 Alpha 60 Linear 1.25 1.7 -} - -event PulseOption5 -{ - Animate Option1Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option2Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate Option5Background_Selected Alpha 255 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 128 Linear 0.5 1.5 - - Animate YesLeftLabel Alpha 0 Linear 1.25 1.7 - Animate YesIcon Alpha 0 Linear 1.25 1.7 - Animate YesRightLabel Alpha 0 Linear 1.25 1.7 - - Animate NoLeftLabel Alpha 0 Linear 1.25 1.7 - Animate NoIcon Alpha 0 Linear 1.25 1.7 - Animate NoRightLabel Alpha 0 Linear 1.25 1.7 - - Animate LabelOption1 Alpha 60 Linear 1.25 1.7 - Animate LabelOption2 Alpha 60 Linear 1.25 1.7 - Animate LabelOption3 Alpha 60 Linear 1.25 1.7 - Animate LabelOption4 Alpha 60 Linear 1.25 1.7 -} - -event HideVoteBackgrounds -{ - Animate Option1Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option2Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option3Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option4Background_Selected Alpha 0 Linear 0.0 0.001 - Animate Option5Background_Selected Alpha 0 Linear 0.0 0.001 - - Animate YesLeftLabel Alpha 255 Linear 0.0 0.001 - Animate YesIcon Alpha 255 Linear 0.0 0.001 - Animate YesRightLabel Alpha 255 Linear 0.0 0.001 - - Animate NoLeftLabel Alpha 255 Linear 0.0 0.001 - Animate NoIcon Alpha 255 Linear 0.0 0.001 - Animate NoRightLabel Alpha 255 Linear 0.0 0.001 - - Animate LabelOption1 Alpha 255 Linear 0.0 0.001 - Animate LabelOption2 Alpha 255 Linear 0.0 0.001 - Animate LabelOption3 Alpha 255 Linear 0.0 0.001 - Animate LabelOption4 Alpha 255 Linear 0.0 0.001 - Animate LabelOption5 Alpha 255 Linear 0.0 0.001 -} - -//====================================================== -// -// Below is ported from or based on TF2 and HL2:DM -// -//====================================================== - -// Number menu -event MenuOpen -{ - StopEvent MenuClose 0.0 - - // fade in - Animate HudMenu Alpha "255" Linear 0.0 0.1 - Animate HudMenu SelectionAlpha "255" Linear 0.0 0.1 - Animate HudMenu FgColor "FgColor" Linear 0.0 0.1 - Animate HudMenu MenuColor "MenuColor" Linear 0.0 0.1 - Animate HudMenu MenuItemColor "MenuItemColor" Linear 0.0 0.1 - Animate HudMenu TextScan "1" Linear 0.0 0.1 - - // Undo any blur - Animate HudMenu Blur "1" Linear 0.0 0.01 -} - -// Alternate event to draw attention to menu, similar to HUD hint -event MenuOpenFlash -{ - StopEvent MenuClose 0.0 - - // fade in - Animate HudMenu Alpha "255" Linear 0.0 0.3 - Animate HudMenu SelectionAlpha "255" Linear 0.0 0.3 - Animate HudMenu FgColor "FgColor" Linear 0.0 0.3 - Animate HudMenu MenuColor "MenuColor" Linear 0.0 0.3 - Animate HudMenu MenuItemColor "MenuItemColor" Linear 0.0 0.3 - Animate HudMenu TextScan "1" Linear 0.0 0.3 - - // flash text - Animate HudMenu MenuItemColor "255 220 0 255" Linear 1.0 0.2 - Animate HudMenu MenuItemColor "MenuItemColor" Linear 1.2 0.2 - Animate HudMenu MenuItemColor "255 220 0 255" Linear 2.0 0.2 - Animate HudMenu MenuItemColor "MenuItemColor" Linear 2.2 0.2 - Animate HudMenu MenuColor "255 220 0 255" Linear 1.0 0.2 - Animate HudMenu MenuColor "MenuColor" Linear 1.2 0.2 - Animate HudMenu MenuColor "255 220 0 255" Linear 2.0 0.2 - Animate HudMenu MenuColor "MenuColor" Linear 2.2 0.2 - - // Undo any blur - Animate HudMenu Blur "1" Linear 0.0 0.01 -} - -event MenuClose -{ - // Hide it - Animate HudMenu Alpha "0" Linear 0.0 1 - Animate HudMenu SelectionAlpha "0" Linear 0.0 1 - Animate HudMenu FgColor "0 0 0 0" Linear 0.0 1 - Animate HudMenu MenuColor "0 0 0 0" Linear 0.0 1 - Animate HudMenu MenuItemColor "0 0 0 0" Linear 0.0 1 -} - -event MenuPulse -{ - Animate HudMenu Blur "7" Linear 0.0 0.1 - Animate HudMenu Blur "2" Deaccel 0.1 0.1 - Animate HudMenu Blur "7" Linear 0.2 0.1 - Animate HudMenu Blur "2" Deaccel 0.3 0.1 - Animate HudMenu Blur "7" Linear 0.4 0.1 - Animate HudMenu Blur "2" Deaccel 0.5 0.1 - Animate HudMenu Blur "1" Deaccel 0.6 0.4 -} - -// HL2:DM team -event FadeOutTeamLine -{ - // make the display visible - Animate TeamDisplay Alpha "0" Linear 0.0 0.25 -} - -event FadeInTeamLine -{ - // make the display visible - Animate TeamDisplay Alpha "255" Linear 0.0 0.5 -} - -//====================================================== -//====================================================== - diff --git a/VPKs/hl2_mapbase_content/scripts/hudanimations_manifest.txt b/VPKs/hl2_mapbase_content/scripts/hudanimations_manifest.txt new file mode 100644 index 0000000..7b90893 --- /dev/null +++ b/VPKs/hl2_mapbase_content/scripts/hudanimations_manifest.txt @@ -0,0 +1,6 @@ +hudanimations_manifest +{ + + "file" "scripts/hudanimations.txt" + "file" "scripts/hudanimations_mapbase_hl2.txt" +} \ No newline at end of file diff --git a/VPKs/hl2_mapbase_content/scripts/hudanimations_mapbase_hl2.txt b/VPKs/hl2_mapbase_content/scripts/hudanimations_mapbase_hl2.txt new file mode 100644 index 0000000..6c065f9 --- /dev/null +++ b/VPKs/hl2_mapbase_content/scripts/hudanimations_mapbase_hl2.txt @@ -0,0 +1,210 @@ +// sample animation script +// +// +// commands: +// Animate +// variables: +// FgColor +// BgColor +// Position +// Size +// Blur (hud panels only) +// TextColor (hud panels only) +// Ammo2Color (hud panels only) +// Alpha (hud weapon selection only) +// SelectionAlpha (hud weapon selection only) +// TextScan (hud weapon selection only) +// +// interpolator: +// Linear +// Accel - starts moving slow, ends fast +// Deaccel - starts moving fast, ends slow +// +// RunEvent +// starts another even running at the specified time +// +// StopEvent +// stops another event that is current running at the specified time +// +// StopAnimation +// stops all animations refering to the specified variable in the specified panel +// +// StopPanelAnimations +// stops all active animations operating on the specified panel +// +// +// Useful game console commands: +// cl_Animationinfo or +// displays all the animatable variables for the hud element +// + +event SuitAuxPowerFourItemsActive +{ + // resize the aux power to fit four items + Animate HudSuitPower Size "102 66" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Position "16 360" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Size "102 72" Linear 0.0 0.4 [$X360] + Animate HudSuitPower Position "48 338" Linear 0.0 0.4 [$X360] +} + +event SuitAuxPowerFiveItemsActive +{ + // resize the aux power to fit five items + Animate HudSuitPower Size "102 76" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Position "16 350" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Size "102 82" Linear 0.0 0.4 [$X360] + Animate HudSuitPower Position "48 328" Linear 0.0 0.4 [$X360] +} + +event SuitAuxPowerSixItemsActive +{ + // resize the aux power to fit six items + Animate HudSuitPower Size "102 86" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Position "16 340" Linear 0.0 0.4 [$WIN32] + Animate HudSuitPower Size "102 92" Linear 0.0 0.4 [$X360] + Animate HudSuitPower Position "48 318" Linear 0.0 0.4 [$X360] +} + +//------------------------------- + +// Number menu +event MenuOpen +{ + StopEvent MenuClose 0.0 + + // fade in + Animate HudMenu Alpha "255" Linear 0.0 0.1 + Animate HudMenu SelectionAlpha "255" Linear 0.0 0.1 + Animate HudMenu FgColor "FgColor" Linear 0.0 0.1 + Animate HudMenu MenuColor "MenuColor" Linear 0.0 0.1 + Animate HudMenu MenuItemColor "MenuItemColor" Linear 0.0 0.1 + Animate HudMenu TextScan "1" Linear 0.0 0.1 + + // Undo any blur + Animate HudMenu Blur "1" Linear 0.0 0.01 +} + +// Alternate event to draw attention to menu, similar to HUD hint +event MenuOpenFlash +{ + StopEvent MenuClose 0.0 + + // fade in + Animate HudMenu Alpha "255" Linear 0.0 0.3 + Animate HudMenu SelectionAlpha "255" Linear 0.0 0.3 + Animate HudMenu FgColor "FgColor" Linear 0.0 0.3 + Animate HudMenu MenuColor "MenuColor" Linear 0.0 0.3 + Animate HudMenu MenuItemColor "MenuItemColor" Linear 0.0 0.3 + Animate HudMenu TextScan "1" Linear 0.0 0.3 + + // flash text + Animate HudMenu MenuItemColor "255 220 0 255" Linear 1.0 0.2 + Animate HudMenu MenuItemColor "MenuItemColor" Linear 1.2 0.2 + Animate HudMenu MenuItemColor "255 220 0 255" Linear 2.0 0.2 + Animate HudMenu MenuItemColor "MenuItemColor" Linear 2.2 0.2 + Animate HudMenu MenuColor "255 220 0 255" Linear 1.0 0.2 + Animate HudMenu MenuColor "MenuColor" Linear 1.2 0.2 + Animate HudMenu MenuColor "255 220 0 255" Linear 2.0 0.2 + Animate HudMenu MenuColor "MenuColor" Linear 2.2 0.2 + + // Undo any blur + Animate HudMenu Blur "1" Linear 0.0 0.01 +} + +event MenuClose +{ + // Hide it + Animate HudMenu Alpha "0" Linear 0.0 1 + Animate HudMenu SelectionAlpha "0" Linear 0.0 1 + Animate HudMenu FgColor "0 0 0 0" Linear 0.0 1 + Animate HudMenu MenuColor "0 0 0 0" Linear 0.0 1 + Animate HudMenu MenuItemColor "0 0 0 0" Linear 0.0 1 +} + +event MenuPulse +{ + Animate HudMenu Blur "7" Linear 0.0 0.1 + Animate HudMenu Blur "2" Deaccel 0.1 0.1 + Animate HudMenu Blur "7" Linear 0.2 0.1 + Animate HudMenu Blur "2" Deaccel 0.3 0.1 + Animate HudMenu Blur "7" Linear 0.4 0.1 + Animate HudMenu Blur "2" Deaccel 0.5 0.1 + Animate HudMenu Blur "1" Deaccel 0.6 0.4 +} + +//------------------------------- + +event GenericGameTimerShow +{ + StopEvent GenericGameTimerClose 0.0 + + // fade in + Animate HudGenericGameTimer Alpha "255" Linear 0.0 0.1 + Animate HudGenericGameTimer FgColor "FgColor" Linear 0.0 0.1 + Animate HudGenericGameTimer TimerBoxColor "TimerBoxColor" Linear 0.0 0.1 + Animate HudGenericGameTimer TextColor "TextColor" Linear 0.0 0.1 + Animate HudGenericGameTimer NumberColor "NumberColor" Linear 0.0 0.1 + + // Undo any blur + Animate HudGenericGameTimer Blur "1" Linear 0.0 0.01 +} + +// Alternate event to draw attention to menu, similar to HUD hint +event GenericGameTimerShowFlash +{ + StopEvent GenericGameTimerClose 0.0 + + // fade in + Animate HudGenericGameTimer Alpha "255" Linear 0.0 0.3 + Animate HudGenericGameTimer FgColor "FgColor" Linear 0.0 0.3 + Animate HudGenericGameTimer TimerBoxColor "TimerBoxColor" Linear 0.0 0.3 + Animate HudGenericGameTimer TextColor "TextColor" Linear 0.0 0.3 + Animate HudGenericGameTimer NumberColor "NumberColor" Linear 0.0 0.3 + + // flash text + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 1.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 1.2 0.2 + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 2.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 2.2 0.2 + + // Undo any blur + Animate HudGenericGameTimer Blur "1" Linear 0.0 0.01 +} + +event GenericGameTimerClose +{ + // Hide it + Animate HudGenericGameTimer Alpha "0" Linear 0.0 1 + Animate HudGenericGameTimer FgColor "0 0 0 0" Linear 0.0 1 + Animate HudGenericGameTimer TimerBoxColor "0 0 0 0" Linear 0.0 1 + Animate HudGenericGameTimer TextColor "0 0 0 0" Linear 0.0 1 + Animate HudGenericGameTimer NumberColor "0 0 0 0" Linear 0.0 1 +} + +event GenericGameTimerPulse +{ + // flash text + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 0.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 0.2 0.2 + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 1.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 1.2 0.2 + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 2.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 2.2 0.2 +} + +event GenericGameTimerPulseOnce +{ + // flash text + Animate HudGenericGameTimer FgColor "255 220 0 255" Linear 0.0 0.2 + Animate HudGenericGameTimer FgColor "FgColor" Linear 0.2 0.2 +} + +event GenericGameTimerWarn +{ + Animate HudGenericGameTimer FgColor "255 64 64 255" Linear 0.0 1.0 +} + +event GenericGameTimerUnwarn +{ + Animate HudGenericGameTimer FgColor "FgColor" Linear 0.0 1.0 +} diff --git a/VPKs/hl2_mapbase_content/scripts/hudlayout.res b/VPKs/hl2_mapbase_content/scripts/hudlayout.res index 01ee6cf..b626197 100644 --- a/VPKs/hl2_mapbase_content/scripts/hudlayout.res +++ b/VPKs/hl2_mapbase_content/scripts/hudlayout.res @@ -717,6 +717,21 @@ "PaintBackgroundType" "0" // rounded corners } + //============================== + // + // Mapbase-specific + // + //============================== + HudGenericGameTimer + { + "fieldName" "HudGenericGameTimer" + "visible" "1" + "enabled" "1" + "wide" "640" + "tall" "480" + "zpos" "1" + } + //============================== // // Below is ported from HL2:DM diff --git a/VPKs/shared_content_v7_0/materials/editor/game_timer.vmt b/VPKs/shared_content_v7_0/materials/editor/game_timer.vmt new file mode 100644 index 0000000..99fe438 --- /dev/null +++ b/VPKs/shared_content_v7_0/materials/editor/game_timer.vmt @@ -0,0 +1,7 @@ +SDK_Sprite +{ + "$spriteorientation" "vp_parallel" + "$spriteorigin" "[ 0.50 0.50 ]" + "$basetexture" "editor/game_timer" + "$no_fullbright" 1 +} diff --git a/VPKs/shared_content_v7_0/materials/editor/game_timer.vtf b/VPKs/shared_content_v7_0/materials/editor/game_timer.vtf new file mode 100644 index 0000000000000000000000000000000000000000..52aa66e636d45197bb4a7e3734c52a6437a1a9c9 GIT binary patch literal 5696 zcmeHLU1%It6h0GXXtq+^Em=wQWm7kW6bimX`cTNMBq7^c*p#`&hia2p5n|IH3lb^X z$(rB~6qit>FEt1)RzXqJZ4o6xQR$2IQC(^+QIv=__N808aQ)7my|Z(Nl(uQwTFKq{ z*>BFd_uTVy&pk8Sygph%L`^sgI9>cGLuBE9(EM&9eX1w!{kW}Ig-bHoU<;UW9csn} zL#exn-JRp540TO*OimoJJ6j&!ux96}Umt0?@cAr1-@f&Ut;fcQoGu~0_A`|E0(U$w zZWMx_7q$yA`W%rs-to-E1Gvwf2=Hs`#E1KVcX(p|^ZBVPj^74n-S^QBJWKN%arEV1 z85ATa@%Gf=?#DN5dv~b4RTTfE2X>SXWou_;hFF5<0Ux#HmFWPd(}^Qj-yB{0`==wr z)cl@!-D-JRo?O*_^!qnPsCh&TKX#s!yiHo~8HL%Jf&OtE@UQ8r(;a{On>{rg+Abu6 z`D^=VtnK8Fch^qi(Driu?=IH*hAY}`{AJyFWF;A1NC^efmu(XnXjar#gusb6F&>A2l)Bhf@)7-Ye#d@Sh5oLAJ>eNREz$<&bW`6yoX(~c*B2VA@e1C6frW_d zA1u$Z4f-PFOM>!Cq<;Y|Iv)!yie0oQb{wZSid{EnV9*^+U&uabG)-rFEkeGtwEDZ@ z{?GHVEYI+l>!uCtIC#AX>j%49lRww@|ow`Aez48}q*x^M5+# ze=FvHiur#a;(xX$UbYPT*fIYvLjDr_9}bB46Y3lOgZf6iLOsKOIV_K8f6&eKkNg^? zLw#fY!~8cbf2sVx(E3F7GxS0B3vrx3j@jQH%Im1Uh<*cO^@Mn#{x>3jQTm(pIC06y zQ{nuL!uTG;NdA%eUvK|grr+86l>xIdwPB1sm1>X6cP8~KfKl2S=?yxtUWu`wT)ag(hc@OYMzpP{A< z_s5sGTYlf;N#b1-r2VEy5B)hGDHiZsg!E5% zDOHX2Z+u_i@si0@eLRASQl?UkdV=vlDrbz}>#}_F`^v4xk7Vbl{2`@E*W?!ePx<6u D`*^X- literal 0 HcmV?d00001