Fixed backwards compatibility issue on PlayerInteractyEvent

This commit is contained in:
Shoghi Cervantes 2015-04-10 10:16:03 +02:00
parent a7b1c6e086
commit 5d102c2ede
2 changed files with 3 additions and 3 deletions

View File

@ -1155,9 +1155,9 @@ class Player extends Human implements CommandSender, InventoryHolder, IPlayer{
$pk->x = $from->x; $pk->x = $from->x;
$pk->y = $from->y + $this->getEyeHeight(); $pk->y = $from->y + $this->getEyeHeight();
$pk->z = $from->z; $pk->z = $from->z;
$pk->yaw = $from->yaw;
$pk->bodyYaw = $from->yaw; $pk->bodyYaw = $from->yaw;
$pk->pitch = $from->pitch; $pk->pitch = $from->pitch;
$pk->yaw = $from->yaw;
$pk->mode = 1; $pk->mode = 1;
$this->directDataPacket($pk); $this->directDataPacket($pk);
$this->forceMovement = new Vector3($from->x, $from->y, $from->z); $this->forceMovement = new Vector3($from->x, $from->y, $from->z);

View File

@ -61,7 +61,7 @@ class PlayerInteractEvent extends PlayerEvent implements Cancellable{
$this->touchVector = new Vector3(0, 0, 0); $this->touchVector = new Vector3(0, 0, 0);
}else{ }else{
$this->touchVector = $block; $this->touchVector = $block;
Block::get(0, 0, new Position(0, 0, 0, $player->level)); $this->blockTouched = Block::get(0, 0, new Position(0, 0, 0, $player->level));
} }
$this->player = $player; $this->player = $player;
$this->item = $item; $this->item = $item;