Minecraft Blogs / Art

In-depth — Seamless transparent containers and its issues

  • 263 views, 1 today
  • 2
  • 1
Hebgbs's Avatar Hebgbs
Level 47 : Master Archer
41

Introduction

Hi! Author of InventorySense Transparent UI / InventorySense UI Transparent fork and its respective additive works. This blog post will explain in dry, boring terms how the "Seamless" tab effect is created for both creative inventory and recipe book, as well a specific issue which is caused with its current implementation, which could have a resolution.

The effect

How the transparent UI mod achieves this effect is relatively simple: bits of the container are removed to be replaced as necessary by the various tabs which make up each container interface. While there was a lot of work figuring out the exact pixels I had to remove, basically once I had one or two of them figured out, replicating for the rest of the tabs was easy enough as separation between each are equidistant from one another, save for the bigger gaps in creative inventory where there are basically four sections of tabs that make up the top and bottom rows.

How I figured it out for creative initially was through an exercise of trial and error — After using a colour to see exactly what of the container body I had to remove was, I did just that and made the bits you see completely transparent. The active tabs were then modified to have empty space in the middle, and the inactive tabs kept their appearance to pull off this illusion, so the original look of the inactive tabs were preserved while providing this seamless transition between tab element and container body.

The recipe book was much of the same, except no alterations to the tabs beyond transparent modifications were necessary. Overall, it's a sore sight better than how VanillaTweaks tackled this issue, which I hope in future is something they may consider if someone were to ever recommend my work, should I not bring up its issues myself.

Concept issues

Creative inventory
This issue has to do with the default appearance — Unmodified aside from deleting most of the main colour, the tabs hang one pixel down compared to the container body. My resolution to this was to modify the tabs, but modifying the container frame would had also been an equally--sufficient option, at the risk of making the container appear slightly shorter — for preservation of the default appearance, I figured making the tabs line up with the frame was a better choice.

Recipe book
This is where the real problems are at; Using the same trick for recipe book, it looks great when all five tabs are available to the player, which for anyone experienced in the game is typically within an hour's worth of play on any server. For less experienced players, the appearance of the recipe book is ruined by the appearance of gaps, because I refuse to do what the fine people of Dokucraft did by making them look like buttons rather than tabs.

OptiFine?

No. That's the short answer, but also the least interesting. OptiFine allows for different container states, texture states and so-on — advanced properties for users of the custom GUI feature so authors can have tons more flexibility with resource packs, which explains in part its dominance as a multi-purpose game improvement solution.

There sadly appears to be little interest in resolving the issue of lacking recipe book customization, of which for the 1.17 release I would love for all authors to have the capability of creating themed recipe book pages, which would — via an indirect way — resolve my problem by using slightly different copies of the recipe book container to basically have only one tabs' worth of missing pixels, which would allow for my effect to not have this particular issue.

Will they get around to figuring it out? It'd probably be deemed low-priority, so not very likely, though there are possibilities for authors being tossed out if they elect to do nothing about this specific issue, as I'd love to see what comes of themed recipe book sections — I am sure there are ideas swimming around in your brain already having read this.
Tags

Create an account or sign in to comment.

Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome