Total War: WARHAMMER III

Total War: WARHAMMER III

Scrap Upgrade UI Framework
66 Comments
Trident121 11 Jul @ 2:45am 
Cannot see this mod in SFO as dwarfs. I Aldo have better Ui mod. Conflict?
Porkenstein 21 Apr @ 1:34pm 
"If you are mod author, feel free to just credit this & insert these ui files directly into your own mod --- after all we are all doing free work for CA :-)"

You are the best, mr holder
BAGHolder  [author] 2 Apr @ 4:40am 
updated to 6.1.

Briefly tested it works fine & the kislev invocation button is there.

If you still notice any issue, try resubscribe.
Pfleger Von Yggdrasill 1 Apr @ 12:26pm 
I don't think dirty dan's mods work with this one, or is it need to be placed above this one?
Uryens 31 Mar @ 4:14pm 
Not dwarf upgrades, any mod adding unit upgrades that requires this. And some that dont require it but have not been updated properly either.
karcen 30 Mar @ 4:00pm 
Did the dwarf upgrades break or rather all of them the upgrade button vanished.
EliteGamer11388 30 Mar @ 12:53pm 
Ugh, I hate when updates break mods. I get that updates are good, and a lot of times necessary, but not all modders return to update their work. Not saying this one will or won't, just some don't. There isn't really a good solution, other than waiting.
Jolc3r 30 Mar @ 5:48am 
Same here, kislev has a new army invocations that this mod overrides.
AkumulatoR 29 Mar @ 3:08am 
This mod breaks nukislev army invocations button by taking its place.
lechkingofdead 26 Mar @ 2:13pm 
im here to let ya know to update ya mod file because thew game has updated and some mods have broken
mace_palframan 7 Mar @ 2:32pm 
Wondering, if there is a dark elf one? Looked through the list, found everything but DE.
BAGHolder  [author] 27 Jan @ 9:54am 
Pushed another minor update: hide the UI upgrade button for loaned-army (their units cannot be upgraded by player anyway).
BAGHolder  [author] 27 Jan @ 9:53am 
@ViGabooo

Dwarf has no upgrade in vanilla --- should be the mod issue (whichever mod added the upgrade)

@Barmaley

You may ask Chop if he can make this compatible.
ViGabooo 26 Jan @ 11:36pm 
i can't upgrade dwarf units, i have the resources (the currency not the oathgold) but i still can't upgrade with it the oathgold is fine.
Barmaley 26 Jan @ 10:48pm 
A useful mod, but breaks "[Ui] Chop's 1080 Modpack Support | Compilation: 1920x1080 Res"
Tag_Ur_It--> 26 Jan @ 3:45pm 
@BAGHolder thank you! I had to stop myself from playing cause I knew i'd just upgrade everything and it would be boring so thank you OP
BAGHolder  [author] 26 Jan @ 2:47pm 
@Tag_Ur_It-->

Thank you for reporting! I hope you saved your awesome run, because it is now patched :-)

Clan moulder is now excluded from using scrap upgrade. I guess they are supposed to always use flesh lab for upgrade.

The exploit happened because CA used the same db table for flesh lab & scrape upgrade..
BAGHolder  [author] 26 Jan @ 2:17pm 
@Backmechuisa

Thank you for the great solution!

Implemented & credited you in the description --- if you want to be added an author I am happy to do that too!

@Radious

The updated ui script now has the button hidden for factions without upgrade option.
akeean 20 Jan @ 7:46pm 
GOAT. Why would CA restrict this all of a sudden...? There are so many more important things in the game that are broken by implementation or even as basic concept (sieges, butt ladders, actual siege and land battle maps, broken database tables, units not holding their weapons or with textures missing, wrong unit tags, diplomacy & trade, loads of quest battles, endgame crisis and an actual chaos invasion etc). Yeah but sure, make sure only greenskins and wood elves can use scrap mechanics.

I wonder if they get confused by bug reports of people trying to load old campaigns that ran scrap mods that CA's random breaking updates with minor actual improvements broke and they take that as signal as "scrap upgrade mods tend to cause instability to the game, lets better not have that as easily moddable"
Tag_Ur_It--> 15 Jan @ 10:09am 
I was able to add every scrap upgrade at the same time to any unit for free during a clan mouolder run. Is that normal?
Backmechuisa 14 Jan @ 1:39am 
Many modders will likely use your file as a basis to create upgrade unit mods, so I hope this modification proves helpful to many of them.
While working on compatibility using the file you provided, I came across this issue and sought to find a solution.
Thank you for your work and contribution.
Backmechuisa 14 Jan @ 1:39am 
Hey BAGHolder, thanks for your efforts.
However, the current visibility code in the hud_campaign.twui.xml file causes inactive buttons to appear even for factions that cannot upgradeable units.
So, I would recommend the following modification:
I’ve moved from the existing functionality of detecting upgradeable units into the VisibilitySetter condition.
This way, factions with upgradeable units will naturally have the button activated, while those without such units will have the button hidden naturally, without requiring additional options or Lua code.

--
context_function_id="IsContextValid(SelectedCharacter.MilitaryForceContext.FactionLoanedFromContext) == false">
--
from this.

--
context_function_id="Component("units", "main_units_panel").ForceContainsUpgradableUnits">

--
to this.
Mortrau 28 Dec, 2024 @ 7:05pm 
@BAGHolder Big thanks for this fix! Sadly that CA made this such way and forced us to seek for TWUI solutions.
Belial 22 Dec, 2024 @ 6:07am 
@BAGHolder, thank you very much for your work.
I've already implemented your solution to my update of "Immortal Armouries".
Let me know if you want to be added as a contributor.
Thank you
Dante 22 Dec, 2024 @ 12:48am 
For those of you using this Framework with Alternative Unit Cards by r1kko, here is a submod enabling compatibility between them so you will see r1kko's unit cards instead of CA's vanilla unit cards: https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=3389219182 . Be warned that it does use AI 2x upscaling.
Dante 21 Dec, 2024 @ 8:28pm 
@Nanu Thanks for the incompatibility fix!
Avallac 21 Dec, 2024 @ 6:08pm 
Thank you.
Nanu 21 Dec, 2024 @ 4:38pm 
@BAGHolder Well each unit has several hundred potential upgrades the mod chooses from so it would get overwhelming fast lol
BAGHolder  [author] 21 Dec, 2024 @ 3:57pm 
@Nanu

That is great, thank you very much for the efforts!

Now some people may miss the free upgrade :-)
Nanu 21 Dec, 2024 @ 8:57am 
Patch is up. I no longer see Dynamic RoR effects on your UI. I think these mods work together now.
Nanu 21 Dec, 2024 @ 8:49am 
@BAGHolder I think I found the issue. I was able to get some units to hide their effects by delaying the locking function. The rest were not getting locked due to changes in the prefixes that I forgot to update in the script. I'm uploading a patch soon that I hope will make these two mods compatible.
Milhojas 21 Dec, 2024 @ 7:28am 
@Nanu and @BAGHolder, thanks for the update, I was worried something may be wrong
BAGHolder  [author] 21 Dec, 2024 @ 4:37am 
@Nanu

Thank you for the info!

Well, this mod only removed CA's check condition on culture (only greenskin & woodelf tree), and only changed two ui files...

Looks to me the script lock no longer works for the new UI. Not sure if it is possible to add such a condition in the ui files..

If nothing else, we can just say it is not meant to be used together due to the free lunch :-)
Dante 20 Dec, 2024 @ 2:03pm 
@Nanu thanks Nanu for the follow-up!
Nanu 20 Dec, 2024 @ 1:49pm 
@BAGHolder The upgrades my mod uses aren't meant to be purchasable. I use the following line of code to lock all effects added by my mod:

cm:faction_set_unit_purchasable_effect_lock_state(faction, effect, "", true);

This worked for the vanilla UI that CA removed. I haven't looked at your mod yet but I imagine it would be simple to create a patch that checks for my effects (I use a standard prefix for all of them to ensure any that aren't locked or are added by submods get locked on game load) and doesn't add them to your UI. I'll take a look this weekend
BAGHolder  [author] 20 Dec, 2024 @ 1:36pm 
@Dante

Thank you for the information!
I didn't know that...most mods out there restricts upgrade using money + resource..
Dante 20 Dec, 2024 @ 12:31pm 
If anybody was wondering why you could buy unit upgrades for free right off the bat for these factions including Ogres and Skaven, its due to a incompatibility with Nanu's Dynamic Regiments of Renown . The framework inadvertently exposes Nanu's upgrades for free for those factions.
BAGHolder  [author] 19 Dec, 2024 @ 3:19pm 
@Iconomy

Cannot be the UI mod. Must be some other mod adding upgrades.
Iconomy 19 Dec, 2024 @ 10:22am 
Not sure if this is due to your mod or the dynamic ROR mod or the Wood Elf upgrades mod, but playing as Khorne I was able to upgrade units to any ROR variant for free from the scrap menu
BAGHolder  [author] 19 Dec, 2024 @ 5:27am 
@Huppias

Do you mean the UI file for his army skills?

You can use context viewer to find out (just google "wh3 context viewer").
Huppias 18 Dec, 2024 @ 5:52pm 
Boss, do you know where the demon Prince's random army skills are?
BAGHolder  [author] 18 Dec, 2024 @ 8:38am 
@Radious

Hi Radious! I don't see a direct way to limit the button appearance ... would do if I can.


This is controlled by the "hud_campaign.twui.xml" file under data.pack.
On line 12269, CA limits the button by an if condition for greenskin culture, or Drycha or argwylon.

I simply removed those conditions -- which makes the button appear for every race.


I don't see an easy way to verify if a race has scrap upgrade or not, because it is only coded in UI file only, not any db table entry.

Alternatively, one can add more "or condition" to include any specific culture / faction they wish.
BAGHolder  [author] 18 Dec, 2024 @ 8:38am 
@Synthetic Man

Not a problem at all --- feel free to do so, see the last section.
Synthetic Man 18 Dec, 2024 @ 4:08am 
Hello hello! We have figured out how to tweak it slightly and restrict it to specific factions only. Is it okay if we incorporate a modified version of your framework into our mod? With full credits of course.
Radious 17 Dec, 2024 @ 8:52pm 
Good day. Thank you for this fix. Is it possible to hide upgrade icon for all other races which do not have upgrades enabled? It will confuse a lot people to see it on every race when we for example did upgrades for other 3 only.
Ubermorgen 15 Dec, 2024 @ 10:23am 
Great work! It's sad that modders have to fix stuff like that though.
nullmana 15 Dec, 2024 @ 9:46am 
Thanks a lot for your framework. you just saved my weekend fixing my mod :)
Huppias 15 Dec, 2024 @ 7:11am 
@BAGHolder Yes, CA doesn't have some large unit cards to draw, Add to ui => units => infopics
BAGHolder  [author] 15 Dec, 2024 @ 4:33am 
@Huppias

I think it is because CA didn't do large unit cards for some units, so it default to greenskin infantry --- just let it be :-)
BAGHolder  [author] 15 Dec, 2024 @ 4:31am 
@Barstow @Time Police Officer @Human72

Ok I checked that it is not the UI file having the restriction.

Units can get all available upgrade, so long the "is_exclusive" is off in the db/unit_purchasable_effect_sets table.

All vanilla greenskin and woodelf upgrades has this off, that is why you may get all their upgrade.

But most mods (like Dirty Dan's) has this setting on, so you can only get one upgrade.

Check with the mod author on lifting this restriction, or use RPFM to change that yourself.