Swatch Slot
I need to create a single Swatch Slot for my new walls (In Default).
How do I do this?
56 Replies
Like the "Ficsit Foundation Swatch" and "Project Assembly Swatch"?
I'm not sure, just asking for clarification
I think there are a few open source mods that add custom search slots you could look at
I want to add a option here (White + White)


Have you tried creating a new subclass of FGSwatchGroup like those are? It might end up auto detected
I created one but I don't know how to use it
oof, gimme a few minutes to collect some screenshots and write something up. I did this for SS and it's kind of a pain in the ass.
What I'm about to post is based on Kyrium's guide to adding swatches. His method is done in cpp, but I've adapted it for blueprints. I'm also not entirely sure that I did it correctly, although it does seem to work.
https://ficsit.app/guide/8RQqqjxcaAGpcb
The first thing you'll want to do is a header edit (yay!)
Open FGSwatchGroup and change mGroupName to editdefaultsonly
From this:
UPROPERTY( VisibleDefaultsOnly )
FText mGroupName;
To this:
UPROPERTY( EditDefaultsOnly)
FText mGroupName;
Then rebuild the project, let me know when you've done that
You will also need these access transformers
BlueprintReadWrite=(Class="/Script/FactoryGame.FGSwatchGroup", Property="mGroupName")
BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mSwatchGroupDatum")
BlueprintReadWrite=(Class="/Script/FactoryGame.FGBuildableSubsystem", Property="mColorSlots_Data")
BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mPlayerGlobalColorPresets")
BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mBuildingColorSlots_Data")Yes, I see your Swatch

How to do?
Open \YourSMLProject\Source\FactoryGame\Public\FGSwatchGroup.h
And make the changes i posted above. Then rebuild the project in VS.
BlueprintReadWrite=(Class="/Script/FactoryGame.FGSwatchGroup", Property="mGroupName") BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mSwatchGroupDatum") BlueprintReadWrite=(Class="/Script/FactoryGame.FGBuildableSubsystem", Property="mColorSlots_Data") BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mPlayerGlobalColorPresets") BlueprintReadWrite=(Class="/Script/FactoryGame.FGGameState", Property="mBuildingColorSlots_Data")Done
Next, Create 3 new Blueprints in this order:
FGSwatchGroup
Only contains a name and you'll need the header edit I mentioned above or set it on the CDO FGFactoryCustomizationDescriptor_Swatch Give it a name and description and an ID. I use ID 30, so maybe use 31, It does need to be unique to all other swatches though. mCategory should be CC_Swatch and mSubCategory should be CSC_Swatch_Default Set menu priority to something high, I used 99.
FGCustomizationRecipe Set mProducedIn to BP_BuildGun Set mCustomizationDesc to the FGFactoryCustomizationDescriptor_Swatch class you created.
Only contains a name and you'll need the header edit I mentioned above or set it on the CDO FGFactoryCustomizationDescriptor_Swatch Give it a name and description and an ID. I use ID 30, so maybe use 31, It does need to be unique to all other swatches though. mCategory should be CC_Swatch and mSubCategory should be CSC_Swatch_Default Set menu priority to something high, I used 99.
FGCustomizationRecipe Set mProducedIn to BP_BuildGun Set mCustomizationDesc to the FGFactoryCustomizationDescriptor_Swatch class you created.



You'll notice my mGroupName is greyed out because I don't currently have the header edit, but your's should be editable.
Damn, I upgraded VS to Version 17.14.21 (November 2025) and now I can't compile anymore. I'll have to reinstall it.

This is the last bit, where you actually register your new classes and inject them in to the games systems. One of the structs is a variable because there is no make function for it.

Note the that ArrayElement index should be the same ID you set up in the swatch descriptor
OK thanks, I'll try it when I've reinstalled VS
And you would run this code from begin play in a subsystem or from the life cyle event in a module (any phase)
Interesting. I gave up on doing this a long time ago because Kyriums cpp method seemed too prone to conflicts.
I think it still can be, especially with the ID.
Yeah I think adding/removing mods and other things will probably cause some surprise shuffling.
Yeah, I freely admit that I'm not sure it's done correctly, but it does seem to work so far and no one has complained about it afaik
I thought blueprint read write could override visible defaults only
I dont think so. I have an active AT for the property and it's still greyed out. Also, this:
https://discord.com/channels/555424930502541343/601030071221878784/1293319735945199749
What about EditAnywhere?
I placed the code in the Game World module on ELifeCyclePhase.
So I do have access to the swatches in the buildable, and when I build an element, it correctly displays the predefined colors.
The only thing missing is the display of this swatch in the defaults (via X), why?
@D4rk @Jean Michel based on this: https://unreal-garden.com/docs/uproperty/#editanywhere
I think EditAnywhere will override
VisibleDefaultsOnlyUnreal🌱Garden
All UPROPERTY Specifiers
Sample code, screenshots and comments for all specifiers, including undocumented ones.
I haven't had an opportunity to test it myself yet
I'm not sure what you mean by this, which part isn't working?
Good to know, but it requires a header edit either way
I was able to edit it.
What would that change?

That is the name as it will appear in the UI
for which part? I re-read your message and it appears the only header edit is to swap VisibleDefaultsOnly to EditDefaultsOnly. I am assuming that applying this access transformer https://docs.ficsit.app/satisfactory-modding/latest/Development/ModLoader/AccessTransformers.html#_editanywhere would override the old VisibleDefaultsOnly, and EditAnywhere is more permissive than the EditDefaultsOnly the original header edit swapped to
Unless I'm mistaken and it's the name in the descriptor. I used the exact same text for both.
I don't have the button like yours

The AT does not override VisibleDefaultsOnly. so it doesn't matter if you change it to EditAnywhere or EditDefaultsOnly, both require a head edit.
Did you do this part
https://discord.com/channels/555424930502541343/1441027604894453892/1441143077871030324
Same name in desc

@Mircea (Area Actions) can you confirm if this is intended access transformers behavior? I would expect that using an AT to add an incompatible but more permissive access transformer would replace the less permissive access transformer. especially because doing so reduces the number of access transformer variants that need to exist
Yes

It's definitely not intended
But I remember checking this case specifically
I phrased that question poorly, sorry. is adding conflicting but more permissive intended to override, silently fail, or loudly fail?
Wdym by conflicting?
EditAnywhere vs EditDefaultsOnly, or EditAnywhere vs VisibleDefaultsOnly?
EditAnywhere explicitly clears everything VisibleDefaultsOnly sets


So it should definitely work
Hmm, I have the AT for the property and it is still greyed out. I cant edit it without the header edit
this is my source for considering them conflicting https://unreal-garden.com/docs/uproperty/#editanywhere, I wonder if there is an order of operations thing going on here

UHT considers them incompatible
But for us we just set the flags to what we want them to be
Which means clearing any flags that might be set by those incomaptible modifiers, and setting the flags that our modifier would set
I missed something yesterday. The recipe you created needs to be added to a schematic and unlocked. You can auto unlock it with code or make the player unlock it in the HUB or awesome shop in the normal way.


Thanks, I test it
Fantastic!
Thank you so much!

@Mircea (Area Actions) @Robb (Busy)
Should I reset the value to VisibleDefaultsOnly or leave it as is for the mod's release?
You can leave it, it makes no difference in the shipped mod. ATs are editor env only
access transformers and header edits are compile time only - it is not adjusting the game's behavior, it is basically just turning off the safeties that keep you from accessing it
What was decided though? Should the AT override VisibleDefaultsOnly or not,
I didn't fully understand what Mircea said
although if you have the time, if you could undo your header edit and try using an
EditAnywhere access transformer on it instead to see if it still works (make sure to revisit the blueprint trying to use it and compile/check for errors in it specifically), that would be nice
I believe the AT is supposed to override itThey should and they do
OK, I'll try tomorrow.
Many thanks to all three of you.
All that's left for me to do now is build the hundred or so elements.
Good night, or good day.
Sorry I made you jump through that hoop Jean, I'm a bit behind on the AT stuff and I didn't know the EditAnywhere AT existed. This is all you needed.
BlueprintReadWrite=(Class="/Script/FactoryGame.FGSwatchGroup", Property="mGroupName")
EditAnywhere=(Class="/Script/FactoryGame.FGSwatchGroup", Property="mGroupName")
it is one of the more recent ones