<commit_before>--- ../src-base/minecraft/net/minecraft/client/renderer/RenderGlobal.java
+++ ../src-work/minecraft/net/minecraft/client/renderer/RenderGlobal.java
@@ -547,8 +547,10 @@
 
     public void func_180446_a(Entity p_180446_1_, ICamera p_180446_2_, float p_180446_3_)
     {
+        int pass = net.minecraftforge.client.MinecraftForgeClient.getRenderPass();
         if (this.field_72740_G > 0)
         {
+            if (pass > 0) return;
             --this.field_72740_G;
         }
         else
@@ -559,9 +561,12 @@
             this.field_72769_h.field_72984_F.func_76320_a("prepare");
             TileEntityRendererDispatcher.field_147556_a.func_178470_a(this.field_72769_h, this.field_72777_q.func_110434_K(), this.field_72777_q.field_71466_p, this.field_72777_q.func_175606_aa(), p_180446_3_);
             this.field_175010_j.func_180597_a(this.field_72769_h, this.field_72777_q.field_71466_p, this.field_72777_q.func_175606_aa(), this.field_72777_q.field_147125_j, this.field_72777_q.field_71474_y, p_180446_3_);
+            if(pass == 0)
+            {
             this.field_72748_H = 0;
             this.field_72749_I = 0;
             this.field_72750_J = 0;
+            }
             Entity entity = this.field_72777_q.func_175606_aa();
             double d3 = entity.field_70142_S + (entity.field_70165_t - entity.field_70142_S) * (double)p_180446_3_;
             double d4 = entity.field_70137_T + (entity.field_70163_u - entity.field_70137_T) * (double)p_180446_3_;
@@ -573,11 +578,15 @@
             this.field_72777_q.field_71460_t.func_180436_i();
             this.field_72769_h.field_72984_F.func_76318_c("global");
             List<Entity> list = this.field_72769_h.func_72910_y();
+            if (pass == 0)
+            {
             this.field_72748_H = list.size();
+            }
 
             for (int i = 0; i < this.field_72769_h.field_73007_j.size(); ++i)
             {
                 Entity entity1 = (Entity)this.field_72769_h.field_73007_j.get(i);
+                if (!entity1.shouldRenderInPass(pass)) continue;
                 ++this.field_72749_I;
 
                 if (entity1.func_145770_h(d0, d1, d2))
@@ -599,6 +608,7 @@
                 {
                     for (Entity entity2 : classinheritancemultimap)
                     {
+                        if(!entity2.shouldRenderInPass(pass)) continue;
                         boolean flag = this.field_175010_j.func_178635_a(entity2, p_180446_2_, d0, d1, d2) || entity2.func_184215_y(this.field_72777_q.field_71439_g);
 
                         if (flag)
@@ -672,6 +682,7 @@
             this.field_72769_h.field_72984_F.func_76318_c("blockentities");
             RenderHelper.func_74519_b();
 
+            TileEntityRendererDispatcher.field_147556_a.preDrawBatch();
             for (RenderGlobal.ContainerLocalRenderInformation renderglobal$containerlocalrenderinformation1 : this.field_72755_R)
             {
                 List<TileEntity> list3 = renderglobal$containerlocalrenderinformation1.field_178036_a.func_178571_g().func_178485_b();
@@ -680,6 +691,7 @@
                 {
                     for (TileEntity tileentity2 : list3)
                     {
+                        if (!tileentity2.shouldRenderInPass(pass) || !p_180446_2_.func_78546_a(tileentity2.getRenderBoundingBox())) continue;
                         TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity2, p_180446_3_, -1);
                     }
                 }
@@ -689,9 +701,11 @@
             {
                 for (TileEntity tileentity : this.field_181024_n)
                 {
+                    if (!tileentity.shouldRenderInPass(pass) || !p_180446_2_.func_78546_a(tileentity.getRenderBoundingBox())) continue;
                     TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity, p_180446_3_, -1);
                 }
             }
+            TileEntityRendererDispatcher.field_147556_a.drawBatch(pass);
 
             this.func_180443_s();
 
@@ -718,7 +732,7 @@
 
                 Block block = this.field_72769_h.func_180495_p(blockpos).func_177230_c();
 
-                if (tileentity1 != null && (block instanceof BlockChest || block instanceof BlockEnderChest || block instanceof BlockSign || block instanceof BlockSkull))
+                if (tileentity1 != null && tileentity1.shouldRenderInPass(pass) && tileentity1.canRenderBreaking() && p_180446_2_.func_78546_a(tileentity1.getRenderBoundingBox()))
                 {
                     TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity1, p_180446_3_, destroyblockprogress.func_73106_e());
                 }
@@ -1210,6 +1224,13 @@
 
     public void func_174976_a(float p_174976_1_, int p_174976_2_)
     {
+        net.minecraftforge.client.IRenderHandler renderer = this.field_72769_h.field_73011_w.getSkyRenderer();
+        if (renderer != null)
+        {
+            renderer.render(p_174976_1_, field_72769_h, field_72777_q);
+            return;
+        }
+
         if (this.field_72777_q.field_71441_e.field_73011_w.func_186058_p().func_186068_a() == 1)
         {
             this.func_180448_r();
@@ -1427,6 +1448,12 @@
 
     public void func_180447_b(float p_180447_1_, int p_180447_2_)
     {
+        net.minecraftforge.client.IRenderHandler renderer = this.field_72777_q.field_71441_e.field_73011_w.getCloudRenderer();
+        if (renderer != null)
+        {
+            renderer.render(p_180447_1_, this.field_72777_q.field_71441_e, field_72777_q);
+            return;
+        }
         if (this.field_72777_q.field_71441_e.field_73011_w.func_76569_d())
         {
             if (this.field_72777_q.field_71474_y.func_181147_e() == 2)
@@ -1854,8 +1881,11 @@
                 double d4 = (double)blockpos.func_177956_o() - d1;
                 double d5 = (double)blockpos.func_177952_p() - d2;
                 Block block = this.field_72769_h.func_180495_p(blockpos).func_177230_c();
+                TileEntity te = this.field_72769_h.func_175625_s(blockpos);
+                boolean hasBreak = block instanceof BlockChest || block instanceof BlockEnderChest || block instanceof BlockSign || block instanceof BlockSkull;
+                if (!hasBreak) hasBreak = te != null && te.canRenderBreaking();
 
-                if (!(block instanceof BlockChest) && !(block instanceof BlockEnderChest) && !(block instanceof BlockSign) && !(block instanceof BlockSkull))
+                if (!hasBreak)
                 {
                     if (d3 * d3 + d4 * d4 + d5 * d5 > 1024.0D)
                     {<commit_msg>Fixed outline shader rendering, closes #2560.<commit_after>--- ../src-base/minecraft/net/minecraft/client/renderer/RenderGlobal.java
+++ ../src-work/minecraft/net/minecraft/client/renderer/RenderGlobal.java
@@ -547,8 +547,10 @@
 
     public void func_180446_a(Entity p_180446_1_, ICamera p_180446_2_, float p_180446_3_)
     {
+        int pass = net.minecraftforge.client.MinecraftForgeClient.getRenderPass();
         if (this.field_72740_G > 0)
         {
+            if (pass > 0) return;
             --this.field_72740_G;
         }
         else
@@ -559,9 +561,12 @@
             this.field_72769_h.field_72984_F.func_76320_a("prepare");
             TileEntityRendererDispatcher.field_147556_a.func_178470_a(this.field_72769_h, this.field_72777_q.func_110434_K(), this.field_72777_q.field_71466_p, this.field_72777_q.func_175606_aa(), p_180446_3_);
             this.field_175010_j.func_180597_a(this.field_72769_h, this.field_72777_q.field_71466_p, this.field_72777_q.func_175606_aa(), this.field_72777_q.field_147125_j, this.field_72777_q.field_71474_y, p_180446_3_);
+            if(pass == 0)
+            {
             this.field_72748_H = 0;
             this.field_72749_I = 0;
             this.field_72750_J = 0;
+            }
             Entity entity = this.field_72777_q.func_175606_aa();
             double d3 = entity.field_70142_S + (entity.field_70165_t - entity.field_70142_S) * (double)p_180446_3_;
             double d4 = entity.field_70137_T + (entity.field_70163_u - entity.field_70137_T) * (double)p_180446_3_;
@@ -573,11 +578,15 @@
             this.field_72777_q.field_71460_t.func_180436_i();
             this.field_72769_h.field_72984_F.func_76318_c("global");
             List<Entity> list = this.field_72769_h.func_72910_y();
+            if (pass == 0)
+            {
             this.field_72748_H = list.size();
+            }
 
             for (int i = 0; i < this.field_72769_h.field_73007_j.size(); ++i)
             {
                 Entity entity1 = (Entity)this.field_72769_h.field_73007_j.get(i);
+                if (!entity1.shouldRenderInPass(pass)) continue;
                 ++this.field_72749_I;
 
                 if (entity1.func_145770_h(d0, d1, d2))
@@ -599,6 +608,7 @@
                 {
                     for (Entity entity2 : classinheritancemultimap)
                     {
+                        if(!entity2.shouldRenderInPass(pass)) continue;
                         boolean flag = this.field_175010_j.func_178635_a(entity2, p_180446_2_, d0, d1, d2) || entity2.func_184215_y(this.field_72777_q.field_71439_g);
 
                         if (flag)
@@ -633,6 +643,7 @@
                 }
             }
 
+            if(pass == 0)
             if (this.func_174985_d() && (!list1.isEmpty() || this.field_184386_ad))
             {
                 this.field_72769_h.field_72984_F.func_76318_c("entityOutlines");
@@ -672,6 +683,7 @@
             this.field_72769_h.field_72984_F.func_76318_c("blockentities");
             RenderHelper.func_74519_b();
 
+            TileEntityRendererDispatcher.field_147556_a.preDrawBatch();
             for (RenderGlobal.ContainerLocalRenderInformation renderglobal$containerlocalrenderinformation1 : this.field_72755_R)
             {
                 List<TileEntity> list3 = renderglobal$containerlocalrenderinformation1.field_178036_a.func_178571_g().func_178485_b();
@@ -680,6 +692,7 @@
                 {
                     for (TileEntity tileentity2 : list3)
                     {
+                        if (!tileentity2.shouldRenderInPass(pass) || !p_180446_2_.func_78546_a(tileentity2.getRenderBoundingBox())) continue;
                         TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity2, p_180446_3_, -1);
                     }
                 }
@@ -689,9 +702,11 @@
             {
                 for (TileEntity tileentity : this.field_181024_n)
                 {
+                    if (!tileentity.shouldRenderInPass(pass) || !p_180446_2_.func_78546_a(tileentity.getRenderBoundingBox())) continue;
                     TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity, p_180446_3_, -1);
                 }
             }
+            TileEntityRendererDispatcher.field_147556_a.drawBatch(pass);
 
             this.func_180443_s();
 
@@ -718,7 +733,7 @@
 
                 Block block = this.field_72769_h.func_180495_p(blockpos).func_177230_c();
 
-                if (tileentity1 != null && (block instanceof BlockChest || block instanceof BlockEnderChest || block instanceof BlockSign || block instanceof BlockSkull))
+                if (tileentity1 != null && tileentity1.shouldRenderInPass(pass) && tileentity1.canRenderBreaking() && p_180446_2_.func_78546_a(tileentity1.getRenderBoundingBox()))
                 {
                     TileEntityRendererDispatcher.field_147556_a.func_180546_a(tileentity1, p_180446_3_, destroyblockprogress.func_73106_e());
                 }
@@ -1210,6 +1225,13 @@
 
     public void func_174976_a(float p_174976_1_, int p_174976_2_)
     {
+        net.minecraftforge.client.IRenderHandler renderer = this.field_72769_h.field_73011_w.getSkyRenderer();
+        if (renderer != null)
+        {
+            renderer.render(p_174976_1_, field_72769_h, field_72777_q);
+            return;
+        }
+
         if (this.field_72777_q.field_71441_e.field_73011_w.func_186058_p().func_186068_a() == 1)
         {
             this.func_180448_r();
@@ -1427,6 +1449,12 @@
 
     public void func_180447_b(float p_180447_1_, int p_180447_2_)
     {
+        net.minecraftforge.client.IRenderHandler renderer = this.field_72777_q.field_71441_e.field_73011_w.getCloudRenderer();
+        if (renderer != null)
+        {
+            renderer.render(p_180447_1_, this.field_72777_q.field_71441_e, field_72777_q);
+            return;
+        }
         if (this.field_72777_q.field_71441_e.field_73011_w.func_76569_d())
         {
             if (this.field_72777_q.field_71474_y.func_181147_e() == 2)
@@ -1854,8 +1882,11 @@
                 double d4 = (double)blockpos.func_177956_o() - d1;
                 double d5 = (double)blockpos.func_177952_p() - d2;
                 Block block = this.field_72769_h.func_180495_p(blockpos).func_177230_c();
+                TileEntity te = this.field_72769_h.func_175625_s(blockpos);
+                boolean hasBreak = block instanceof BlockChest || block instanceof BlockEnderChest || block instanceof BlockSign || block instanceof BlockSkull;
+                if (!hasBreak) hasBreak = te != null && te.canRenderBreaking();
 
-                if (!(block instanceof BlockChest) && !(block instanceof BlockEnderChest) && !(block instanceof BlockSign) && !(block instanceof BlockSkull))
+                if (!hasBreak)
                 {
                     if (d3 * d3 + d4 * d4 + d5 * d5 > 1024.0D)
                     {
{'fraction_non_alphanumeric': 0.11035351663825688, 'fraction_numerical': 0.13777514266656785, 'mean_word_length': 2.2468719923002887, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2016704', 'n_tokens_mistral': 5650, 'n_tokens_neox': 4513, 'n_words': 580}