minetest-mods / unified_inventory

An extensible inventory mod which allows searching crafting and browsing for recipes in the same dialogue.
Other
50 stars 38 forks source link

Improve consistency of inventory (and alike) imagery #166

Closed VanessaE closed 3 years ago

VanessaE commented 3 years ago

In a number of places, background[] is misused to place the inventory backdrop images. Where appropriate, image[] is used instead, so that "ui_form_bg.png" actually serves as the one and only true background image.

In so doing, I was able to remake the bag inventory images, making them only big as is actually needed to hold 1, 2, or 3 rows of inventory slots.

This, in turn, allows a standardized main inventory image to occupy the lower part of the window, which allows for consistent inventory image positioning and sizing from one page to another.

I also removed ui_misc_form.png. Nothing in UI uses it, and any external mods that used it can just use the standard inventory and its background.

Lastly, I reduced the background image to 512x384 px. It was unnecessarily large before, considering it has no real detail.

The larger inventory images are all 512px wide, and multiples of 64px in height. Before, they were oddly sized.

BuckarooBanzay commented 3 years ago

Uhm, is there a reason you removed the luacheck workflow? :thinking:

VanessaE commented 3 years ago

Sorry about that, I'm not at all sure why git chose to delete those files (wasn't my intention :smiley:). Should be good now.

SmallJoker commented 3 years ago

Conflicts with #162 that also uses fill for image backgrounds.

VanessaE commented 3 years ago

Frankly I think that looks ugly as sin, and part of the signature look of Unified Inventory is the rounded inventory slots in its images. I just made them more consistent, while that pull request destroys the look and feel of the mod entirely.

I strongly encourage you to reject that one, in favor of mine.

VanessaE commented 3 years ago

To prove my point, here's how UI is themed by way of this PR's changes, in the resurrected Dreambuilder game I'm working on:

image

VanessaE commented 3 years ago

Trash icon is no longer a square

Unintentional but I can correct it if you want. Oddly, neither the code nor the image have been changed. Must be the result of changes to how the other images are applied.

ItemStack position is better but IMO placed too far down

You can't make this comparison from the Bags page -- part of the consistency issues this PR addresses is that the images formerly used in the Bags page had a mildly-different version of the 8x4 inventory area, which looks like someone was being lazy or sloppy.

Rather, you need to use the initial Crafting page for comparison. I tried to get cube-shaped stuff to look centered, and then once I liked it, the other pages followed.

SmallJoker commented 3 years ago

Unintentional but I can correct it if you want.

Yes please. The other pages look better now, although I wonder whether there wouldn't be a more generic way to style unified_inventory. I'm thinking of adding a per-player settings page which would then allow to change between slim/full mode and supported styles (sfinv-style or unified_inventory style). Yet I need to find time and motivation to implement that.

For historical reasons I'll favour this PR over the other, but would welcome more customization to switch to the default game (originally sfinv) style in the future.

VanessaE commented 3 years ago

I took a closer look, and if I download your image and examine it, the trash icon is 56x57 px the "PR" frame and 64x60 px in the "Master" frame

For comparison, a nearby inventory slot is 68x65 px in the "PR" version and 62x64 px in "Master" (ignoring a shadow on the right that isn't noticeable at normal size).

So the trash can icon is actually more square in my PR, it's just a little smaller. Nothing is square. :smiley: If anything, I suppose the most appropriate thing to do is make the icon the same size and aspect as the inv slots.

The difference must be the result of changes to how the other images are applied.

more customization to switch to the default game (originally sfinv) style

Sounds like something simple to do, by just not loading the images at all, if some setting is enabled.

Should I add-in the two "standard button" images and the code that uses them?

SmallJoker commented 3 years ago

Thanks. Looks good. Will merge in a few days if there are no objections in the meantime.