Fixed teleport crash

This commit is contained in:
Shoghi Cervantes Pueyo 2012-12-17 16:40:44 +01:00
parent d573f8f6da
commit ab3862446c
3 changed files with 8 additions and 7 deletions

3
TODO
View File

@ -1,3 +1,4 @@
- Save placed blocks and relay them to other players.
- Fix spawn position resetting to 0,128,0
- Mob spawning, item pick up
- Mob spawning, item pick up
- Fix metadata orientation

View File

@ -96,11 +96,11 @@ class PlayerAPI{
public function tppos($name, $x, $y, $z){
$player = $this->get($name);
if($player !== false){
$this->player->dataPacket(MC_MOVE_PLAYER, array(
"eid" => $player->eid,
"x" => $player->x,
"y" => $player->y,
"z" => $player->z,
$player->dataPacket(MC_MOVE_PLAYER, array(
"eid" => 0,
"x" => $x,
"y" => $y,
"z" => $z,
"yaw" => 0,
"pitch" => 0,
));

View File

@ -276,7 +276,7 @@ class Session{
"z" => $this->data["spawn"]["z"],
"unknown1" => 0,
"gamemode" => $this->server->gamemode,
"eid" => $this->eid,
"eid" => 0,
));
break;
case MC_READY: