2022-10-09 05:13:17 +00:00
|
|
|
#ifndef _CHEALTHINFO
|
|
|
|
#define _CHEALTHINFO
|
2022-09-18 05:55:13 +00:00
|
|
|
|
|
|
|
#include "types.h"
|
|
|
|
|
2022-10-13 22:37:09 +00:00
|
|
|
class CInputStream;
|
2022-09-18 05:55:13 +00:00
|
|
|
class CHealthInfo {
|
|
|
|
public:
|
2022-10-09 05:37:23 +00:00
|
|
|
CHealthInfo(float hp, float resist) : x0_health(hp), x4_knockbackResistance(resist) {}
|
2022-10-13 22:37:09 +00:00
|
|
|
explicit CHealthInfo(CInputStream&);
|
|
|
|
|
2022-10-01 14:08:15 +00:00
|
|
|
void SetHP(float hp) { x0_health = hp; }
|
2022-10-04 13:29:05 +00:00
|
|
|
void SetKnockbackResistance(float resist) { x4_knockbackResistance = resist; }
|
2022-10-01 14:08:15 +00:00
|
|
|
float GetHP() const { return x0_health; }
|
2022-09-18 05:55:13 +00:00
|
|
|
|
|
|
|
private:
|
2022-10-09 05:37:23 +00:00
|
|
|
float x0_health;
|
|
|
|
float x4_knockbackResistance;
|
2022-09-18 05:55:13 +00:00
|
|
|
};
|
|
|
|
CHECK_SIZEOF(CHealthInfo, 0x8)
|
|
|
|
|
2022-10-09 05:13:17 +00:00
|
|
|
#endif // _CHEALTHINFO
|