|
group2 0.1.0
CSE 125 Group 2
|
Snapshot of game state consumed by the HUD each frame. More...
#include <HudTypes.hpp>
Public Attributes | |
| const InputBindings * | bindings = nullptr |
| Live input bindings for HUD key prompts. | |
| BindingDevice | activeInputDevice {} |
| Last-used input device; selects KBM vs controller glyphs (0 == KBM). | |
| int | health = 100 |
| int | maxHealth = 100 |
| int | armor = 0 |
| int | maxArmor = 100 |
| int | overShield = 0 |
| int | maxOverShield = 200 |
| float | abilityLevelProgress = 0.f |
| accumDamage / systems::dmgThreshold, clamped 0..1. | |
| int | abilityLevel = 0 |
| int | ammoClip = 30 |
| int | ammoReserve = 90 |
| int | weaponId = 0 |
| int | primaryWeaponId = 0 |
| WeaponType ordinal in the primary slot. | |
| int | secondarySlotWeaponId = 2 |
| WeaponType ordinal in the secondary slot. | |
| int | activeWeaponSlot = 0 |
| 0 = primary, 1 = secondary. | |
| bool | railgunScoped = false |
| True while the local player holds right click with the railgun equipped. | |
| float | railgunChargeTime = 0.f |
| Current GunInstance::chargeTime for the equipped railgun. | |
| float | roundTimeRemaining = 0.f |
| bool | isAlive = true |
| MatchPhase | currentPhase = MatchPhase::IN_PROGRESS |
| Current server match phase. | |
| bool | matchWon = false |
| True if the local player won the finished match. | |
| bool | forceScoreboardOpen = false |
| True when match flow should show scoreboard automatically. | |
| bool | isReloading = false |
| float | reloadProgress = 0.0f |
| 0-1 | |
| std::span< const HudKillFeedEntry > | killFeedEvents |
| std::span< const HudDamageEvent > | damageEvents |
| std::span< const HudHitConfirm > | hitConfirms |
| std::span< const HudDamageNumber > | damageNumbers |
| Floating damage numbers to spawn this frame. | |
| HudDamageAccum | damageAccum |
| Running damage total to current target. | |
| HudShotgunBlast | latestShotgunBlast |
| Most recent shotgun blast; valid=false when none. | |
| glm::mat4 | viewProj {1.f} |
| std::span< const HudTeamMemberStatus > | allies |
| std::span< const HudTeamMemberStatus > | enemies |
| int | allyScore = 0 |
| int | enemyScore = 0 |
| float | localPlayerX = 0.f |
| float | localPlayerZ = 0.f |
| float | localPlayerYaw = 0.f |
| Player facing direction (radians, 0 = +Z, CW). | |
| std::span< const HudMinimapDot > | enemyDots |
| float | minimapWorldRange = 4000.f |
| World units visible in each direction from center. | |
| bool | tookDamage = false |
| True the frame health or armor decreased. | |
| float | damageIntensity = 0.f |
| 0..1 fraction of max-health lost this frame. | |
| bool | armorBroke = false |
| True the frame armor dropped to zero. | |
| bool | pickupAvailable = false |
| True when a pickup is currently actionable. | |
| int | pickupWeaponId = 0 |
| Mirrors WeaponType: 0=Rifle, 1=Rocket, 2=RailGun, 3=EnergyGun. | |
| std::span< const HudWorldEnemy > | worldEnemies |
| Enemies whose HP bars float above them in-world. | |
| HudEquipmentState | equipment |
| Grapple / grenade / tactical state. | |
| HudGrenadeRadialState | grenadeRadial |
| Held-G grenade selection radial. | |
| HudEmoteWheelState | emoteWheel |
| Held-B emote selection wheel. | |
| HudKillerBox | killerBox |
| Killcam: red box framing the killer while dead. | |
| HudAbilitySelectionState | abilitySelection |
| Pending level-up ability choice. | |
| std::span< const HudPickupNotification > | pickupNotifications |
| Slide-in pickup messages this frame. | |
| std::span< const HudPopupMessage > | popupMessages |
| Generic popup messages this frame. | |
| HudKdaCounter | kda |
| Local player kill/assist/death counter (top-right). | |
| HudChatState | chat |
| Bottom-left all-chat log/input. | |
| std::span< const HudVoiceSpeaker > | voiceSpeakers |
| Currently audible proximity voice speakers. | |
| HudMatchInfo | matchInfo |
| Match elapsed time + frag target (top-center header). | |
| int | gravityDirection = 0 |
| 0=down, 1=left, 2=up, 3=right (HUD compass arrow). | |
| int | secondaryWeaponId = -1 |
| -1 = no inactive weapon loaded. | |
| int | secondaryClip = 0 |
| Mag count of the inactive weapon. | |
| int | secondaryReserve = 0 |
| Reserve count of the inactive weapon. | |
| int | secondaryKeybind = 2 |
| 1 or 2 — the keybind that swaps to this slot. | |
| int | magCapacity = 0 |
| Max rounds per mag for the current weapon. | |
| int | secondaryMagCapacity = 0 |
| Max rounds per mag for the secondary weapon (when set). | |
| float | screenW = 1280.f |
| float | screenH = 720.f |
Snapshot of game state consumed by the HUD each frame.
Filled by Game from ECS data. The HUD never imports ECS headers.
| int HudGameState::abilityLevel = 0 |
| float HudGameState::abilityLevelProgress = 0.f |
accumDamage / systems::dmgThreshold, clamped 0..1.
| HudAbilitySelectionState HudGameState::abilitySelection |
Pending level-up ability choice.
| BindingDevice HudGameState::activeInputDevice {} |
Last-used input device; selects KBM vs controller glyphs (0 == KBM).
| int HudGameState::activeWeaponSlot = 0 |
0 = primary, 1 = secondary.
| std::span<const HudTeamMemberStatus> HudGameState::allies |
| int HudGameState::allyScore = 0 |
| int HudGameState::ammoClip = 30 |
| int HudGameState::ammoReserve = 90 |
| int HudGameState::armor = 0 |
| bool HudGameState::armorBroke = false |
True the frame armor dropped to zero.
| const InputBindings* HudGameState::bindings = nullptr |
Live input bindings for HUD key prompts.
| HudChatState HudGameState::chat |
Bottom-left all-chat log/input.
| MatchPhase HudGameState::currentPhase = MatchPhase::IN_PROGRESS |
Current server match phase.
| HudDamageAccum HudGameState::damageAccum |
Running damage total to current target.
| std::span<const HudDamageEvent> HudGameState::damageEvents |
| float HudGameState::damageIntensity = 0.f |
0..1 fraction of max-health lost this frame.
| std::span<const HudDamageNumber> HudGameState::damageNumbers |
Floating damage numbers to spawn this frame.
| HudEmoteWheelState HudGameState::emoteWheel |
Held-B emote selection wheel.
| std::span<const HudTeamMemberStatus> HudGameState::enemies |
| std::span<const HudMinimapDot> HudGameState::enemyDots |
| int HudGameState::enemyScore = 0 |
| HudEquipmentState HudGameState::equipment |
Grapple / grenade / tactical state.
| bool HudGameState::forceScoreboardOpen = false |
True when match flow should show scoreboard automatically.
| int HudGameState::gravityDirection = 0 |
0=down, 1=left, 2=up, 3=right (HUD compass arrow).
| HudGrenadeRadialState HudGameState::grenadeRadial |
Held-G grenade selection radial.
| int HudGameState::health = 100 |
| std::span<const HudHitConfirm> HudGameState::hitConfirms |
| bool HudGameState::isAlive = true |
| bool HudGameState::isReloading = false |
| HudKdaCounter HudGameState::kda |
Local player kill/assist/death counter (top-right).
| HudKillerBox HudGameState::killerBox |
Killcam: red box framing the killer while dead.
| std::span<const HudKillFeedEntry> HudGameState::killFeedEvents |
| HudShotgunBlast HudGameState::latestShotgunBlast |
Most recent shotgun blast; valid=false when none.
| float HudGameState::localPlayerX = 0.f |
| float HudGameState::localPlayerYaw = 0.f |
Player facing direction (radians, 0 = +Z, CW).
| float HudGameState::localPlayerZ = 0.f |
| int HudGameState::magCapacity = 0 |
Max rounds per mag for the current weapon.
| HudMatchInfo HudGameState::matchInfo |
Match elapsed time + frag target (top-center header).
| bool HudGameState::matchWon = false |
True if the local player won the finished match.
| int HudGameState::maxArmor = 100 |
| int HudGameState::maxHealth = 100 |
| int HudGameState::maxOverShield = 200 |
| float HudGameState::minimapWorldRange = 4000.f |
World units visible in each direction from center.
| int HudGameState::overShield = 0 |
| bool HudGameState::pickupAvailable = false |
True when a pickup is currently actionable.
| std::span<const HudPickupNotification> HudGameState::pickupNotifications |
Slide-in pickup messages this frame.
| int HudGameState::pickupWeaponId = 0 |
Mirrors WeaponType: 0=Rifle, 1=Rocket, 2=RailGun, 3=EnergyGun.
| std::span<const HudPopupMessage> HudGameState::popupMessages |
Generic popup messages this frame.
| int HudGameState::primaryWeaponId = 0 |
WeaponType ordinal in the primary slot.
| float HudGameState::railgunChargeTime = 0.f |
Current GunInstance::chargeTime for the equipped railgun.
| bool HudGameState::railgunScoped = false |
True while the local player holds right click with the railgun equipped.
| float HudGameState::reloadProgress = 0.0f |
0-1
| float HudGameState::roundTimeRemaining = 0.f |
| float HudGameState::screenH = 720.f |
| float HudGameState::screenW = 1280.f |
| int HudGameState::secondaryClip = 0 |
Mag count of the inactive weapon.
| int HudGameState::secondaryKeybind = 2 |
1 or 2 — the keybind that swaps to this slot.
| int HudGameState::secondaryMagCapacity = 0 |
Max rounds per mag for the secondary weapon (when set).
| int HudGameState::secondaryReserve = 0 |
Reserve count of the inactive weapon.
| int HudGameState::secondarySlotWeaponId = 2 |
WeaponType ordinal in the secondary slot.
| int HudGameState::secondaryWeaponId = -1 |
-1 = no inactive weapon loaded.
| bool HudGameState::tookDamage = false |
True the frame health or armor decreased.
| glm::mat4 HudGameState::viewProj {1.f} |
| std::span<const HudVoiceSpeaker> HudGameState::voiceSpeakers |
Currently audible proximity voice speakers.
| int HudGameState::weaponId = 0 |
| std::span<const HudWorldEnemy> HudGameState::worldEnemies |
Enemies whose HP bars float above them in-world.