[SOLVED] Advanced GUI customization

#1

Hello internet,
I’m currently making a kingdom mod and wanted to customize the UI a “bit”. I’ve looked into several other mods to see how to set individual buttons, but all I found was a replacement of the town.png.
Actually I want to go a bit further and change ALL buttons in the start_menu. Unluckily it seems like it is not possible to replace the buttons in the same way, like the town.png. As you can see below I made an override for every button (like everyone does with the town.png), but nothing is happening.
Still the town.png changes ingame, but the others are all the default buttons. There is no error, neither as a pop up, nor in the stonehearth.log. The buttons I made have the same size as their default counterpart and no transparency (Don’t know if this is important, but checking the pics was my first attempt to solve the problem).

Any ideas where I could have made a/some fault/-s?
Whoever solves this problem will get a sneak peek of the mysterious elders (It’s worth it, promised!) :wink:

{
“info” : {
“name” : “elders_ui”,
“deferred_load”: true,
“client_only”: true,
“version” : 3
},
“aliases” : {},
“mixintos” : {
“stonehearth/ui/data/constants.json” : “file(ui/data/constants.json)”,
“stonehearth/locales/en.json”: “elders/locales/en.json”
},
“overrides” : {
“stonehearth/ui/game/start_menu/images/dock.png” : “file(start_menu/dock.png)”,
“stonehearth/ui/game/start_menu/images/town.png” : “file(start_menu/town.png)”,
“stonehearth/ui/game/start_menu/images/citizen.png” : “file(start_menu/citizen.png)”,
“stonehearth/ui/game/start_menu/images/dock_crafters.png” : “file(start_menu/dock_crafters.png)”,
“stonehearth/ui/game/start_menu/images/harvest.png” : “file(start_menu/harvest.png)”,
“stonehearth/ui/game/start_menu/images/manage_bulletins.png” : “file(start_menu/manage_bulletins.png)”,
“stonehearth/ui/game/start_menu/images/new_builder.png” : “file(start_menu/new_builder.png)”,
“stonehearth/ui/game/start_menu/images/place_item.png” : “file(start_menu/place_item.png)”,
“stonehearth/ui/game/start_menu/images/zone.png” : “file(start_menu/zone.png)”,
“stonehearth/ui/game/unit_frame/images/bg_border.png” : “file(unit_frame/bg_border.png)”,
“stonehearth/ui/game/unit_frame/images/command_button_bg.png” : “file(unit_frame/command-button-bg.png)”,
“stonehearth/ui/root/css/images/input/checkbox.png” : “file(input/checkbox.png)”,
“stonehearth/ui/root/css/images/gui/button.png” : “file(gui/button.png)”,
“stonehearth/ui/root/css/images/gui/panel.png” : “file(gui/panel.png)”,
“stonehearth/ui/root/css/images/gui/title.png” : “file(gui/title.png)”,
“stonehearth/ui/root/css/images/gui/well.png” : “file(gui/well.png)”,
“stonehearth/ui/root/css/images/gui/well2.png” : “file(gui/well2.png)”,
“stonehearth/ui/root/css/images/gui/tab.png” : “file(gui/tab.png)”,
“stonehearth/ui/root/css/images/gui/tab_active.png” : “file(gui/tab_active.png)”,
“stonehearth/entities/gizmos/camp_standard/camp_standard_ghost.json” : “file(/elders/entities/standard/elders_camp_standard_ghost.json)”
},
“ui”: {
“less”: [
“file(unit_frame/unit_frame.less)”,
“file(gui/gui.less)”,
“file(game/character_sheets/citizen_character_sheet/citizen_character_sheet.less)”
]
}
}

Thanks in advance :v:

1 Like
#2

Try adding a leading / before stonehearth in those paths.

#3

Unfortunately it doesn’t change anything at all. I added a leading / before any path. The new town.png is still shown correctly, but the other buttons remain unchanged.
I might be wrong, but I assume, that when it works for the town.png in this way, it should work for the other buttons aswell.

Quite hard to find any mod to compare to. Most custom kingdoms only change the town.png (like in rayyas children)

#4

What about the dock? Rayya also changes that.
Here in the firefly kingdom it also changes the citizen button:
screenshot%202018_06_14__13_14_42

1 Like
#5

And now I know what my next mod change is going to be… Thanks Bruno :’)

#6

The dock works aswell.

Can you tell me how you changed the button? Is my attempt even right?
I assume the A23 experimental build I have is outdated. Neither the town nor the citizen button is changed.

#7

Sometimes I doubt my mind.

Its both “citizens”. Not “citizen” :sweat_smile:

2 Likes
#8

Yes, the swamp is outdated. In a few minutes I will update that, just need to prepare the post.
What I did was just like you did, in the “mod_ui” I have an override section with:

	"stonehearth/ui/game/start_menu/images/citizens.png": "file(ui/game/start_menu/images/citizens.png)"

That fixed it for you? Else I can’t see anything wrong with what you did, should work.

#9

Yes, now it works properly. Seems like overriding a non existing file with another non existing file causes a jump to the end of the “override” component.

The promised reward, that is actually publicity:
Dryad_sneakpeek

4 Likes
#10

hearthligns have invented the ghilly suit :stuck_out_tongue: ?

1 Like
#11

Yes. This is totally going to be a Battlefield Mod :smiley:

#12

well i recently thought up a way to do a naruto-style susanoo/shaman king style oversoul, so a hearthling tank isnt out of the question…

1 Like