QtCraft API C++ classes QML types Handbook

QcMobExchange::CreatureHit Struct

struct QcMobExchange::CreatureHit

A blow of one creature at another (a golem at a hostile creature, decision E-471; a pet at its owner's foe, decision E-480); the server deals it after the tick (QcServerCreatures). More...

Header: #include <server/mobs/QcMobExchange.h>

Public Variables

quint32 attacker
double damage
QcVec3 from
double lift
quint32 target

Detailed Description

Member Variable Documentation

quint32 CreatureHit::attacker

Entity id of the creature that strikes.

double CreatureHit::damage

The damage of the blow.

QcVec3 CreatureHit::from

Where the blow comes from (the push goes away from it).

double CreatureHit::lift

Times a blow's usual lift (PlayerHit::lift).

quint32 CreatureHit::target

Entity id of the creature struck.