Add missing respawn method (#1095)

This commit is contained in:
IzzelAliz 2023-09-17 09:14:05 +08:00
parent 2606ff93b7
commit 97bc12d44f

View File

@ -253,6 +253,10 @@ public abstract class PlayerListMixin implements PlayerListBridge {
return entity;
}
public ServerPlayer respawn(ServerPlayer entityplayer, boolean flag, PlayerRespawnEvent.RespawnReason reason) {
return this.respawn(entityplayer, this.server.getLevel(entityplayer.getRespawnDimension()), flag, null, true, reason);
}
public ServerPlayer respawn(ServerPlayer playerIn, ServerLevel worldIn, boolean flag, Location location, boolean avoidSuffocation, PlayerRespawnEvent.RespawnReason respawnReason) {
playerIn.stopRiding();
this.players.remove(playerIn);