updated playerhitstructure
This commit is contained in:
parent
13f38d2576
commit
f47e36d001
@ -21,7 +21,11 @@ class PlayerHitStructure {
|
||||
private $damage;
|
||||
private $shooterPoints;
|
||||
private $weapon;
|
||||
private $hitDistance = 0;
|
||||
private $hitDistance;
|
||||
private $shooterPosition = 0;
|
||||
private $victimPosition = 0;
|
||||
private $shooterAimDirection = 0;
|
||||
private $victimAimDirection = 0;
|
||||
|
||||
/** @var ManiaControl $maniaControl */
|
||||
private $maniaControl;
|
||||
@ -39,10 +43,23 @@ class PlayerHitStructure {
|
||||
$this->damage = $data[2];
|
||||
$this->weapon = $data[3];
|
||||
$this->shooterPoints = $data[4];
|
||||
$this->hitDistance = $data[5];
|
||||
|
||||
//TODO remove key check in some months (hitDistance got implemented 2014-10-16)
|
||||
if (array_key_exists(5, $data)) {
|
||||
$this->hitDistance = $data[5];
|
||||
//TODO remove key check in some months (got implemented 2015-05-03)
|
||||
if (array_key_exists(6, $data)) {
|
||||
$this->shooterPosition = $data[6];
|
||||
}
|
||||
|
||||
if (array_key_exists(7, $data)) {
|
||||
$this->victimPosition = $data[7];
|
||||
}
|
||||
|
||||
if (array_key_exists(8, $data)) {
|
||||
$this->shooterAimDirection = $data[8];
|
||||
}
|
||||
|
||||
if (array_key_exists(9, $data)) {
|
||||
$this->victimAimDirection = $data[9];
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user