public static void LoginRequest(MinecraftClient client, IPacket _packet) { var packet = (LoginRequestPacket)_packet; client.EntityId = packet.EntityId; client.Spawned = true; client.OnLoggedIn(); // Initialize world client.World = new ReadOnlyWorld(); client.LevelInformation = new LevelInformation(packet); client.OnWorldInitialized(); }
public static void LoginRequest(MinecraftClient client, IPacket _packet) { var packet = (LoginRequestPacket)_packet; client.EntityId = packet.EntityId; client.Spawned = true; client.OnLoggedIn(); // Initialize world client.Level = new Level(); client.Level.Difficulty = packet.Difficulty; client.Level.GameMode = packet.GameMode; client.Level.World.LevelType = packet.LevelType; client.OnWorldInitialized(); }
public static void LoginRequest(MinecraftClient client, IPacket _packet) { var packet = (LoginRequestPacket)_packet; client.EntityId = packet.EntityId; client.IsLoggedIn = true; client.OnLoggedIn(); LogProvider.Log("Logged in."); // Initialize world client.World = new ReadOnlyWorld(); client.LevelInformation = new LevelInformation(packet); client.OnWorldInitialized(); }