Search in sources :

Example 11 with PacketPlayOutRespawn

use of net.minecraft.server.v1_13_R1.PacketPlayOutRespawn in project TheAPI by TheDevTec.

the class v1_13_R2 method packetRespawn.

@Override
public Object packetRespawn(Player player) {
    EntityPlayer entityPlayer = (EntityPlayer) getPlayer(player);
    WorldServer worldserver = entityPlayer.getWorldServer();
    return new PacketPlayOutRespawn(worldserver.dimension, worldserver.getDifficulty(), worldserver.getWorldData().getType(), entityPlayer.playerInteractManager.getGameMode());
}
Also used : EntityPlayer(net.minecraft.server.v1_13_R2.EntityPlayer) WorldServer(net.minecraft.server.v1_13_R2.WorldServer) PacketPlayOutRespawn(net.minecraft.server.v1_13_R2.PacketPlayOutRespawn)

Example 12 with PacketPlayOutRespawn

use of net.minecraft.server.v1_13_R1.PacketPlayOutRespawn in project TheAPI by TheDevTec.

the class v1_12_R1 method packetRespawn.

@Override
public Object packetRespawn(Player player) {
    EntityPlayer entityPlayer = (EntityPlayer) getPlayer(player);
    WorldServer worldserver = entityPlayer.x();
    byte actualDimension = (byte) worldserver.getWorld().getEnvironment().getId();
    return new PacketPlayOutRespawn((byte) ((actualDimension >= 0) ? -1 : 0), worldserver.getDifficulty(), worldserver.getWorldData().getType(), entityPlayer.playerInteractManager.getGameMode());
}
Also used : EntityPlayer(net.minecraft.server.v1_12_R1.EntityPlayer) WorldServer(net.minecraft.server.v1_12_R1.WorldServer) PacketPlayOutRespawn(net.minecraft.server.v1_12_R1.PacketPlayOutRespawn)

Example 13 with PacketPlayOutRespawn

use of net.minecraft.server.v1_13_R1.PacketPlayOutRespawn in project TheAPI by TheDevTec.

the class v1_14_R1 method packetRespawn.

@Override
public Object packetRespawn(Player player) {
    EntityPlayer entityPlayer = (EntityPlayer) getPlayer(player);
    WorldServer worldserver = entityPlayer.getWorldServer();
    return new PacketPlayOutRespawn(worldserver.worldProvider.getDimensionManager(), entityPlayer.world.getWorldData().getType(), entityPlayer.playerInteractManager.getGameMode());
}
Also used : EntityPlayer(net.minecraft.server.v1_14_R1.EntityPlayer) WorldServer(net.minecraft.server.v1_14_R1.WorldServer) PacketPlayOutRespawn(net.minecraft.server.v1_14_R1.PacketPlayOutRespawn)

Example 14 with PacketPlayOutRespawn

use of net.minecraft.server.v1_13_R1.PacketPlayOutRespawn in project TheAPI by TheDevTec.

the class v1_8_R3 method packetRespawn.

@Override
public Object packetRespawn(Player player) {
    EntityPlayer entityPlayer = (EntityPlayer) getPlayer(player);
    WorldServer worldserver = entityPlayer.u();
    byte actualDimension = (byte) worldserver.getWorld().getEnvironment().getId();
    return new PacketPlayOutRespawn((byte) ((actualDimension >= 0) ? -1 : 0), worldserver.getDifficulty(), worldserver.getWorldData().getType(), entityPlayer.playerInteractManager.getGameMode());
}
Also used : EntityPlayer(net.minecraft.server.v1_8_R3.EntityPlayer) WorldServer(net.minecraft.server.v1_8_R3.WorldServer) PacketPlayOutRespawn(net.minecraft.server.v1_8_R3.PacketPlayOutRespawn)

Example 15 with PacketPlayOutRespawn

use of net.minecraft.server.v1_13_R1.PacketPlayOutRespawn in project TheAPI by TheDevTec.

the class v1_9_R1 method packetRespawn.

@Override
public Object packetRespawn(Player player) {
    EntityPlayer entityPlayer = (EntityPlayer) getPlayer(player);
    WorldServer worldserver = entityPlayer.x();
    byte actualDimension = (byte) worldserver.getWorld().getEnvironment().getId();
    return new PacketPlayOutRespawn((byte) ((actualDimension >= 0) ? -1 : 0), worldserver.getDifficulty(), worldserver.getWorldData().getType(), entityPlayer.playerInteractManager.getGameMode());
}
Also used : EntityPlayer(net.minecraft.server.v1_9_R1.EntityPlayer) WorldServer(net.minecraft.server.v1_9_R1.WorldServer) PacketPlayOutRespawn(net.minecraft.server.v1_9_R1.PacketPlayOutRespawn)

Aggregations

UUID (java.util.UUID)4 Player (org.bukkit.entity.Player)4 BukkitRunnable (org.bukkit.scheduler.BukkitRunnable)4 EntityPlayer (net.minecraft.server.v1_10_R1.EntityPlayer)2 PacketPlayOutRespawn (net.minecraft.server.v1_10_R1.PacketPlayOutRespawn)2 EntityPlayer (net.minecraft.server.v1_11_R1.EntityPlayer)2 PacketPlayOutRespawn (net.minecraft.server.v1_11_R1.PacketPlayOutRespawn)2 EntityPlayer (net.minecraft.server.v1_8_R3.EntityPlayer)2 PacketPlayOutRespawn (net.minecraft.server.v1_8_R3.PacketPlayOutRespawn)2 PacketPlayOutEntityDestroy (net.minecraft.server.v1_10_R1.PacketPlayOutEntityDestroy)1 PacketPlayOutNamedEntitySpawn (net.minecraft.server.v1_10_R1.PacketPlayOutNamedEntitySpawn)1 PacketPlayOutPlayerInfo (net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo)1 WorldServer (net.minecraft.server.v1_10_R1.WorldServer)1 PacketPlayOutEntityDestroy (net.minecraft.server.v1_11_R1.PacketPlayOutEntityDestroy)1 PacketPlayOutNamedEntitySpawn (net.minecraft.server.v1_11_R1.PacketPlayOutNamedEntitySpawn)1 PacketPlayOutPlayerInfo (net.minecraft.server.v1_11_R1.PacketPlayOutPlayerInfo)1 WorldServer (net.minecraft.server.v1_11_R1.WorldServer)1 EntityPlayer (net.minecraft.server.v1_12_R1.EntityPlayer)1 PacketPlayOutRespawn (net.minecraft.server.v1_12_R1.PacketPlayOutRespawn)1 WorldServer (net.minecraft.server.v1_12_R1.WorldServer)1