group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
GrenadeConfig Struct Reference

All tuning for one grenade type. More...

#include <GrenadeConfig.hpp>

Public Attributes

float throwSpeed = 1500.0f
 Initial speed along throw direction (u/s).
float throwPitchOffset = 0.35f
 Upward rotation applied to eye dir (rad, ~20°).
float throwCooldown = 0.4f
 Min seconds between throws.
float fuseTime = -1.0f
 Seconds; <0 means impact-detonate (no fuse).
float bounceRestitution = 0.0f
 0 = no bounce, 0.5 = lossy, 1.0 = elastic.
bool sticky = false
 If true, freezes velocity on first surface hit.
float maxLifeTime = 8.0f
 Hard timeout safety (s).
GrenadeDetonationKind detonation = GrenadeDetonationKind::Explosion
float damage = 0.0f
float explosionRadius = 0.0f
float damageFalloffExp = 1.0f
float selfDamageMult = 0.4f
float maxKnockback = 0.0f
float knockbackFalloffExp = 1.0f
float fireRadius = 0.0f
float fireDuration = 0.0f
float fireDps = 0.0f
int modelId = 1
 Reuses rocket model for v1.
glm::vec3 tint = {1.0f, 1.0f, 1.0f}
 RGB multiplier for projectile rendering.

Detailed Description

All tuning for one grenade type.

Member Data Documentation

◆ bounceRestitution

float GrenadeConfig::bounceRestitution = 0.0f

0 = no bounce, 0.5 = lossy, 1.0 = elastic.

◆ damage

float GrenadeConfig::damage = 0.0f

◆ damageFalloffExp

float GrenadeConfig::damageFalloffExp = 1.0f

◆ detonation

◆ explosionRadius

float GrenadeConfig::explosionRadius = 0.0f

◆ fireDps

float GrenadeConfig::fireDps = 0.0f

◆ fireDuration

float GrenadeConfig::fireDuration = 0.0f

◆ fireRadius

float GrenadeConfig::fireRadius = 0.0f

◆ fuseTime

float GrenadeConfig::fuseTime = -1.0f

Seconds; <0 means impact-detonate (no fuse).

◆ knockbackFalloffExp

float GrenadeConfig::knockbackFalloffExp = 1.0f

◆ maxKnockback

float GrenadeConfig::maxKnockback = 0.0f

◆ maxLifeTime

float GrenadeConfig::maxLifeTime = 8.0f

Hard timeout safety (s).

◆ modelId

int GrenadeConfig::modelId = 1

Reuses rocket model for v1.

◆ selfDamageMult

float GrenadeConfig::selfDamageMult = 0.4f

◆ sticky

bool GrenadeConfig::sticky = false

If true, freezes velocity on first surface hit.

◆ throwCooldown

float GrenadeConfig::throwCooldown = 0.4f

Min seconds between throws.

◆ throwPitchOffset

float GrenadeConfig::throwPitchOffset = 0.35f

Upward rotation applied to eye dir (rad, ~20°).

◆ throwSpeed

float GrenadeConfig::throwSpeed = 1500.0f

Initial speed along throw direction (u/s).

◆ tint

glm::vec3 GrenadeConfig::tint = {1.0f, 1.0f, 1.0f}

RGB multiplier for projectile rendering.


The documentation for this struct was generated from the following file: