Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
DamageInfoOutput Class Reference

#include <Damage.h>

Inherits Snapshot.

Public Member Functions

 DamageInfoOutput (void)
 
- Public Member Functions inherited from Snapshot
 Snapshot (void)
 
 ~Snapshot (void)
 

Public Attributes

Real m_actualDamageDealt
 
Real m_actualDamageClipped
 (see comment for m_actualDamageDealt)
 
Bool m_noEffect
 if true, no damage was done at all (generally due to being InactiveBody)
 

Protected Member Functions

virtual void crc (Xfer *xfer)
 run the "light" crc check on this data structure
 
virtual void xfer (Xfer *xfer)
 
virtual void loadPostProcess (void)
 

Detailed Description

Damage into outputs

Definition at line 311 of file Damage.h.

Constructor & Destructor Documentation

◆ DamageInfoOutput()

DamageInfoOutput::DamageInfoOutput ( void )
inline

Definition at line 316 of file Damage.h.

Member Function Documentation

◆ crc()

virtual void DamageInfoOutput::crc ( Xfer * xfer)
inlineprotectedvirtual

run the "light" crc check on this data structure

Implements Snapshot.

Definition at line 343 of file Damage.h.

◆ loadPostProcess()

virtual void DamageInfoOutput::loadPostProcess ( void )
inlineprotectedvirtual

post process phase for loading save games. All save systems have their xfer run using XferLoad mode, and then all systems each have their post process run

Implements Snapshot.

Definition at line 345 of file Damage.h.

◆ xfer()

void DamageInfoOutput::xfer ( Xfer * xfer)
protectedvirtual

Xfer method Version Info: 1: Initial version

Implements Snapshot.

Definition at line 179 of file Damage.cpp.

Member Data Documentation

◆ m_actualDamageClipped

Real DamageInfoOutput::m_actualDamageClipped

(see comment for m_actualDamageDealt)

Definition at line 337 of file Damage.h.

◆ m_actualDamageDealt

Real DamageInfoOutput::m_actualDamageDealt

m_actualDamageDealt is the damage we tried to apply to object (after multipliers and such). m_actualDamageClipped is the value of m_actualDamageDealt, but clipped to the max health remaining of the obj. example: a mammoth tank fires a round at a small tank, attempting 100 damage. the small tank has a damage multiplier of 50%, meaning that only 50 damage is applied. furthermore, the small tank has only 30 health remaining. so: m_actualDamageDealt = 50, m_actualDamageClipped = 30.

this distinction is useful, since visual fx really wants to do the fx for "50 damage", even though it was more than necessary to kill this object; game logic, on the other hand, may want to know the "clipped" damage for ai purposes.

Definition at line 336 of file Damage.h.

◆ m_noEffect

Bool DamageInfoOutput::m_noEffect

if true, no damage was done at all (generally due to being InactiveBody)

Definition at line 338 of file Damage.h.


The documentation for this class was generated from the following files: