Wrath of Zeus
Made by Torchlight Games for CSE 125 SP24
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
Projectile::Options Struct Reference

Struct for options to configure the projectile. More...

#include <projectile.hpp>

Public Member Functions

 Options (bool isSpell, int damage, float h_mult, float v_mult, bool homing, float homing_strength, int homing_duration, std::optional< EntityID > target)
 

Data Fields

bool isSpell
 
float h_mult
 
float v_mult
 
int damage
 
bool homing
 
float homing_strength
 
int homing_duration
 
std::optional< EntityIDtarget
 

Detailed Description

Struct for options to configure the projectile.

Constructor & Destructor Documentation

◆ Options()

Projectile::Options::Options ( bool  isSpell,
int  damage,
float  h_mult,
float  v_mult,
bool  homing,
float  homing_strength,
int  homing_duration,
std::optional< EntityID target 
)
inline
Parameters
damageDamage when the projectile collides with a creature
h_multhorizontal velocity multiplier
v_multvertical velocity multiplier
homingwhether or not the projectile homes in on a specified target
homing_strengthvalue from 0-1, where the closer to 1 the more strong the homing is
homing_durationhow many ticks it should home for
targetTarget towards which the projectile homes, if it is homing

Field Documentation

◆ damage

int Projectile::Options::damage

◆ h_mult

float Projectile::Options::h_mult

◆ homing

bool Projectile::Options::homing

◆ homing_duration

int Projectile::Options::homing_duration

◆ homing_strength

float Projectile::Options::homing_strength

◆ isSpell

bool Projectile::Options::isSpell

◆ target

std::optional<EntityID> Projectile::Options::target

◆ v_mult

float Projectile::Options::v_mult

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