mirror of
https://github.com/danbulant/flying-squid
synced 2026-06-14 03:51:07 +00:00
fix 2 bugs in login : send the update health packet + send named_entity_spawn as fixed point
This commit is contained in:
parent
37db96d8a1
commit
c26b11bb74
2 changed files with 4 additions and 4 deletions
|
|
@ -207,9 +207,9 @@ function inject(serv,player)
|
|||
player._writeOthers('named_entity_spawn',{
|
||||
entityId: player.entity.id,
|
||||
playerUUID: player._client.uuid,
|
||||
x: player.entity.position.x/32,
|
||||
y: player.entity.position.y/32,
|
||||
z: player.entity.position.z/32,
|
||||
x: player.entity.position.x,
|
||||
y: player.entity.position.y,
|
||||
z: player.entity.position.z,
|
||||
yaw: player.entity.yaw,
|
||||
pitch: player.entity.pitch,
|
||||
currentItem: 0,
|
||||
|
|
@ -240,6 +240,7 @@ function inject(serv,player)
|
|||
await sendMap();
|
||||
sendSpawnPosition();
|
||||
sendInitialPosition();
|
||||
player.updateHealth(player.entity.health);
|
||||
|
||||
player.emit("spawned");
|
||||
|
||||
|
|
|
|||
|
|
@ -183,7 +183,6 @@ function inject(serv,settings)
|
|||
});
|
||||
|
||||
player.on('modpe', function (command) {
|
||||
console.log(command);
|
||||
try {
|
||||
procCmd(command);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue