Posted April 26, 20205 yr Hi, so I was wondering if it's possible to stop rendering all the tile entities in a world? I want to stop all and any blocks or entities from being loaded in so I am able to get the total MC Client's CPU usage down to 1%-5% I just want to know if this is possible, if so, how can it be done? I still want to be able to see things in my inventory, just don't want to render any of the textures in the world itself. I'd want it to look something like in the image provided. The imagine provided is something someone else had sent me. I'll probably end up back porting this to 1.12 then I guess. Edited April 26, 20205 yr by playerbase dont want the 2nd image in there.
April 27, 20205 yr Hi Yeah it's possible if you're willing to poke deep into the vanilla code. Your code can do basically anything it wants; use Reflection to change the access levels of fields and then you can modify the render structures to your heart's content. Look at WorldRenderer and especially WorldRenderer ::updateCameraAndRender. The problem with doing this is that it often isn't robust, and will likely make your mod incompatible with others. Thread safety can be difficult as well. But it's for sure possible. Cheers TGG
April 27, 20205 yr If you are just looking for a way to AFK in Hypixel SkyBlock (as indicated by the picture) then there are mods out there that disables the client rendering at all (even the window itself). However, If you want to make a general mod for disabling parts of the rendering, you need to use reflection to change certain aspects like the WorldRenderer (as TGG mentioned above), or unbind renderers from TEs if you want to disable TESRs from rendering while keeping world rendering the same. You might want to check out https://github.com/davidmaamoaix/StopRender (the code is for 1.12.2, but the concept haven’t change much). Some tips: Spoiler Modder Support: Spoiler 1. Do not follow tutorials on YouTube, especially TechnoVision (previously called Loremaster) and HarryTalks, due to their promotion of bad practice and usage of outdated code. 2. Always post your code. 3. Never copy and paste code. You won't learn anything from doing that. 4. Quote Programming via Eclipse's hotfixes will get you nowhere 5. Learn to use your IDE, especially the debugger. 6. Quote The "picture that's worth 1000 words" only works if there's an obvious problem or a freehand red circle around it. Support & Bug Reports: Spoiler 1. Read the EAQ before asking for help. Remember to provide the appropriate log(s). 2. Versions below 1.11 are no longer supported due to their age. Update to a modern version of Minecraft to receive support.
April 27, 20205 yr Author I peaked at the StopRender mod from the link you provided before and now, yet when I entered in different TileEntities, nothing actually worked I always seemed to get an error, this is when I used 1.12.2 as well, if you understand it, perhaps you could show me a working example? Cause even the example provided by the mod developer on curseforge, it doesn't work so I'm unsure how to progress from here. 6 hours ago, DavidM said: If you are just looking for a way to AFK in Hypixel SkyBlock (as indicated by the picture) then there are mods out there that disables the client rendering at all (even the window itself). However, If you want to make a general mod for disabling parts of the rendering, you need to use reflection to change certain aspects like the WorldRenderer (as TGG mentioned above), or unbind renderers from TEs if you want to disable TESRs from rendering while keeping world rendering the same. You might want to check out https://github.com/davidmaamoaix/StopRender (the code is for 1.12.2, but the concept haven’t change much). Do you know if any mods that disables the client rendering like you had said above? Like including the window itself? If so could you perhaps list one? It'd be quite useful and I'd appreciate the assistance. Edited April 27, 20205 yr by playerbase Had to add more info and didn't want to double post.
April 28, 20205 yr Author Also, I know forge no longer has long term support for 1.12.2 hence why I'm asking for 1.14 perhaps this could be done for 1.12.* I'm still fairly new to this.
March 2Mar 2 Just in case anyone else looks at this in the future, in 1.12.2 there was a boolean for whether the world and HUD renders would update or not. I assume it still exists in future versions. Things to keep in mind: 1. It will prevent the HUD from updating as well, not just the world render. You'd have to make your own HUD render calls if you want the HUD to update (maybe after rendering a black background on top of the latest world render, see below). 2. It will not remove the existing world view / render...it will look more like the game is paused (even if it isn't), like a screenshot. If you want a black background, you could simply render a black background on top of it. It does prevent all the heavy render calls and uses basically no render-based CPU. 3. Make sure to re-enable the boolean at an appropriate time, obviously... 4. This also ends up skipping normal GUI renders. If you want to render something, the most obvious hack is Minecraft.getMinecraft().addScheduledTask(), as those are run on the constant loop and not just on tick. I won't go into detail on that. 5. Sounds and their positions, and all game logic is still updated as normal (assuming the game is not paused). Minecraft.getMinecraft().skipRenderWorld = true; Edited March 2Mar 2 by Laike_Endaril Additional info
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.