make gui element ignore other elements in parent / x/y position of elements

User avatar
ownlyme
Filter Inserter
Filter Inserter
Posts: 444
Joined: Thu Dec 21, 2017 8:02 am
Contact:

make gui element ignore other elements in parent / x/y position of elements

Post by ownlyme »

When you display stuff in gui.center with top_margin etc, you quickly run into issues when other gui elements use the same parent.
for example this cute little mana bar:
manabar.png
manabar.png (7.22 MiB) Viewed 1233 times
Everything seems fine, but now let's add a frame...
frame.png
frame.png (6.99 MiB) Viewed 1233 times
And suddenly everything's really screwed up...

Maybe you could add a flag like ".ignore_other_elements" or x/y coordinates of elements...

please also notice my other thread about displaying elements on top of the game's gui (not related to this particular mod)
viewtopic.php?f=28&t=70866
creator of 55 mods
My api requests/suggestions: ui relative for overlay||Grenade arc||Player Modifiers||textbox::selection||Singleplayer RCON||disable car's ground sounds
User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5211
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: make gui element ignore other elements in parent / x/y position of elements

Post by eradicator »

We're all still waiting for screen.add{}

viewtopic.php?p=348718#p348718
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Bilka
Factorio Staff
Factorio Staff
Posts: 3314
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: make gui element ignore other elements in parent / x/y position of elements

Post by Bilka »

This has been implemented for the next version of 0.17. See viewtopic.php?f=65&t=46487#p443704
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
Post Reply

Return to “Implemented mod requests”