#slate
1 messages ยท Page 11 of 1
ah race conditions. fun
but i dont think im even gonna use it on multiple items, so i basically did all this for nothing
but its ok. i know for next time
lmao. oh do i know that feeling.
I scrapped my last quest editor because although it looked neat, it was actually a pain to use.
i made a custom graph editor that functioned more of a asset builder.
Even had nested graphs and custom widgets for the nodes
yeah the main advantage is how easy it is to do quest branching
on the save and compile it just traverses the graph and builds the asset.
for instance
thats cool as shit dude. i wouldnt even know where to start on what youre working with.
I'm dumb as a fuckin rock. took a whole month to get there lol. just got to start small.
AI is almost useless because of how undocumented custom graphs are
Studdying this library was really helpful
https://github.com/jinyuliao/GenericGraph
But there's still a lot of things that aren't documented that you need to get things working.
drawing wires, assigning pins, connection policies, etc.
just a lot of trial and error.
and my use was to make it a asset builder as opposed to a regular exucition graph. so that added some other small layers of complexity
honestly when I'm done with this current version I may re-add the graph as a second editor option, or as a quest flow viewer
thanks for that doc, ill add it to my research backlog!
np. feel free to @ me if you have any questions. It's a doozy lol
sure thing! probably not for a while though, ive embarked on some other projects and probably wont interact with graphing stuff and editor slate
sweet, by the time you finish that I'll be on my next quest editor iteration instead of actually working on my own project lol

im not sure what else i need to actually package my plugin. some videos say i need to do some .bat stuff for different versions, other people say i dont because its an editor plugin and has no game content, so i can just hit the package button and submit it.
yeah that's one I wouldn't know. I've not tried to package a plugin before
are you trying to support older versions of unreal as well?
id certainly like to. i dont think any of my code is specifically 5.4 related. i can probably do every engine version that has FPaths implemented. unless the specific font folder im modifying hasnt always been where it currently is. ive only ever used the currently newest version tho, so idk what the old ones had
meh. ill try to actuall work on that tomorrow. today was a bust, because i got distracted. but one day ill accomplish it
oh my god. i hate AI.
copilot helped me a lot in making my checkbox yesterday, but it steered me in the wrong direction. i knew there had to be ways to manipulate the metadata of a property but i just didnt understand fully how to do it, and when i asked the AI it kept telling me that it wasnt manipulatable in runtime. so i decided it must be right and i went in another direction with it, that is way more annoying.
i asked more directly today because i had another little hiccup and i thought metadata would be a great way to solve it, so i asked it to explain how property metadata works and it gave me a lot of good information, that completely contradicts what it said yesterday
https://github.com/DoubleDeez/MDMetaDataEditor/tree/main
you might like looking at this for your project. manipulating metadata seems like a great way to modify your property sections.
i also just had another idea for you. there is a metadata property called DisplayAfter or DisplayPriority, that you can use to decide the order of your properties in whichever category they are.
Yeah I find most models to be so useless at the lower level suff in unreal
o1 has been pretty good actually, but still needs some massaging
Claude routinely lies, makes shit up, and comes up with some stupid convoluted ways to accomplish a task
for instance, one thing i hate in unreal is how inherited properties / categories show up last in the details panel
I wanted to have them show up first so all the defaults could be at the top
claude came up with the idea of removing all the properties, and storing a ref in a table, then one by one re-add all the properties in their categories.
as opposed to the smarter way that o1 gave of just giving one category more priority ๐ฟ
yup. they tell you some crazy things sometimes
and they often get stuck in a thought process if youre already on a track
and wont suggest other possibilities
Thank you. I'll check it out when i get home. some quick skimming showed some interesting ideas if i can get them to work (such as grouping)
but wtf are those gifs? lol
i can't tell for shit what's going on in any of them
the first one shows how adding a meta category to a property filters the list
the second one shows how you can change how properties are presented through the ForceInlineRow metadata
third one shows changing the edit conditions
and the fourth one is about adding custom metadata tags for your properties
the second one shows how you can change how properties are presented through the ForceInlineRow metadata
ohh now i see that's neat
and the fourth one is about adding custom metadata tags for your properties
This could be really helpful
Could pair with something like a save system where it auto saves / loads values
just by adding a metadata tag to the property.
i use metadata in my dialouge system now, but since i don't know of a way to do that in BP, it was only useful in CPP
very interesting 
yeah i think if you do some manual config loads and saves, changes to the metadata values outside of the presets you hardcode in the macro itself will be saved into the config
well i think it may have been right about metadata. you can do it during runtime but you cant save it without manually adding it to a config or some setting you save somewhere.
alright i did it. i also made it so the Reset to Defaults skips disabled properties
man i thought i was done again, but i spent all day optimizing little things
The last 20% is 80% of the work
is there a way to adjust and find perfect padding value without compiling everytime ?
i set it to something and then i paste a screenshot into photoshop and measure how many more/less pixels i want to move it 
I feel the pain. Nice hack btw
you could do a mockup in UMG
I use paint!
Paint is the best.
i want to draw a slashed line for a use case like displaying 3/4 ... like a square box with a diagonal line going from corner to corner. what do best?
inside an SBox / SOverlay
Override OnPaint?
first time! i guess i was trying to figure out if there was anything like SLine. so i guess i could make my own SLine and use OnPaint to draw whatever i want? interesting
I think you'd need to use draw the individual line segments. Super simple, just a pain to set up.
after much deliberation i have decided that i am a lazy idiot and i am just going to draw a stupid image brush containing a diagonal line
๐
another Q... i have a horizontal box, it contains one or more things on the left, then a blank spacer in the middle that shrinks, and one thing on the right.
what sort of options might i have to elegantly handle cases where the things on the left grow too big? as in ways to cut them off so they don't do this
i think if you set it to wrap maybe, but then itll go to the next line.
maybe if you put that part of the widget into a side-scrolling widget, and then you disable side-scrolling.
something like that might do trick 
heyy congrats on finishing and submitting ๐ค๐ฝ
i think SBox has clipping
that should hide any content that extends past it's bounds
hey thanks, i actually just got a scroll view working and... it's better behaving than i thought it would be, yay
might be nice to have it functional and hide the scrollbar too
yep! https://gyazo.com/06d946ef82d97a266a7c558f5502ef37.mp4 thanks theos too of course
yup! looks beautiful ๐
looking good bro, glad my advice workes
Wtf. They told me to use file share to upload my plugin for review and apparently the share link is asking for access and so they denied it. Guess I gotta figure out what that means and try again
You need to either provide a link that anyone can access or one that is password protected and provide the password, you can't set it up as a 'share by invite' kinda thing.
I thought it would be one that everyone could access. I didn't change the settings at all or make a requirement. I made an account, uploaded the file, and clicked the "share download link" button below my uploaded file.
I guess I'll have to check again
oh ic, the share link brings me to the filesharing website, that then asks for a login
the download link is just this tho : undefined/download/vq0EMawJobO3vSaVpmft
how the heck do i use that
I'd use a better file sharing website.
that was what they recommended, but i guess i will. idk why they would tell me to use a website they explicitly cant work with
Google drive should work fine?
im trying dropbox. the link i made there works in an incognito tab so that should be fine. they arent letting me update my listing tho....
guess i have to redo it all
this is so dumb
Good old big corps
Anybody can tell me the name of the slate widget the editor uses for arrays? I have an array of static meshes and I want to replace its widget in a property customization with a similar list except the asset pickers for the static meshes use another widget instead
widget reflector isn't super clear on it
It'll be private in the property editor module.
yeah I ended up finding it, I managed to correctly spawn parts of the widget like the header with the + and trash button but have trouble spawning a widget for every entry inside the list "group" & have it update when an entry is added/removed, wish they'd just made a "ListPropertyEditor" widget or smth that handles it all automatically
i listed my plugin under all 5.0+ versions, but apparently you need to submit a different file for each version, even though the one i sent in should work for all of them. i was too lazy to actually test each version so i just resubmitted with only 5.4
Hi. Retainer Box makes everything inside blurry. How to fix this?
Got a link to the release page?
Plugin was sent back for review, so we will see. I feel like it'll be rejected again for some stupid reason and I'll have to resubmit a fourth time. I'll keep you updated when it's up
Marketplace reviews are said to be very slow right now, when I submitted a plugin a month ago it took it just two days to be rejected for an unfair reason 
Yup. Took 2 days my first submission, 3 days or so for my next one where they kindly told me that they could review my 5.4 version because I submitted that one, but they decided not to until I removed the other version numbers from the listing or gave them more copies of it. And then I forgot to resubmit for a day, so that was a day wasted where they could have reviewed my version.
Idk if it was always like this or just the new FAB thing
im surprised they are reviewing new submissions at all. i have a plugin where the dev is claiming the UE devs aren't allowing new updates until FAB is out
how true that is 
Alright, creating a combobox for a struct's PropertyTypeCustomization was a mission.
you're done already???
all because unreal refuses to add the ability to do GetOptions directly on structs ๐ฟ
hiking up to mt everest woulda been faster at this point. lol
The label gets updated to the appropriate options whenever Script is changed
oh yeah thatlooks ilke 2 or 3 weeks of work right there, good job
me, on month 6 of writing a small custom graph node
I thought it'd be an easy few lines of code. not almost 100 ๐ฟ
dude those are a pain lol. I made a whole quest system using a custom graph. and so far have ended up not using it
took a whole month to get there too
no FlowGraph? 
no flow graph.
because i wanted it to be a asset builder rather than a execution graph(?)
so basically when it saves, it traverses the nodes / tree and creates the asset.
an asset that builds assets? o_O 2meta4me, grood job if it works though ๐
fab came out on the 8th i think?
lmao. yeah each of those objectives has a nested graph for the individual tasks. it works fine, but it's kind of pain to use. hard to see what's going on, since i have to keep openening the subgraphs, and going back to parent
the new one I'm working on is less flashy, but seems to do a decent job representing the quest
it's already out? i thought the marketplace would get completely replaced by fab
i think its a slow phase-out. new things cant be put on marketplace anymore, and old plugins will still be accessible from there for a while
your thing is looking awesome
thanks ๐ the damn combo box alone took like 2 hrs ๐ฟ
but it correctly now parses labels from my dialogue system so that's neat
AI helped for damn sure. I'm way too dumb to have done it the correct way. unreal source code is just so damn dense, that finding non convoluted examples to pull apart for slate isn't trivial
ikr! my big problem is that it often looks like there are multiple things i could be using to do the job, but none seem to do it how i imagine or theres some bit of code i dont understand so it doesnt click, and i get so distracted going through the methods of every goddamn class i can find, and everything that seems even tangentially related.
turns out at after many hours, its like 2 lines of code or something that i need
I'm also sure I shouldn't be creating a whole new object, loading it, parsing it, just to get the string array options everytime i want to update the combobox options.
hacky at best. but it's only for editor so i don't care about performance
fr! in the end it's quite simple to create and often the final code does seem practical. but yeah, given the lack of documentation on this side of unreal it's damn hard to get there.
like, daekesh told me like 3 separate times to use a DetailCustomization for my plugin, and that i had to register it and i just went on a wild goose chase
turns out it makes a lot of sense and is easy to do
but i just couldnt figure out simple instructions
i feel that. i think every part of my plugins so far I've dealt with that. once i figure it out, re-reading the little bits of documentation i had originally found seem to suddenly make a lot more sense. lol
yeah. i have a codebase of random and useless class methods floating around in my head now that i saw during research. at least it makes me explore
need to add a few more properties and I'm done with this part of it. this whole journey has come a LONG way
From standard unreal tree (red and green lines added in photoshop to show subtrees)
"Ana's Interesting label" is putting a lot of expectations on whoever is supposed to overwrite that
can't get more interesting than that
this actually looks so good tho. im jealous
thank you โค๏ธ
make shitty ui details customizations for the next year and you too can produce works of art like this within mere months

(i love slate)
we all love slate. no sarcasm here no sir!
yeah slate isn't too bad. it's definitely getting easier.
i did prototype this in the regular editor widget before bringing it over to slate. was hoping that with slate i'd fix the details rendering bug, but nope. had to hack that too
once you actually get comfortable with it you really do feel like a boss
adding that checkbox next to all my properties was very cool
it does feel pretty good when you start getting it
RIP to whoever decides to create their whole game ui in slate
also no UMG wrapper for SSplitter is a sin
for real. i actually saw a project that did that and i decided to take a look at it and maybe attempt my own, and i gave up on that after a couple days. the things you can do in UMG by just being able to move things in visual space and layering widgets and making configurations is just so much easier.
and with the ability to write out all the logic in C++ with BindWidget, makes it a dream honestly
(and if you have angelscript it's ever neat'er)
Hello, I'm trying to use some paint functions within UMG, but it's rather a Slate question, so I'm dropping it here. So, I'm drawing a little graph, but it draws in the top left corner of the widget. Is there any ability to shift the whole thing without affecting the points I'm feeding in the MakeLines? I obviously could iterate through every single point, and add some offset, but I wonder whether it's possible to affect all of them without changing them on the computational step.
make a child widget that is the actual graph surface and draw within the context of it instead?
Is it possible to center a text drawn using FSlateDrawElement::MakeText? I usually would get the size of the final text, and shift it by half of the widget, but I can't get the size of the text at any point
I got a graph like that, so I have many text entries
i find that for most things regarding positioning, you want to wrap your widgets in panel widgets, that all have alignment options. using a horizontal/verticle box or a grid panel will give you some options. boxes seem to override top level size box overrides tho if you arent using fill
im not sure about Draw elements, but if you put an element within a border or other container and put that in a panel, or just go straight to panel then you can align the panel
and the draw will go with it
its been 2 days since my last submission. how hard is it to see if my plugin works? i tested it myself a little by just moving the plugin into the engine's plugins folder and opening a different project from the one i created the plugin in and it worked immediately on adding it. i made sure all the filepaths and stuff were relative to the plugin and not absolute and its like 3 classes total.
and since i only have the one version its not like they have to test it for every version. besides testing it on mac and linux which should maybe take an extra 20 minutes, idk what else they would need.
im frustrated by bureaucracy!
@fluid jewel i was doing research for other topics, and im sure you know a lot of this information already, but it looked like something you might run into or may want to use for your project so i thought id share it.
https://benui.ca/unreal/tmap-same-row/
sweet. actually had no idea about forceinlinerow
yeah, and the other method is basically what i had done in my project, overwriting the base slate widget display for things, and then recreating it with modifications
removing the extra reset to defaults button part was neat too.
also very briefly considered this
you can mod tf outa that header. added an image in there
expanded:
right now the only thing I'm battiling with is the fact that for some reason the header has a splitter that's cutting off my text if the splitter gets too small
It's really clunky but the only way I figured out how to accurately position text elements was rather convoluted, there's a slate font measuring service thing you use and it returns the actual size of the string on screen, then you can offset the paint geometry by half the height/width to get it to draw centered, I used this to use ttf fonts for mouse cursors, here's the code for the font measurement thing - https://github.com/Amir-BK/unDAW/blob/8d40ac091490ce7138fe36d84b25095117a4632e/Source/BKMusicWidgets/Private/BKMusicWidgets.cpp#L18
And also creating offset paint geometry and then calling the OnPaint event for the widget passing this geometry (and potentially a clipping rect) is how to draw lines and stuff within a subwidget without needing to calculate the offset with the draw calls.
I also used the font measuring thingie to paint notes using musical true type fonts (SMUFL) on the correct position on the staff, it was impossible without it, spent a long time trying to figure that out, and then abandoned that whole endeavor.
if you dont use the CategoryRow->AddPropertyName() and AddPropertyValue() functions to replicate default slate formatting then the splitter wont appear i think.
idk exactly what youre referring to because its not in the image, but if its that splitter, then thats how you remove it
oh i found a picture higher up that has a larger screenshot, but without the special header. this splitter will be removed if you dont use the property functions
or if you make a CustomRow
youll have to manually justify the header text though, and alter the font to match the default slate font size, which i think is 8
this double expansion arrow thing is interesting. you can probably remove that by copying what benUI did in the earlier link
there might be some way to disable the second one
tho i think that might also be solved if you remove the default slate property slots
Hmm. Iโll have to play around with it. I tried just using either name content or value content and couldnโt get it to get rid of the header.
Not on atm to test but I may @ you later.
I was under the impression you needed to use the header that was passed in, and that the splitter was built in.
if you want to have unreal engine do some of the layout work for you, then yes, you need to use the Propery slot functions, but if you make a customrow or dont include those, then slate will ignore it because it has nothing to do with it anymore
youll have to do a bit more work to implement it from scratch
ah i got the function name wrong. the Property Content ones
it might actually be this though. it says here "shown in the default way to the category"
if you build the widget yourself without trying to use premade UPROPERTY() defined properties, then youll not have the splitter
this may be an option as well. idk what exactly it means
Thank you very much. Got it working like this
static FVector2f GetNumberTextSize(const FSlateFontInfo& Font, FString Text)
{
const auto FontMeasureService = FSlateApplication::Get().GetRenderer()->GetFontMeasureService();
const FVector2f ReturnValue = FontMeasureService->Measure(Text, Font);
return ReturnValue;
}
I got another little problem with my graph. When I unzoom the designer, the lines scale up accordingly. Is there a way to make it consistent?
Edit: setting PaintGeometry.DrawScale to 1 seems to fix it. It's weird since the property comment screams that it's deprecated, but says that it should affect the thickness nevertheless. I wonder what would be the correct way of doing that
umg has a ScaleBox, so i suspect there is an SWidget of the same name. it keeps it's contents the same relative size
sorry I'm confused. is this for customizing the details?
for CustomizeHeader it passes in the HeaderRow row object
the first arrow is to expand the details
the second one is to show the insert / delete / duplicate menu
SBox I think is the equivalent.

oh i don't need to use the name and content slots as you mentioned.
I can just add the content i want as a child
sorry. my pea brain couldn't 'comprehend
SScrollBox - lovely smooth scroll functionality, works with mouse wheel, does not work well with an editable text box (because you keep typing and it doesn't follow the text)
SMultiLineEditableTextBox - crap scroll function, does not work with mouse wheel, lovely editable text functionality (scrolls to follow the text cursor as you type)
can i just put these two into a room with some wine and a good movie and wait until they combine for me 
I got it to work for both scrolling down as you type and with the wheel
+ SVerticalBox::Slot()
.HAlign(HAlign_Left)
.AutoHeight()
[
SNew(SScrollBox)
+ SScrollBox::Slot()
[
SNew(SBox)
.HeightOverride(48)
.WidthOverride(200)
[
SNew(SMultiLineEditableTextBox)
]
]
]
unless i midunderstood the assignment
maybe down works, i'm doing both width and height though
ah width too. apologies
upon further testing width works too. again maybe i misunerstand the assignment here
oh, right. those scrollbars are not the scrollbox, they are of the text box
i am basically whining that the text box doesn't have smooth scrolling
ah i see. i smoothbrained afterall.
not really
the smooth scroll is just so nice tho ๐ฅน https://gyazo.com/3f90f2366b18c600e2e442a975f719ef.mp4 next month i will pack 7 days rations and embark on a journey to make my own text box with smooth scroll
bleh, fps is too low lol
whata. that looks so good
i remember reading you were working on a flowgraph dialogue plugin. from the looks of it, it's lookin real good
pretty happy with it yeah. generally functional on the backend too by now, just finding the rough edges and missing edge cases for things https://gyazo.com/e8c2f46cad1d88beebcf737350833e53.mp4
what plugin or blueprint is this? looks nice
speech nodes are almost entirely custom but it's running in Flow Graph plugin
nice, can i find it on marketplace?
MIT but i think at my current pace (dad of toddlers) it's at least a month maybe two away from being worth pulling and looking at https://github.com/HomerJohnston/UE-FlowYap
nice!
screw it i'll force the two of you dumb widgets to coexist https://gyazo.com/b18288cae0e40e1975b7eff653123f56.mp4
I need someone to make a plugin that transforms a UMG widget blueprint into swidget. If you have a blueprint that is a Border with a nested Button and some customizations on each, it will read the values of the widgets in order, and generate an SWidget hierarchy using the equivalent swidget components while keeping your colors/transformations/alignments etc.
You'll end up with slate code you can copy paste somewhere else and it will work
no. you will suffer just like the rest of us. be thankful that we have live coding
I'll need to actually look into enabling that. Currently I've not been using it
hint: SMultiLineEditableTextBox isn't localized :\ [I mean, it is, but the widget doesn't give you the localization settings]
STextPropertyEditableTextBox is used for properly editing localized FText... but the default implementation isn't very well suited for generic use, it doesn't scale vertically to fit its parent nice. i copy pasted it into my own class and modified it a bit
also it needs a helper class IEditableTextProperty which has no generic public variants, you have to make one yourself. a private one exists tailored for details customizations FEditableTextPropertyHandle which can be copied into your own, or you can make one from scratch
and where were they gonna tell me this requirement?
i mean, i guess they are telling me now
but how the hell am i supposed to know this specific URL i need before they fail my submission?
i only failed 2 parts of this never-before-seen-or-provided checklist, so theoretically my next submission should succeed
What does "removed explicitly" mean in this context:
UWidget::RemoveFromParent() called on '/Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap:UMG_CupcakeContainer_C_1' which has no UMG parent (if it was added directly to a native Slate widget via TakeWidget() then it must be removed explicitly rather than via RemoveFromParent())
I think that warning is made here, but I don't see a function on the MyDockTab to remove it explicity. I'm replacing it by setting it's content MyDockTab->SetContent(MyCupcakeContainerWidget->TakeWidget())
// Clean up the previous widget instance if it exists
if (MyCupcakeContainerWidget)
{
if (MyCupcakeContainerWidget->IsValidLowLevel())
{
MyCupcakeContainerWidget->RemoveFromParent();
MyCupcakeContainerWidget = nullptr;
}
}
It probably means it needs to be removed directly from its parent using the slate widget, not the umg one.
Hmm... Ok, I replaced it with MyDockTab->ClearContent(). I'm still getting this error. I'm making a plugin, with a slate tab that loads a UMG component.
When I try to save a level as a new level, I'm getting this error:
Error LogLoad Old World /Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap not cleaned up by GC! Object World /Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap is being referenced by UMG_CupcakeContainer_C /Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap:UMG_CupcakeContainer_C_2:
Error LogLoad (root) GCObjectReferencer /Engine/Transient.GCObjectReferencer_0
Error LogLoad -> SObjectWidget(UMG_CupcakeContainer_C_2)::AddReferencedObjects( UMG_CupcakeContainer_C /Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap:UMG_CupcakeContainer_C_2)
Error LogLoad ^ UnknownFunction []
(repeated many times)
Error LogLoad ^ UnknownFunction []
Error LogLoad -> UObject* UObject::Outer = World /Game/FirstPerson/Maps/FirstPersonMap.FirstPersonMap
Error LogLoad ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error LogLoad ^ This reference is preventing the old World from being GC'd ^
CupcakeContainer doesn't reference the World in it's subclass methods. It manages some listviews and has a tick.
Any ideas on what to do?
Can I deinitialize CupcakeContainer once I know I'm done with it?
I don't think I am in my code. I think it's something under the covers.
Here's my cleanup code:
// Clean up the previous widget instance if it exists
if (MyCupcakeContainerWidget)
{
if (MyCupcakeContainerWidget->IsValidLowLevel())
{
//MyCupcakeContainerWidget->RemoveFromParent(); // Logs warning
MyDockTab->ClearContent();
MyCupcakeContainerWidget->Rename(nullptr, GEditor->GetEditorWorldContext().World());
MyCupcakeContainerWidget = nullptr;
}
}
Now I'm getting this warning for every subwidget in the UMG form (see .txt file)
FirstPersonMap is being referenced by UMG_CupcakeContainer_C
Why is the widget owned by the world?
Good question.
It's a UMG widget that lives in a slate tab. That tab is opened by a button in the editor.
I need a world for the UMG widget, so I was trying this:
if (bHasPie)
{
World = GEditor->PlayWorld;
}
else
{
World = GEditor->GetEditorWorldContext().World();
That all worked great until I tried to save/create a level and now it's having this problem unloading the previous level.
The UMG widget is for watching debug values during PIE and making debug draws.
What's Blutility?
Is this also called "Editor Utility Widget"?
They got to be working by the hour. One fail at a time until you finally meet all their requirements
Maybe? I've never made one.
I do everything in slate
Fair enough, thanks for the tip. I built this whole UI using UMG. It was all working till I tried to save a level. ๐
There's a core delegate that triggers when a map is unloaded (or saved maybe?) You could try using that to destroy the widget or whatever.
When you save a level to a new location (new map or rename) it technically unloads and reloads the map internally.
When I started, I thought of putting the container in an empty world.
Editor Utility Widget's look like they support most of what I need and would be more stable.
Lastly, there's this, whatever it does:
https://dev.epicgames.com/documentation/en-us/unreal-engine/BlueprintAPI/EditorScripting/ContentBrowser/ConverttoEditorUtilityWidget?application_version=5.5
The adventure continues, thanks for the help!
Convert to Editor Utility Widget
Np!
maybe i'm crazy but i've made some global/extern structs that hold all my style FNames and i wrapped the normal Set("StyleName", data) calls in a macro so that i have NO MORE STUPID HUNT AND PECK FOR STYLE STRING NAMES!!!
// GOODBYE ANNOYING STYLE NAME STRING
// Set("ImageBrush_Icon_AudioTime", new IMAGE_BRUSH("DialogueNodeIcons/AudioTime", FVector2f(16)));
YAP_DEFINE_IMAGEBRUSH(ImageBrush_Icon_AudioTime, "DialogueNodeIcons/AudioTime", (16, 16));```
```cpp
SNew(SImage)
// GOODBYE ANNOYING STYLE NAME STRING
//.Image(FYapEditorStyle::GetImageBrush("ImageBrush_Icons_AudioTime"))
.Image(FYapEditorStyle::GetImageBrush(YapStyles.ImageBrush_Icon_AudioTime))```
That's cool
Does anyone see STextBlock like this? I applied a strike brush to those, and this started to happen randomly.
Whether this phenomenon will occur or not seems determined when the editor is run, in my guess. Once this phenomenon occurs, it persists until the editor is closed. If I just close and open a window or tab that has this phenomenon, it still exists.
This phenomenon disappears if I remove the STextBlock with the strike brush from the code through hot reload, and close and open again the window or tab that had STextBlock (to remake slate). But, after that, if I add STextBlock again with the strike brush through hot reload, close, and open that window or tab again, this phenomenon happens again.
What I see is a font drawing error. Something in the font is drawing individual letters incorrectly. Have you tried changing the font? I see glyphs in the tab titles. Have you tried changing the editor to English?
Oh, I will try that right now:D!!!
Ah... Same. It still happened again when I changed the editor's language to English.
I made the smallest project to reproduce this problem. After some moment, I think that I can upload to github this.
I uploaded. You can see this in here: https://github.com/hyaniner/UnrealSTextBlockBrokenWithStrikeBrush/
i've never used strike brush, is it a strikeout ---- effect? kinda looks like the strike brush is using a whole-ass texture atlas lol
but also clearly not scaling correct
~~You can use the strike here with tilda ~~ ~~Some Text~~ I'm also considering physical damage to my graphics card as a possible scenario, but it seems unlikely that the graphics card would only react when I use the certain brush as strike line. But worry is still worry to me. So I hope somebody test that project I uploaded.
what is Old/Border supposed to be?
looks like thats a starship style border brush. are you meant to use border brushes for the strikeout?
idk, try using a normal FSlateBrush rather than an FSlateBorderBrush
Thank you for your reply. Old/Border is just a test brush that I found from the editor of the engine. There is no need to use that brush for me. But I want to know why that happens so I want to be ready for a similar situation in the future.
well, besides you using a SlateBorderBrush instead of a SlateBrush, i cant see any issues, though i havent actually downloaded the project myself and done any testing.
other places in the code that use a strikethrough all use FSlateBrushes
so, try switching that out, and if that doesnt work youre gonna have to think of something else
Thank you very much. I will test that.
I changed FSlateBorderBrush to FSlateBrush, and that phenomenon does not appear anymore. I'm glad to solve my worry. Thank you! It seems that I was confused after I saw the usage of the "Old/HyperlinkUnderline.png" as the hyperlink underline brush with the SetHovered(). I thought I had to use the FSlateBorderBrush for the underline and strikethrough.
glad it worked out! that was a hail mary suggestion.
What the hell. It works just fine on my computer
Something that works for me fails to compile for them??
Took 6 days for them to try my plugin.
fmargin::fmargin 
Hey, works for me
yeah, works fine here too (but... why :D)
Because I don't know what the heck im doing most of the time. If something works I don't rly question it
is this the widget help? I am having an issue, something in my VR headset is triggering on hovered events, how can I use this node to figure out what is causing the event?
its the button but how can I make it so it tells me what is causing the event
You can look in the logs to see wherever it's triggered
Make some debugging print statements
You could also create an event viewer of some sort
yeah but if I dont know whats causing it
Well, you're not giving me a lot of information to work on. First step to finding what could cause it to trigger, is to know what is being triggered
It seems to be named slot browser, under the parent class base radial. Idk what either of those things are meant to be
im just using the widget as an exmple trying to see if there is a way that when its hovered whats hovering it
Presumably your cursor
Is there anything other than your cursor that could "hover" it?
I think there is some hit testing methods that widgets have, and will know what actor interacted with it. You could try that
You may have to cast to an actor you think it might be, and then check for equality
but now what?
Don't put it on preconstruct. Put it on begin play.
Check if that thing you casted to is the thing that you get a hit test with or is within the bounds of your widget when it's hovered and print the result
True or false
what node do I use
Idk. I haven't done much blueprint work. Try looking for things like "hit test" or "debug"
Or collision
AI could be wrong so take it with a grain of salt. Probably true tho
Sounds right
is a widget interaction the only thing that cant trigger a button on hovered event?
depends on how you code it. if you have a 3D button in your game that interacts with multiple objects and is not UI, you could very well have things that "hover" over it. if you make a button count as hovered when a player stands on it, then that would count.
i dont know of any default way you would get a hovered action without specifically coding it in. maybe VR is different, i dont know how VR works
anyone know what this is?
mission impossible: given a simple instanced UObject, figure out how to spawn a slate widget of its property panel on my graph when i click on a label representing this UObject
this is all probably going to be locked behind stupid private editor widgets isn't it...
looks like microsoft telling microsoft that microsoft's package has a vulnerability
probably ignore unless you are making your project into a web server or something
surprise surprise
System.Security.Cryptography.Cose, System.IO.Packaging, Microsoft.Extensions.Caching.Memory may be exposed to a hostile input which may lead them to be susceptible to hash flooding attacks resulting in denial of service.
https://github.com/advisories/GHSA-qj66-m88j-hmgj
- it's possible, I did it, it's clunky, but basically just have some TArray<UObject> property in the object whose properties you're displaying, in my case the easy solution was to customize the details of my graph object and add a property TArray for SelectedNodes, just updating this array based on your selection from the grpah will do the trick.
- This is not the elegant way to do it, there is build in unreal way to let a details/property viewer receive an array of objects to customize, this has many advantages as it also automatically groups their properties and lets you edit them together (same as how the editor does it), depenending on the usecase this might be needed. either way when you have a referene to a details viewer you can just pass a UObjecet to it
That's the select node in the Asset Editor toolkit class, you can see the ugliness as I'm actually manipulating the TArray in the graph uobject directly
hmm, what i'm hoping to do is make the details panel irrelevant - i want to display the UObject's properties in a floating widget on my graph. i'm not sure if that's what you're saying you did or not?
(thanks for the reply!)
oh wait maybe i understand - are you "selecting" the instanced uobjects and then the details panel just... displays those objects?
darn, UEdGraph / FlowGraph is more locked down than this, i've never used FAssetEditorToolkit before
yeah, it monitors the TArray property, I'm selecting the nodes, the nodes are either UObject themselves or otherwise 'display' some uobject or struct, so you can collect those once you have the array of selected nodes, and then just pass it to whichever object it is whose details you display, and that's it
This is an EdGraph
flow graph also has an asset editor toolkit somewhere, it has similar functionality for selection
I'm pretty sure you can find an 'on nodes selected' method in the main asset editor class for flow, in the editor module
i very roughly see how this might work. but seems like it would require me to override the whole details panel. i suppose i could control that... but is hacky for sure. i'll waste a bunch of my life looking for other options first, but thanks for at least Plan B ๐
Not really, it will only require you to add a TArray with UPROPERTY(VisibleAnywhere) in it, really.
This is the hacky simple route
Like this, the uproperty in my graph object, this is what actually displays the selected nodes (or actually their underlying 'vertex' UObjects), - https://github.com/Amir-BK/unDAW/blob/8d40ac091490ce7138fe36d84b25095117a4632e/Source/BKEditorUtilities/Public/M2SoundEdGraphSchema.h#L74
do you happen to have a screenshot of this in action? just wondering if i'm still misinterpreting the result
lemme whip up the old OBS
huh, TIL win+shift+s at least in win11 can record a gif now...
ill blow your mind, win+shift+s is the same as prtscrn in win11
oof, not as long as i am a l337 gyazo user
Certainly longer than I thought it would be!
you can see it in action within the first 20 seconds or so, i go into more detail in the rest of the video
and again althoug the details class is customized here this property is actually displayed by virtue of being marked a UPROPERTY, it is not part of the ugly customizations, you can achieve this exact same result with a standard non customized detailed viewer, even in the editor properties
i used to use lightshot but in my latest install i forgot that i forgot to install it ๐
I don't trust anything other than OBS, I'd rather spend a minute settings things up then record and then see it's unusable for some reason
gotcha, thanks for taking the time!
lol, honestly I got a contract for some company redoing their widgets infrastructure and their project is all UMG and in a field that I find completly boring any excuse to open up my open source plugin project and look at c++ code sparks joy
the level of 'code' you can find in some commercial projects is shocking
the benefit of UMG is that designers can do code the drawback of UMG is that designers can do code
Yes sure the only way to notify your parent widget that you're a button that has been clicked is by getting the game instance, from there the player pawn and from it the cached referene to the HUD, always do that, in every button.
Why yes your main hud should just be 10 different widget you spawn all at once and just collapse, every change in every single one of them should directly update the state of the other widgets, even though they're never actually displayed at the same time, this won't cause any issues.
I'm sorry. had to vent.
Where are you even using this variable? Canโt you just comment out this line?
you are getting the underlying TCHAR buffer of a temporary FString. You should use FString as the type of the variable instead to cause a copy/move, but since you aren't using it at all, you can just remove it
bro. my brain is not working today
i think i might commit suicide out of embarrassment. cya
don't do it, it gets better. I'm not sure when but it does!
thanks that rly boosted my spirits. i wont do it
ill do it tomorrow
i need daily positive affirmations
procrastinate, I like it
gotta love c++ errors
now i gotta wait another week to get this shit on the market
tbf it's a gnarly bug if you were to use it
I was mega depressed yesterday, I apologize for my comments
I'm trying to get a CommonUI CommonButtonBase widget to use input but not consume it (it should still propagate). Pretty much done everything I can think of or search for: all variables tested, overridden all functions that return FReply and set to Unhandled, etc. The BP events MouseDown don't seem to fire, but the widget responds to those visually, which makes me think that the underlying slate stuff is consuming the input.
More broadly: How do I set my UI so that it responds to input but does not block it from propagating?
I don't necessarily want click through - specifically I want the EnhancedInputSystem to be able to listen to and respond to onclicks even if a button is being clicked on.
So I don't know common UI at all and didn't wanna give bad comments, but no one else has responded so I'll give my thoughts.
In the normal enhanced input system, inputs have a check box that says "Consume Inputs", and I believe if you turn that off you can make w click interact with multiple things
There should be methods somewhere that can manipulate whether it consumes or not
Yeah, I've explored all those simple solutions. Thanks for mentioning it though, you never know when I've missed something. The issue is also not with EIS consuming inputs, but rather CommonButtonBase/Slate consuming them.
Hey all!
Is it possible in slate to inherit SLATE_ARGUMENTs?
Or a simple way to pass those into child widgets?
I have about 8 widgets that all inherit from a base widget that holds similar info, as they are all controllers for an audio plugin I'm working on.
They all have the same delegate that needs to be broadcasted when updated that is bound to the same function eventually.
Right now when I have to include a SLATE_EVENT(FOnBusUpdated, OnBusUpdated) in all 8 widgets as an argument, then assign that in the Construct function.
Is there any way to only do this once in the base class?
You can do it like that #slate message
I would still have to include that in every widget though yea?
I mean, it depends on what you're trying to do, really, you can have a slate_argument(ParentsArgs) or something which you expose to whoever's creating the widget, or you can create a parent arguments struct in the widgets constructor event and just intiialize it with values. You can also have the delegate as a member and just bind to it from the calling widget.
That whole pattern of passing in the delegate is a very UMG facing thing that thinks about a usecase where a designer might want to completly intercept the functionality of some slate widget, in slate only widgets passing in the event as an argument is often just overkill.
I also got confused by this pattern a whole bunch of times, a slate widget can just have member delegates, you can just bind to them after having created it
oh my shitting asshole
man why do i not double check things
i have the comma in my thing, for some reason it didnt export it
I'm confused because they keep sending you "won't compile" errors - surely you didn't just send in code that you didn't compile??
Did you do the local 'package plugin' thingie first? you don't explicitly have to but it gives a good indication on whether you're going to pass the marketplace checks for all your allowlist platforms
What's the best way to get a specific property picker into a simple VerticalBox of a Compound Widget? I have a list of a few buttons that can do something, one has an SPathPicker above it, another one shuld have a property selection for a FPrimaryAssetType.
I haven't touched Slate in a while and usually have UObjects with DetailsViews, or Structs with Customizations, but I don't really want to do that if I don't have to.
The property can just live in my Widget.
PropertyEditor seems to work. Can ask it to create a Structure DetailsView, passing in the UStruct and the actual struct param. Seems to work fine.
the first few times i made sure to test each iteration. one of them i just had to add a line to my .uplugin file, and i didnt go and repackage the plugin, i just added the line to my original copy and the packaged plugin, both of which had a , and appropriate syntax. i sent that back in, and they gave me a different compilation error which i fixed, and at some point i lost that comma in my .uplugin. idk where it went or what i messed up. i didnt bother recompiling and repackaging it because i thought it was all correct. the copy should match my original perfectly.
what potentially happened is that im dumb. i have 2 copies actually. i have the plugin i made locally in the original project, stored in the project's plugins folder. i made my original package, which i tested by moving it into my UE_5 engine plugins folder under the Marketplace directory, to test the plugin. at one point i must have packaged the testing version and i hadnt updated it properly
i double and tripled checked the most recent one i sent in. i rebuilt the original local copy and made sure it all worked. i replaced my test copy with the local one, and rebuilt that as well. i repackaged my local copy and then double checked i had the .uplugin syntax properly written.
i made sure to delete the intermediary and binary files
there should be no problems
and all the FMargins are fixed
if this fails, im gonna hit a wall and break my hand
So you were literally making them test packaging and compilation for you? Come on lol
Lesson learned anyway I'm sure
Fun fact I just learned the hard way
Been fighting with this for a few weeks and just discovered it.
Not sure if anyone else has encountered this, but I was getting some crashes when creating a new widget on occasion, it would work in some instances but not others.
Rider had autocompleted my Construct arguments to FArguments& args when in fact it HAS to be FArguments& InArgs
It was the only widget that this happened to and the only one causing me issues.
So in case anyone else runs into this now you know ๐คทโโ๏ธ
?????
now im getting this. it builds properly but for some reason im getting an error.
i dont know whats going on
maybe because i used the packaged version without binary files and moved that into my plugins folder. it builds but wont run
well. i didnt think that would happen. lets hope thats not a problem with my submission
i made a chat system!!!
its kinda trash right now. ill work on it more! i think it should be able to work multiplayer, but i only have the one right now and idk how to make a second. ill figure out how to test that.
I'm a bit new to using slate: i've seen the startship suite but i was wondering if theres at least any good way to prototype quickly what something might look like in editor without recompiling. If not that makes sense.
Id also love to know if there's a good guide out there or blog post aside from the Compendium one and the general UE examples. I'm just trying to make some details panels edits for a plugin i've been developing, ive got the basics of setting up customization, but the actual developing of the panels feels... daunting
im suprised to hear livecoding works at all
this may look like UMG, and it kinda is, but i used STextBlocks for the actual messages because working with the UMG widget tree and stuff is cancer, so instead im mixing umg and slate
and therefor i can post about it here mwaahahaha
Another thing you could do maybe is make a slate widget style with all the variables you want to change baked into it, and then make a blueprint class inherited from that. Then you can make an SWidget that uses that blueprint as it's style (need to get the path for the blueprint you made I think), and fiddle with the values
You may have to manually call RebuildWidget each time you make a change, I'm not sure if the widget will refresh automatically
Use an SButton as your test widget and tie its On_Clicked functionality to the rebuild widget method
Then you can click the button to refresh it!
Or, if you add Mainframe to your modules you can use some method there to refresh all the slate resources the program uses. It will close all your slate tabs, including the main window. You can save the window layout with another method, so it will reopen the tabs you were using
That should let you alter your slate in semi-realtime
It does take a couple seconds to refresh your windows
I have an example of the exact methods to use, I can show you when I get back to my PC soon
i think you only need the SaveAllVisualState() and the MainFrameModule parts
you might actually only need the force refresh details part, but that might only be for a DetailsCustomization
I actually chatted with Ari at UEFest about live coding after his talk cause I practically never use it. Apparently if all your code is in c++ it works fantastic and there's not really a concern to not use it. But the problem is when you have a BP class that's a child of a c++ class and you mess with the header file it causes issues.
But I've been using it with slate the last few weeks and has been a huge time saver
? it's worked very well for like 3 years now, just learn its limits though - turn off reinstancing, only use it for .cpp changes
i even have it unload and reload my custom slate style set right now... it's "dangerous" because if i leave my editor window open during it it will crash (as the style sets get destroyed while the editor window is still rendering) but it's fantastic being able to add new brushes and fonts and implement them all with only just closing the asset window and reopening it after it finishes
as for your actual question... yeah, it's rough. hardest thing for me was getting my brain fully wrapped around valign/halign/autowidth/autoheight stuff to the point that i could actually know what the junk i'm writing is going to do
I have a selection list and an editor panel in one of my toolkit's modes. I want the editor panel to listen for the selected item on the list (which I know how to do, just delegates) but how can I get the selection list from the editor panel widget?
As you can see, both of the components of the editor here are seperate tabs in a toolkit mode. So should I be storing the widgets in these tabs as tsharedptr in the toolkit mode itself? What if the user closes one of the tabs and it is lost? How would I fix it upon the tab being reopened?
couple ways to do it... you can go up the hierarchy until you're at a common point that both things know about... maybe the top level window should have the delegate event instead? the selection list tells the window when it changes an item and the window broadcasts that down to subscribers
Sure, I'll try that
MY PLUGIN GOT ACCEPTED.
its apparently now Live on Fab.com, though i have no idea how to actually get the link to it. i dont know if Fab is fully up yet, but im guessing its not. so while my plugin is live, i have no link to it
all it says is that its launching mid-october, which should be 5 days ago, but it could be a loose window
Congrats. I actually gave up on ever trying to submit anything to the marketplace after the first rejection.
Just gotta be dogged and quintuple check your work!
In my case I made a plugin (more like 4) that use the new 'harmonix plugin' epic introduced in 5.4, which is used in fortnite and uefn for like a year now but is marked as 'experimental' in the unreal plugins menu, unbeknownst to me (as it is not written anywhere) you cannot depend on experimental plugins, even if you mark it clearly in the product description. so, like, extra checking wouldn't have helped, and also I don't deal well with rejection so I just decided not to bother, putting stuff out on github doesn't have the same rush (or the impact) but idk, it'll have to do for me, honestly having stuff out on github has already kinda paid off cause I used it instead of sending a CV on multiple occasions and actually got paid work out of it so, yay?
Yeah that sounds annoying. Thankfully my plugin is stable and uses only the core systems. I doubt it will ever be unusable.
epic's denial of the fact that this entire game engine is practically experimental level software
It should be in the uplugin.
i think maybe amir meant it's not clearly written on the marketplace terms that you can't use them, which is bushleague if true
Oh. Maybe so!
I got my current job because they found my github repos and asked if I wanted to interview.
Funny thing is contract I'm working on right now is UMG/BP and it's kinda driving me crazy, but otoh even if I added slate and cpp into the mix i'd still fight with UMG layouts and tree widgets making scrollbars act mysteriously bah
editor widgets are much more fun than this
maybe putting a list view inside a tree view isn't so smart? shouldn't the tree encompass both? bah.
I'm lost regarding this.
I've bound the delegate like this
And the delegate seems to be successfully called
but for some reason nothing bound to it gets executed
Oh, found a fix
It seemed that because I was doing MakeShared() seperately twice on the same object something was being messed up?
Sorry, I've never really done stuff where I have to manage memory (or whatever this is called) in a conscious way lol. Could someone run me through what MakeShared() actually does?
MakeShared creates a new object and assigns it to a smart pointer.
If you don't assign that smart pointer to a strong smart pointer variable, it will instantly be destroyed and destroy your new object.
E.g. SomeWeakPtr = MakeShared<...>(...); = instantly destroyed
MakeShared<...>(...); = instantly destroyed (not assigned to anything)
TSharedRef<...> MyLovelySmartPtr = MakeShared<...>(...); is acceptable. Or TSharedPtr<...>
Or a class member. Etc.
Ohh, that makes sense, for some reason I thought MakeShared just assigned a given object to a smart pointer
Nope.
@vale stump been away at a game jam. epic finally accept your plugin?
Yup! It's live!
Market isn't up yet tho
sweet. @me a link when you got one. market isn't up? I thought fab went up today
I will check when I get on, I didn't see anything about it being up
its up!!!
unfortunately, you cant find it by searching "Editor Font", only "EditorFont", so i may need to change the name to add a space there
its barely on the front page of the "Tools & Plugins" section
im not sure theres any way to boost its visibility. no one searching for a plugin that does what mine does will be able to find it.
I cant put any customizable tags on it, and you cant even search the store by tags. i cant add any search keywords...
do you guys have any suggestions for what to make the title, since its the only thing you can actually search for?
whats the first thing you would all search for if you wanted to change the font of unreal engine?
oh my god i just realized i need to resubmit the plugin actually. i made another mistake on the files
lol
so, do not get this right now. i just updated it and ill tell you when the proper files come in. if you do want it now, you can still get it but you have to make sure to manually save your default Slate fonts and overwrite the Defaults file i have in the contents folder
Bet. Picked it up ๐ But I'll wait for the update before installing it
<3333
leaning into editor theming might be an idea for tags / description
but i don't have an idea for the name
doesnt seem like description matters at all for searches. i could put theme in for a tag thats a good idea
i got a favorite font already picked out that I'd like to see in engine 
Better not be comic sans!
it''s not going to be a popular one. I'll tell you that
i can just tell you how to fix the issue without waiting for the plugin update!! @fluid jewel
go to this filepath
make a copy of the folder somewhere else
rename it to Defaults
go to this filepath + EditorFont\Content\Defaults
either replace the entire file with the copy you just made (Make sure its named "Defaults") or you can take the contents of that file and replace the contents of this file
and then you should be good to go
looks like the update went up
gracias ๐
ill take a look tomorrow. today's the last day of the game jam, so going to grind
gl
youd be my first user. feel free to tell me if theres anything thats not SUPER clear in the instructions or if you run into any bugs. i just now realize i should have added a REAME.txt, but i think it should be simple enough without that.
if you have any suggestions for features i should add, i can take a look at that as well
once i get home tonight ๐
I would recommend a couple screenshots with some fun fonts in the editor to help drive the point of what the product does. i had to read the desc a couple times, and then look at the images to really understand what the plugin did
right, i was gonna do that and then i forgot. i will make everything comic sans!!!!!!!!!!!!!!!!!!!!!!!!
and then illl make everything papyrus
just to show people what NOT to do
James cameron's Avatar strikes again
bro youve seen the skit?
skit? nope
Years after Avatar's release, there's one thing Steven (Ryan Gosling) just can't get over.
#SNL #SNLPremiere #SNL43
Subscribe to SNL:ย https://goo.gl/tUsXwM
Stream Current Full Episodes:ย http://www.nbc.com/saturday-night-live
Watch Past SNL Seasons:ย
Google Play -ย http://bit.ly/SNLGooglePlayย
iTunes -ย http://bit.ly/SNLiTunes
Follow SNL Social...
lol give me a few. I'll watch it when i get back from "lunch" doing a couple last minute for the jam. minor bugfix.
it legitimately hurts my eyes and soul
i think this image should explain pretty well, and also gives a dire warning
do you think this is explains it well?
hmm i used my original plugin font path in this picture, which wont be what most users have. i hope thats not confusing. the default should be what they see first anyway so it should be ok.
Hey everyone, the company we use for touchscreens has now switched to a new controller.
Working in linux FYI.
Before the touchscreen sent BTN_LEFT(left mouse click) The new touchscreen sends BTN_TOUCH.
This is after a bit
LogSlate: Warning: Maximum Touch Index Exceeded, 10, the maximum index allowed is 9
then unreal becomes unresponsive Only thing I can do is quit the game.
The mouse still works
Any Ideas Thanks
If I had to guess someone mixed up the 'touch down' with 'touch pressed' events.
was able to get the index. and everytime you click on the touchscreen the index goes up by 1
so it starts at 0 then keeps going up
once it hits 10 you can't recieve anything anymore
is it possibly meant to decrement on touch up?
I have no clue it just keeps counting up
obviously hard for me to debug as I don't even understand what you have access to here, but this sounds like the multitouch mechanism (which previously didn't come into play cause you were using the touch input as a cursor, probably just treating every new touch as a click event), sounds to me like 'touch up' needs to be handled somehow so that the touch index gets decremented
Yes that is correct but how can you make that happen
anyone know why this code isnt working? it doesnt properly remove the white space
FText Temp = FText::GetEmpty();
FText InputText = PlayerEntryTextBox->GetText();
// Trim leading and trailing whitespace
FString CleanedInput = InputText.ToString().TrimStartAndEnd();
// Replace multiple newlines and extra spaces within the text
CleanedInput = CleanedInput.Replace(TEXT("\n\n"), TEXT("\n"));
CleanedInput = CleanedInput.Replace(TEXT("\t"), TEXT(" ")); // replace tabs with single space
CleanedInput = CleanedInput.Replace(TEXT(" "), TEXT(" ")); // replace double spaces with single space
InputText = FText::FromString(CleanedInput);
// Check if input is now empty after cleaning
if (InputText.IsEmptyOrWhitespace()) {
PlayerEntryTextBox->SetText(Temp); // Clear whitespace if there is empty input
return;
}
// Send the cleaned message
GetPlayerState()->ServerSendChatMessage(
GetPlayerState()->GetPlayerNameCustom(),
InputText,
nChatType
);
UE_LOG(LogTemp, Warning, TEXT("Chat submitted"));
PlayerEntryTextBox->SetHintTextIfContainsText;
๐ฎ
that was quick
tho i dont rly see a difference here
besides some more cleaning
my current code still leads to blank lines
im ok with single linebreaks
i just dont want double
i think it removed double space, but didnt remove the new line
Try this
#include "Misc/Regex.h" // Include this if not already
FText Temp = FText::GetEmpty();
FText InputText = PlayerEntryTextBox->GetText();
// Convert FText to FString and trim leading and trailing whitespace
FString CleanedInput = InputText.ToString().TrimStartAndEnd();
// Use regex to replace any newlines (single or multiple) with a single space
FRegexPattern NewlinePattern(TEXT("[\n\r]+"));
FRegexMatcher Matcher(NewlinePattern, CleanedInput);
CleanedInput = Matcher.Replace(TEXT(" "));
// Replace tabs and multiple spaces with single space
CleanedInput = CleanedInput.Replace(TEXT("\t"), TEXT(" ")); // replace tabs with single space
CleanedInput = CleanedInput.Replace(TEXT(" "), TEXT(" ")); // replace double spaces with single space
// Convert cleaned string back to FText
InputText = FText::FromString(CleanedInput);
// Check if input is now empty after cleaning
if (InputText.IsEmptyOrWhitespace()) {
PlayerEntryTextBox->SetText(Temp); // Clear whitespace if there is empty input
PlayerEntryTextBox->SetHintText(FText::FromString("Type your message here...")); // Set a custom hint text
return;
}
// Send the cleaned message
GetPlayerState()->ServerSendChatMessage(
GetPlayerState()->GetPlayerNameCustom(),
InputText,
nChatType
);
UE_LOG(LogTemp, Warning, TEXT("Chat submitted"));
// Optionally, reset the hint text if needed
PlayerEntryTextBox->SetHintText(FText::FromString("Enter a message..."));
that should work, because i just learned that unreal uses carriage returns so it has to be \r\n
is there a way to make that regex only work for more than 1 line break?
nvm
@vale stump
mind if i slide into them DMs?
Nope, hit me up
i just realized that the PlayerMappableKeySettings ive been using on my project are experimental. i should switch out of using those right?
I don't know, didn't you already pass the review? If Epic said nothing they said nothing, if you're before review and it's something you can easily swap out, I mean, I personally think it's bullshit and that they let many plugins using experimental engine features pass review
different project
and its not a plugin
im just wondering if i should use anything experimental
I'd assume the "rules" are the same but otoh I never saw this listed as a rule anywhere except when my plugin got rejected so... i mean, better safe than sorry, unless the experimental feature provides great value and even in that case I'd plan for a possible swap
im not sure how i would swap this out tbh. i want to let my players remap their keybinds, which every game has, and this experimental feature just has it by default which is nice. i could maybe just....make a bunch of functions that simulates inputs instead. so i have a button mapped to a key, and if a player wants a different key, when they press it i simulate pressing the original key? that seems dumb and convoluted
ill have to do research on inputs i guess
experimental features, used in epic official sample products for years while maintaining their experimental status, go figure.
I never looked into the re-mappable keybinds plugin it's really been a part of Lyra for years, with some plugin as small as this providing limited functionality it's known that epic are fine with you cloning the module and renaming it and just comandeering the existing code for your own purposes in your own plugin, that might be a viable option.
and really, isn't a remapping plugin always going to be a list to TTuples<FInput, FInput> or whatever? I'd bet if you scratch that remapping plugin it ain't so different under the surface from what you planned to make.
thats possible. ill have to look at the source code for it
ive realized i have no idea what PlayerMappableKeySettings actually do. ive not yet setup the system that allows a player to choose their mappings, i just sort of assumed thats what it was for, but it doesnt seem to contain ANY code related to actually remapping anything
thats future me's problem i think
I think it's really just that, a data asset you can stick between the actual inputs (which the user can then configure) and the enhanced input actions.
Look at its usage in the lyra sample, it's just a smol thing.
Alright thanks. Not sure I have that sample actually, I didn't download all of them to save some space. A lot of people mention it though and even the unreal docs talk about the sample and the things in it. I should install that and look around
Lyra is a strange beast but it's the closest thing Epic ever released to a "framework to make a fortnite like game in unreal engine", it's far from complete and parts of it require some real research to figure out but it's also like a treasure trove of information and implementation examples for a variety of systems and plugins
Hi, I'm working on a UI plugin and I want to extend UListView to add new features, one of those features is autoinitialization so that code like this is not needed:
(snippet from Lyra)
FReply UGameSettingPanel::NativeOnFocusReceived(const FGeometry& InGeometry, const FFocusEvent& InFocusEvent)
{
const UCommonInputSubsystem* InputSubsystem = GetInputSubsystem();
if (InputSubsystem && InputSubsystem->GetCurrentInputType() == ECommonInputType::Gamepad)
{
if (TSharedPtr<SWidget> PrimarySlateWidget = ListView_Settings->GetCachedWidget())
{
ListView_Settings->NavigateToIndex(0);
ListView_Settings->SetSelectedIndex(0);
return FReply::Handled();
}
}
return FReply::Unhandled();
}
Problem is UListView derives from UWidget, which seems to be oblivious of focus events and only offer convenience query methods to the internal SWidget (SListViewBase in this specific case)
My question is: is there some way to implement a OnFocusReceived in my UListView-derived class without extending SListViewBase or building a UUserWidget wrapper around a UListView?
What's wrong with extending the slate widget?
Been strugglign with this a little, I have a SListView that I want to be tied to a list of structs in a struct for a property customization but it expects the data to be an array of shared pointers, does this mean you have to effectifly have two copies of the data, one in slate, one in the struct anc be copying it back to and from?
What you can do is use a reference to the data you want in some way.
E.g. you have a list of integers which are the indices of the structs in some other array.
Then in the generate widget method, you look up the data using the index.
If it's a map, you can just put the key value from the map in the list source.
Ahh yeah that could work, what would happen thn if that data was modified externally, would they not become out of sync then? What I have is an array of structs that'll be reordered and what not from slate
Then you're a bit screwed! ๐
If you're re-ordering it, when you re-order the structs, you should regenerate the widgets.
Yeah makes sense to, the idea is it's a photoshop like layer widget
I do something like that in one of the plugins I work on.
I literally have a struct which holds a reference to a material slot, so the struct has the primitive component and the slot index on it.
When things get changed, it regenerates the list.
Ah yeah, I'm just doing some basic noise and texture laying and masking for pcg
Uhh not sure, might have in passing at some point - I don't look at much stuff on the market
It's not on the mp!
If you're not looking for a texture stack in a material it won't matter ๐
Ah, I guess I haven't. I basically don't touch materials
ahhh that's why I don't see it haha - still ony 5.3
Heh
Has anyone had an issue with combobox's that you get the No Content Provided error in the main display but all the items in the list show fine?
Yes, it's the initially selected widget thingie, it's different form the list item widgets and you usually have to set it up when you init the main widget
Ah I was being dumb.. for some reason I thought it just used that same generation function for both items and content
You can do that... you just have to tell it to. ๐
Anyone know good way to create a SScrollBox without dropshadows appearing on top/bottom when list gets full and scrollwheel appears?
try looking at the scroll box style class, does it have settings for shadows?
is it possible in slate to have custom hit geometry?
I need a solution to have a cutout in a widget which won't receive focus/click events so that they go to the underlying widget
nope doesn't work
i'm returning unhandled in the MouseButtonDown and MouseButtonUp but it still catches the click
yea i thought so, too
also the underlying widget doesn't really receive focus for hovered events
maybe because they are separate widgets on the viewport and don't share a common hierarchy!?
It shouldn't matter. It should go through the stack of visible widgets under the cursor, not the widget hierarchy.
but the question remains, since even overriding the mouse button event's would mess with the focus and cancel out hover effects of underlying buttons
that gray button is on the viewport with a lower zorder while the red one is higher on the viewport
the red one masks out the area where the button is and does an point intersection check on click, which works (as i'm getting correct results with print string)
so it returns undhandled for both mouse button events, but still i can't click the button
looking through slate code it seems like it uses FGeometry which only supports boxes with transform anyways, so guess i would end up making 4 colliders which don't cover the masked out area
or i'll just do that in UMG to begin with -_-
I'm confused by your explanation. There is no geometry overlap so why would the pill button interact at all with the square button?
Have you checked your background to make sure it's not above your button and hit testable? Have you tried using a NativeWidget in UMG to nest your slate widget into?
What about if you use a border with no padding, use the TakeWidget function to get the underlying slate widget from the UMG widget, and then place your slate button inside of that. Then you can use the geometry of the border to determine click events, and in UMG it'll act like a normal widget
Is anyone aware of a slate version of USinglePropertyView? Seems for some reason the property changed delegate for that widget is protected and not public so makes it kinda of useless outside of blueprint
there was, the red area is one big square, the cutout is in the material by making that area transparent
but i've changed the setup now, and i'm using 4 borders and a spacer to leave that area blank, it's just a bit annoying that this will only ever work with rectangle cutouts
it's supposed to be an overlay which blocks other buttons
as it's for some tutorial system
only the highlighted button/element should be interactable
no, i'm not
you really think i want to crawl through all elements and disable everything and keep track of what was disabled?
you can pretty easily write some logic that does it for you
yea, seems to be viable after all, i may give it a shot
โค๏ธ
also its better to work backwards. have everything be non-hit testable, except the things you want to be clicked. put all your tutorial buttons in an array, and make a function where after one button is clicked, its disabled and the next button in your tutorial sequence is enabled.
so only 2 buttons are changing states each time. then, at the end of the tutorial you can enable all the buttons by looping over the array
i have set it up this way now but i'm still not convinved that it's the "better" approach
since the disabled visual effects may stack etc.
also every widget with custom logic onMouseButtonDown must check if it it's enabled, etc.
maybe it's good enough to disable parents and stop recursion once i hit on an already disabled widget ๐คท
I'm confused again. A disabled widget shouldn't be registering any click events
If you're using geometry boundaries and mouse button down then that might still click an arbitrary button, so instead of disabled you should make it not hit testable. I think that will remove it's physical boundary space while still being visible on screen
hm, i'll recheck that again tomorrow
If that doesn't work then you should embed a UButton or SButton within your widget that registers the clocks, and then you can set it's opacity to 0 so it doesn't affect whatever visuals you have going on, and then use it purely to capture click events
why are the UMG list views such a disaster
I don't think it's that bad in slate, something about the casting back and forth to some 'data object' and the strange pooling, I don't get it, why is it so weird
I've not dealt with list views at all yet, but I had it in my mind recently from a previous discussion about somehow jerry-rigging the default Slate UPROPERTY macro meta=(GetOptions="{custom func}") into UMG layout somehow, using Native Widget slots and maybe some magic i dont know about yet to get DetailsCustomization not only work in slate
Idk if that's at all similar to a list view, but it would be cool regardless
the list view is like an extension of the scrollbox that expects widgets implementing a user object list entry interface so that they can decouple some underlying data uobject from the actual display widgets and use however many widgets it takes to fill the screne to display potentially thousands of data items, the problems start in that it has some 'convenience' methods fro manipulating this list/tree of items, selecting them, hovering over them, expanding them, the such, and it is just, weird, like you'd scroll over the list and some of the widgets display the incorrect state because it's all weird and you have to manually fidget with when and how the display widget gets updated
it's always hours of messing around until you get it just right for me, idk. really. I'm wondering how long it'd take me to make a proper c++ base widget here instead of this UMG monstrosity.
Hmm. I'm not sure you can simulate drag events and stuff and resize things using the GetOptions meta mod.
On the other hand, it seems like it would be rather simple to change what it displays because everything about it is custom (in regards to ordering items or how interacting with them functions).
Also not sure how listview works in reality in regards to how it displays the widgets. Not sure GetOptions will allow you to customize how it looks at all. Theoretically I think it could display a list of widgets just like listview, but I have no idea. I've only displayed strings.
Hi ben sorry for the interruption after years, have you finally figured out how to draw line or spline that allows for rendering material/texture? I just went through your tutorials, but it seems no sharing there about this topic.
6 years later, my advice would be: poke around with FSlateDrawElement::MakeCustomVerts and your own spline-to-vertices rendering code
Do you guys know of a way to overlay the entire UE editor with a slate or UMG widget, that works outside of the PIE?
Hmm. Can you make Slate windows opaque?
I could open a new window that fills the screen, is always on top, and the background is opaque
And doesn't consume inputs
For what scenario?
I had a random idea of making a UE tutorial plugin that can highlight different aspects of the editor and interact with the user. I figured best way to do that would be overlaying slate with my own widget somehow
yea so Theos i went away from the disabling widgets solution, the visual "transition" from enabled to disabled was just too harsh imho
since i've changed my layout to 4 borders surrounding a spacer it was also easier to do the blocking part since i don't need a cutout anymore and can just make all 4 borders visible so that they catch clicks
are all your buttons the same size? the way i visualize what i think your idea is means that you cant really customize your button sizes, unless you have some cool code that changes the spacer dimensions to match the dimensions of the button it overlays.
also did you try just using Not Hit-testable (self only) instead of disabling it? if the button isnt hit testable, it wont be clicked and therefor has the same functionality as disabling it without any unintended visual changes. then you can flip it back to hit testable when you want it to be clicked.
i'm sizing the spacer to the button size
ok. thats pretty cool. well, as long as it works!
send me a video of what the finished product looks like later, im curious
will do
Thank you dude, I will try to poke around it, and SMeshWidget would be a great reference for this approaching right?
Does someone knows how can I monitor the focus on a child UWidget inside a UUserWidget wrapper? I want to highlight a UUserWidget wrapper when a child UWidget receives/loses focus
I know there are query methods for that like HasUserFocus, but I don't want to call them on tick/timer, ideally, I would want to bind to an event/delegate in UWidget, but I can't see any. Is there a workaround?
instead of that, you could make your delegate in the containing UserWidget and have all your buttons subscribe to it. the parameter could be the reference to the button that broadcasted, so the UserWidget can know what button is calling it
or you can make your own UWidget inherited class and put some custom logic in there
that might be easier actually
Is there any way in Slate to manipulate the contents/geometry of a widget to curve it around a center point?
Effectively Im trying to curve some other widget around the Black rim of this widget
I finally got it working like this, spline with material
It seems OnMouseEnter also catches gamepad focus. It turns out slate events are exposed through SObjectWidget, not UWidget, (which leaves UWidget in a very awkward position)
I should have checked lyra earlier, tbf
You can apply a render transform. You'd need a separate widget per letter, though.
And it won't curve the actual letter, only move / rotate it.
senpai if you can post a tutorial even if it doesnt' have code, that would be wonderful for the community ๐
I second bens notion. Gimme that material!!!!!
Sure I will write a tutorial for it at this weekend ๐
What are the magic words to make an SGridPanel stop automatically resizing the cells based on the content size? I'm looking to just have them 'overflow' on top of the next adjacent cells instead of resizing, this is what I got right now, moving a slot makes everything else resize
I'm thinking I'm missing something, I tried the SUniformGridPanel as well but this one just makes all the grid cells as large as the largest element, though I guess that's a step in the right direction
Have you tried settings the row and column properties?
And then perhaps using an SBox as a wrapper for the cell content with a specific width and height override and letting its child widget overlap?
I tried all sorts of things and now I dislike layout hierarchies even more, just gonna override the onpaint event and do my own canvas thing.
Struggling to find documentation on turning an editor toolbar button into a menu anchor type experience with my widget appearing below the menu button.
I know the logic for UMG but not sure of all the requisites for Slate
Iโve tried to look at refs for other toolbar buttons but not finding anything solid
so I managed to cobble something together with Chatgpt (i know, i know)
and it works. But the placement of the menu anchor just doesnt seem fixed at all. it spawns as in the gif. If i try and play with the Editor UI scale in engine prefs the opening doesnt even follow the button its now like 20/30% offset to the side.
none of the MenuPlacement_ args seems to work as intended either
this is the code
Anyone ever find a fix for a focus issue where if you bind to a buttons OnPressed instead of OnClicked, it only works the second time you click it? (after it/its parent gets focus)
oh, apparently if I make it not focusable (.IsFocusable(false)) that makes it work on the first click cool
No, youโd need to write a new custom widget that painted the characters yourself. Not terribly difficult, like take a look at how the ruler works for vertical text in the UMG designer. Youd just paint a character at a time
I'm writing a low level error type for better and more civilized error handling from C++, is there a way in Slate to create a window with its own message pump so I can display potentially fatal errors to the user while blocking the engine tick? FPlatformMisc::MessageBoxExt is too limitting for me (it doesn't even allow to set my own buttons with their own text on the bottom of the message)
I think I potentially found my own answer: https://forums.unrealengine.com/t/creating-slate-window-outside-of-engine-tick/2144593
FSlateApplication::Get().SomethingsomethingModalWindow
Does anyone know how to make ListView fill the width when wrapped in SScrollBox?
With SScrollBox:
No SScrollBox:
use the widget reflector to see how big each thing is (both desired size, and actual size) - maybe the horizontal box slot needs to be set to HAlign fill also
Put the HAlign on the box slot?
The one you have there means that the listview is using the maximum width of the slot, not that the slot/scrollbox is using the maximum width of its container.
SScrollBox is fine, but SListView shrinks (same as setting HAlign_Fill for HorizontalBox).
If I remove the SScrollBox, the SListView doesn't shrink (see image 4)
I expect that the SListView, when wrapped in SScrollBox, will be the same as image 4.
Hi! I'm trying to reduce standalone Slate app size as much as possible. Right now I managed to make it only 14mb after packaging.
However, most of the size takes .exe file itself. All my content is below 1mb. So I assume it is the engine itself, which takes most of the space.
I know it is already very light, and there are not many reasons to make standalone apps using Slate (I make a small modding kit for my game), but I would like to reduce it as much as possible purely out of interest to see how small the application size can be on Slate.
So, the question is, what can I exclude from engine and how, besides removing modules from build.cs (alredy removed everything useless there). I know I can remove some features and engine code using .target.cs file, but do not really know what I can exclude.
Do SCompoundWidgets only have 1 child slot?
Or can a compound widget have more than one child slot statically allocated?

Wrapping stuff into widget-container may do the trick
If you want more than 1 child, use a widget that has more than 1 slot ๐
A grid view or something. Or horizontal/vertical box.
Or canvas/constraintcanvas if you want fanciness.
I have a custom compound widget which is basically a button. It's working great. Now I want to see if I can basically build a pop-up widget inside of this compound widget class that displays beside my widget. It's like reinventing tooltips. My first idea is to use OnPaint to call the "tooltip" widget's OnPaint with different geometry data but I can't figure out how to configure the allotted geometry of the culling rectangle, no matter what I do my "tooltip" only renders within the bounds of my button widget or vanishes entirely. Am I even close to the correct way of doing this, should I keep banging my head against this OnPaint wall or is this stuff set up in a way that a parent can never OnPaint a child outside of itself?
You can definitely paint children outside, unless there's culling going on.
But why not use a horizontal box or something where the second slot has another widget that's zero sized and that draws outside its bounds? Instead of playing around with on paint?
Or may overlay widget where the top most widget uses a render transform to move it outside the button?
You'd have to constrain its size, but yeah.
I'm trying to compile a project on 5.5 and SListView::ItemHeight is deprecated with an extremely useful message "The ItemHeight is only used for Tile. See ShouldArrangeAsTiles Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile." I have no clue what I'm supposed to see when looking at ShouldArrangeAsTiles, doesn't seem to have any useful info regarding how to get rid of this warning. Anyone?
Seems that it just had no effect in my case, so doesn't matter. Doesn't make the message any more useful. ๐
thanks - i'll beat my head against the wall a little longer. the reason why i'm choosing this method is because it's how graph panels appear to draw overlay widgets over (or near) graph nodes natively, and obviously they work OK. it also just feels less hackish to me than setting up something that relies on negative padding magic numbers
Don't bother with negative padding. Literally set a render transform to push it out of bounds. ๐
thanks didn't know that was a thing, will try it out if i can't get this to work soon ๐
i am stupid and could not figure anything out. no matter what i did, i could not get my floating widget to draw outside of a scrollbox parent that OnPaint was drawing within.
didn't try the dummy slot w/RenderTransform but i feel like it might not have worked either, i think somehow my scrollbox was grabbing and cutting everything off no matter what i did. i just never realized it was the scrollbox doing it (still don't understand how it would, the widget I was OnPainting had no info whatsoever about the scrollbox and i was overriding everything i possibly could)
ended up making use of SGraphNode's overlay widgets system... needs some cleanup but at least the stupid thing runs https://gyazo.com/e8644fb6f030b0e5295b30b00baf73cf.mp4
I'm not an expert in UE UI, though have some experience with UI outside gamedev. In my understanding the main idea of "scrollable" containers is to manage content larger that it's own size, so the task of drawing stuff outside contradicts to their ability to scroll content, I mean everything that's not fit will be available via scrolling 
i wasn't drawing a contained widget, i was manually painting something. i just don't know how it knew to do that
but yeah, it was fun https://gyazo.com/47b92eff740b1cce8616f1852559b2b1.mp4
the paint system must maintain its own callstack/ownerstack somehow i guess, maybe
so that painting doesn't affect child's process of measuring it's size (to tell parent)?
there was no parent, it wasn't added to anything. create an SWidget with SNew... then call SThing->OnPaint(stuff). nothing else
but calling that OnPaint from within the OnPaint of a widget inside the scrollbox
have you tried this setup without scrollbox in the hierarchy?
no; found another solution that worked, don't have time to experiment much, but i do suspect if i called onpaint higher up maybe it would have just worked
sorry for the resurrection ping but FYI as seen above i found it by pure dumb luck while looking for other stuff, this is all it takes:
FDetailsViewArgs Args;
Args.... = blah;
FPropertyEditorModule& PropertyEditorModule = FModuleManager::GetModuleChecked<FPropertyEditorModule>("PropertyEditor");
TSharedPtr<IDetailsView> DetailsViewWidget = PropertyEditorModule.CreateDetailView(Args); // this is an SWidget
DetailsViewWidget->SetObject(YourUObject, ...);```
The scorllbox probably has culling built in...
yeah, like i said, i just couldn't see how it did. there must be a paintstack somewhere, my slate knowledge is not so deep
i guess you must call OnPaint and whatever does the draw says "well you haven't finished drawing the scrollbox yet so you're going to get cut off". 
How would I get the screen resolution in a PreLoadingScreen module? Calling GEngine at startup crashes, so can't use that.
Maybe with FSlateApplication::Get() somewhere?
The call crashed the engine on startup. I also tried TickSpaceGeometry but it won't return anything. Maybe I should make the initial startup loading screen just a static splash screen then
I guess I could try to find out what the resolution is set at, obviously the engine has to know what the resolution is at somehow :/
You may have to delve deeper into the windows api then? Or whatever OS you're on.
But how do you even get anything's tick space geometry if there isn't a slate application to create the window?
Or tick the widget.
It may not even have a window to query yet.
no more slate. just shoot me. (or: wow! this is working more amazing than i could have ever imagi--- ARGH) https://gyazo.com/424275c6c09541b80d4e23168042bdc2.mp4
slate jank aside, today's mission impossible is: how to create an SPropertyEditorInline (which is of course a private class I can't use) for a single instanced UObject property, which is an element of an array?
There's a create single property thingy in the property editor module.
yeah i can't use it because this is one element of an array of a property that i want to display
thinking i'll have to copy/paste and modify a bunch of engine poop so far
SClassPropertyEntryBox 
click... click... click... nothing
https://gyazo.com/bfc06004de5b019e44247343c3dc8735.mp4
of course it works if i just simply insert it elsewhere
... alrighty SVirtualWindow is no longer my best friend, it was causing some of these issues. i don't know what SVirtualWindow should be used for, but it's not this.
Virtual stuff.
Damn @stuck jewel , that's a cool ass thing you're making. Looks so good
Leave some talent for the rest of us
Are you making this a plugin for sale?
no; for flow graph (although i'm getting angry at flow graph and modifying it a bunch, so it might require a fork, at least for a while until i also clean up my changes and convince flow owners that they did a bunch of lazy stuff with their graph worth fixing) https://github.com/HomerJohnston/UE-FlowYap
nothing to look at yet
Did you do the slate design yourself?
yeah
thats very hot i gotta say
damnit
im looking for a UE sugar mommy/daddy
man...i tried to make my own slate style once and i gave up because its cancer and i suck. yours is so nicely laid out
i became a basic UMG user....im not sure i miss slate
lol
slate style isn't really cancer... it's more like a chernobyl bio-robot radiation dose
or ten of those
it's just a vertical box with three buttons ๐
do they light up when the array is filled?
they show/hide appropriately yes
thats still sick.
how do you make an array object be exposed as a blueprint node thingy
and do you manually swap the array elements using these buttons?
or is there some default
im guessing it just uses the normal slate array switcher
and you replaced the buttons
yeah it's just an array. it's just slate vertical boxes that get slots added/removed to match the array
man. it looks so good that it feels like it must be custom
the pins for each fragment (row) are named uniquely like Name_GUID so if i rearrange the array the node just moves everything around naturally
when you're naive making something like a sequence node to start you'll probably use 0, 1, 2, 3 .... but then you realize that it SUCKS to disconnect pin 2 and reconnect to pin 1 when you move up and all that
ic ic. makes sense
since we are talking already, i had a problem using Textures and stuff, and considering your use of slate you probably know the answer i need.
im trying to make UMG buttons for an action menu in runtime based on how many actions the object im interacting with has. the button should take the icon stored in the action object and use it as its texture, during runtime.
the problem im having is that i can't seem to be able to figure out how to set a texture in code using a path, and the button brush or image brush things require various different things that confuse me. some things need a UTexture2D*, some things ask for a UTexture, some things ask for a T-Something-or-other.
i know theoretically how to use the TextureFinder thing, but it never seems to work and always throws errors
this is cool
so the pin is connected to the named item and not the slot?
and therefor you dont have to manually swap the pin?
funnily enough i don't know diddly squat about UMG yet ๐คฃ
well, i dont think its a UMG problem actually. im doing it in cpp, and textures are a slate thing
i just cant figure out how to do it properly
i love that the textbox expands over the icon when youre typing in it...another great touch
this code throws errors
well... you shouldn't be using constructorhelpers for a start, you generally shouldn't be loading game textures via hardcoded paths ever
can that be a UPROPERTY you set somewhere to point at that asset instead?
ok good to know. i kinda hated that idea anyway, but i wasnt sure how else to do it
well i am trying to set this
ive tried making it a Texture2D and setting it in other ways, but most info tells me to use a path
and the constructor helper
the other weird thing is that i also tried setting this in the inherited blueprint object
but when i pull from that i get nothing
there's no way that will "get nothing" if you set it on the blueprint...
if you're in UE5 change that to TObjectPtr<UTexture> instead of UTexture*
won't change any behavior but it's they way we need to get used to doing UPROPERTY's from now on.
share what isn't working next with that setup though
ah ok. some things say to use *, some say to wrap in TObjectPtr, i cant tell the difference
i think ive had a problem with TObjectPtr before tho
like, some functions ask for UTexture*, and i cant put a TObjectPtr<UTexture> in there
yeah, it's really annoying, epic is shoving this new system down our throats before it's fully ready (if it will ever be)
do you mean that BNE implementation is returning on the first line or do you mean SetBrushResourceObject is running but not doing anything?
ill try to make a video to showcase my problems
i tried to also switch to using materials, but then i had problems making textures into materials through code
definitely seems like you should be able to go from UTexture2D to an Icon usage
....i fucked up. i hadnt actually set the icon in the inherited class.
so...it does work
i guess i dont need help then. i can just set icons in the editor
lol
but you did help me by making me try to showcase my problem, which led to me figuring it out
so, thanks
btw what are these 2 pills below the exec?
actually, I still want to be able to set a default icon in case there isnt one. id still like to know how to set that in cpp
if i cant use a path, then how would it be best to set the icon?
they're just output pins but custom
ah
use project settings - make a UDeveloperSettings class and set a default in project settings, read from that if the local one is unset
(they're actually buttons to fucking turn on custom output pins, but this was only because FlowGraph was coded like shit and each pin was adding N cost to refreshing the graph which was adding up really fast, i'll probably just turn them into straight pins if i can finish fixing this plugin)
does this not still require using an asset path?
not sure what you mean?
project settings... in your editor UI
use a TSoftObjectPtr for this, config ini entries need to be soft pointers to work
you said earlier to not use static paths for textures. maybe im misunderstanding
Yeah no static paths involved there
so this crashes for some reason, if i do it during runtime. but the second image works in the object initializer
same thing for both
well, maybe its not the same thing technically. in one of them im setting a UPROPERTY, and in the other im directly setting a brush
honestly, i dont care. i already made something that works. this is too much effort
?? why still paths in code mang
isn't there one to set from UTexture2D? from a UPROPERTY?
there is, which im using for the other part of it, but i cant set the UTexture2D in cpp
its ok though i dont rly need it
im too lazy to work on that more lol
you're not supposed to set the UTexture2D variable in C++...
asset = reference through UPROPERTY = set it in the editor
yeah but i want to set the default in cpp, because im relying mostly on that. i want to do the least possible in the editor for UMG
no, you don't want that
you want to set the default in the editor
unless this is just an editor-only icon for an editor tool, then nobody will care if it's a hard coded editor image path
well alright. its not a big deal i guess. i just really like the idea of keeping as much as i can in the top level to keep everything together
and i want it to be portable to other projects and stuff more easily
Your project will crash on run because the editor will not find the hard coded assets to pack. And it's dumb and annoying to manually pick assets to pack
Add / to always package! ๐
that's almost dumb enough to be something i'd recommend but not quite
i have standards
๐
I'd totally recommend something like /Maps doing that, though, as long as you only put production maps in there.
wtf is SlatePrepass and why is it consuming 5.3ms of the game thread?
oh
yep you were 100% right. this was all because of PIE. a standalone version of the game did not have these slowdowns. thanks
the code that draws widgets
I'm trying to update the position of a widget based on the position of another widget. it works fine at 1:1 zoom but goes haywire at other zooms, is there a global scale factor thing i don't know about? something like how UMG scales the UI at different resolutions but for slate?
right now I'm naively using GetPaintSpaceGeometry() of the child and parent widgets (the floating dropdown one and the button above it) to calculate a position but evidently this isn't right
the floating panel is drawn using a feature of SGraphNode, OverlayWidgets(bool bSelected, const FVector2D& WidgetSize) which only gives me the outermost widget's size (useless), and I can only feed it a relative offset from the top-left corner of the outermost widget at 1:1 zoom ratio
I have access to all/any other widgets, just don't know how to unfudge the scaling
ah, found it. the parent panel (i.e. the actual graph) does have a zoom factor and the node can access it.
Scale my offset by 1.0 / OwnerGraphPanelPtr.Pin()->GetZoomAmount()
@grave hatch Mr. Wizard I know you don't use EditorUtilityWidgets but I was wondering if you're perhaps aware of some secret way to spawn an editor utility widget inside an editor mode toolkit hierarchy? This would have the convenience of letting me use some existing EUW widgets in my editor mode, might be a bit hacky but could be pretty awesome right now.
Hi everyone , is there a way I can get rid of Menu.Background and Menu.OutLine which is inside Construct of MenuStack.cpp? It causing a black background on my slate
I do not want to comment engine code
I do not, sorry! Just spawn it as a regular uwidget?
I'll try again, editor utility widgets have some special sauce and are generally spawned by some subsystem that already creates a tab, I could deal with that if I could also manage the lifetime of this tab when I exit my mode, but I failed to do that as well ๐ฆ
does anyone happen to know what happens if i bind an object function to a delegate, and then delete the object? does the delegate break, or does it hold unnecessary pointers, does it clean itself of outdated bindings?
multicast dynamic delegate btw, using AddUniqueDynamic
#cpp
but generally speaking, the whole dynamic/reflection system is all safely integrated with the GC
you would be getting crashes if it didn't (as is possible with regular delegates - non-dynamic delegates - and certain binding methods)
alright thanks
Would it be possible to do some operations on FBlueprintEditorModule (most likely), grabbing this "parent class" widget and moving it to the title bar?
I've found that it's being created in PostRegenerateMenusAndToolbars (BlueprintEditor.cpp). But cannot find how I could possibly access the title bar here. There are ToolBar and MenuBar extensions, but not TitleBar. Perhaps it could be possible via IMainFrameModule, but cannot find anything relevant.
The FLevelEditorModule has AddTitleBarItem, but that accepts only FTitleBarItem element, which has only plain text capabilities anyway, so even trying to mimic that for blueprint editor won't be enough, on top of probably requiring to modify the source in the first place.
Any chances to do it without modifying engine's code?
Question could fit in #cpp or #engine-source, but since it's specific to UI and I prefer a way without modifying the source - here I am.
i think that is a SWindow piece. try using the widget reflector on it
why do you want to move that to the title bar though?
it annoys me
more than fair
tried it before, but I don't know what to do with this information. reflector when hovering over circled area
see the SWindow at the top?
uh.hmm
everything is swindow so thats not helpful
docking target is the different sections you can place other windows inside of it i assume
i guess its just a docking tab?
are the buttons in the verticle box below that?
to give more context: when I switch tabs, the parent class changes, which changes its width, which changes width of tabs, which shifts them slightly. when I want to quickly move through them, I often missclick or it just irritates my eyes :V
you had me at "it annoys me". i spent weeks making a plugin to fix something that annoyed me
๐
go deeper. whats in that horizontal box
show me more of the tree under it
find where the X and minimize buttons are
different path. this is for minimize
hmm. you suggest modifying source code? tried to avoid it. plus there are UBlueprint dependencies to get the link working. can't just "make a widget", inject where those buttons are and call it a day
i didnt say that. i meant look through the source code to find how it creates the title and places the widgets. i havent thought through how you would actually go about modifying it yet
mm. idk. its 2am and im not exactly a slate expert. not sure i have any info you can use
ye, I can scroll through it and hope for some spark of an idea, but might need some magician or other wizard to help me solve this ๐
mmm. want a jank solution?
make an overlay for the entire program that covers the original parent class widget. make a new one that is locked next to the minimize button over the title bar
make the background opacity 0, and it doesnt consume click inputs
besides on the new parent class
I wonder how many things are going to break if I manage to make it this way
probably nothing! you should also make it ignore drag and drop operations and such, so that your layout docking still works
but...i theoretically dont see any other issues
anyway, ive gotta hit the hay
gluck
use global tab manager i think, create a new tab widget and a detail customization or whatever for it
cya
I'm trying to create a custom ComboBoxKey in cpp that is always filled with Data from the GameInstance.
Is there a Hook in the UWidget class that I could use similar to NativeConstruct for UserWidgets, to retrieve the possible Options and call AddOption?
You can make a Userwidget with a button inside of it and use NativeConstruct from there
I believe ReleaseSlateResources is called right after construct so you can use that too
anyone knows if it's possible to make a SObjectPropertyEntryBox also accept classes? trying to make an asset picker that'll take any type of asset but filter out assets that can't be spawned as actors (ie the way you can drag a static mesh into the scene to spawn a staticmeshactor), and it works except it doesn't include actor classes whether they be BP or CPP
nvm there's the Engine.Blueprint class, idk if I can get the parent class from that or at least check if it inherits from Actor or smth
got it working but if any asset that gets filtered has loading error, this pop up appears which removes focus from the picker and closes it, any way to disable it while filtering? this is the filter function fwiw https://hatebin.com/onescrrkej
& IsAssetPlaceableAsActor https://hatebin.com/bagniyadgi
Hmmm. You could try using the template thingy.
Instead of doing UExample::StaticClass() do TSubclassOf<UExample> ExampleClassVar;
You may have to then cast this variable to the static class
Uh. It might be TSubobjectOf
Something like that
Beyond that I don't have much else
^
this only works if the class I'm comparing against is hardcoded afaik, in my case the classes I want to check against are from a TArray of UClass
I ended up finding how to get the native parent class from a blueprint without loading the bp class though (using tag values)
Now the only issue is that SObjectPropertyEntryBox still loads assets anyway after filtering when scrolling through them, and afaik I can't prevent that without making my own version of the widget altogether
do you display them before filtering? why are they being loaded
probably to generate thumbnails or something
basically SObjectPropertyEntryBox has a filtering delegate which I put my filter function in, and in that I'm supposed to return true for assets that don't pass the filter and false for assets that do
assets that don't get through don't get displayed in the asset picker, assets that do do get displayed once I scroll down to them
Can anyone help me with this issue.
Does anyone happen to know how BindableProperty.h works. It appears to be some delegate that takes a anonymous function (Lambda) to detect if a Attribute of a widget changes. For Slate Attributes there is a bind called "OnChanged". Is this delegate called by the widget when Construct is called?
I am looking at a weird call path where some Actor is selected from the viewport. This actor is wrapped as around a TBindableProperty DebugActor type which is tied to a widget for a slate timeline.
I assume that the lambda you pass to OnPropertyChanged is called by the initialization phase of attributes from the widget construct function.
Example of this would be RewindDebugger.cpp
Line 101 inside the default the constructor. A widget SNew creates a FRewinderDebugger instance per object it seems.
I think OnPropertyChanged is called on tick.
I'm not sure it's called on initialise.
How would you use tabs in your own custom window? My tab just appears at the bottom of my window.
You might need a Docker manager
Or maybe a layout manager
Something like that
I tried using that but I am not sure, how to get that set up. I posted a picture here, below that is some code. #cpp message
hello dev's , wanted to take tips and advices , what is the ideal way to have a window that binds to a pawn delegates and updates when ever that delegate is fired
i have it now working but if i closes the window and that delegate is fired i get crash and it crash in the line where the slate widget is updating it self as if it is still there but closed and also still bound to the delegate
maybe also a way to unbind to a delegate when closed or something , i hope this is clear sorry for bad english
just use an IsValid check to make sure the window exists. or you can unbind the delegate
unbinding is the same as binding. just do Delegate.RemoveDynamic(object, function)
i have this check in the widget it self where when the delegte call is received i update a scroll box content , and what ever check i do to this scroll box it is always passes and crashes when i use it
where do you think i can bind that to when the window is closed , i have it spawned using the gloabal tab manager , and i see there is on close event i can use but i couldn't figure out the signature that i need to have in the function i will be using
if i managed to bind to this window closed it will save me alot of troubles
i noticed one thing i have is valid check for most things in the widget but there is one place i don't have it will try to add it and see what will happen
dont bind to window closed, just unbind the function from the delegate in OnWindowClose
thanks that helped steering my search , i managed to do it thanks
I have a C++ question regarding returning SNew Shared pointer for this function
TSharedPtr<SWidget> FNetworkRewindTrack::GetTimelineViewInternal()
{
// TODO Create Widget UI
// Return a TSharedPointer to the Widget or SNew TSharedPointer Here.
//NetworkRewindTimelineView = SNew(SNetworkRewindTimelineView);
//return NetworkRewindTimelineView;
return SNew(SNetworkRewindTimelineView);
}
This function is a provided interface function I am overriding to return my own SWidget
I get a conversion issue from my type to SWidget, despite knowing my type is derived from SWidget
0>NetworkRewindTrack.cpp(60): Error C2440 : 'return': cannot convert from 'TSharedRef<ObjectType,ESPMode::ThreadSafe>' to 'TSharedPtr<ObjectType,ESPMode::ThreadSafe>'
0> with
0> [
0> ObjectType=SNetworkRewindTimelineView
0> ]
0> and
0> [
0> ObjectType=SWidget
0> ]
0>NetworkRewindTrack.cpp(60): Reference : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
Else where in the source code of other examples overiding this class they dont have problems returning an SNew or sharedptr type dervied from SCompound?
I suspect It might be because I haven't implemented the virtual functions of FWidget yet
Found the issue... missing the public qualifier in my class inheritence :/
thanks tho!
Hah. Hit that one occasionally. It's a real dick.
ya was a simple mistake but the compiler gaslit me hard for 3 hours
I know this might seem simple to some but I need to share to be excited just for a moment.
I created two plugins, one being Editor only, and the other a game plugin.
The Game plugin allows any C++ or blueprint classes to add new entries of data, search entries, remove, update, etc. This data is stored in the Game Instance
Entries contain information like what class it came from, named variables, and values of variables.
The Editor Plugin will only update content in the Debug Window when new data is posted.
So far, it reminds me of a minimal Grafana Dashboard but it can be expanded on and is working in a way where if I package the game, the Editor only plugin is shed without issue.
This is my first time ever working with Slate though... I do like how somewhat minimal it feels without the very rough around the edges look UMG UI can appear without slight adjustments made to it.
bro. can i have a copy of this? its quite annoying how i need to look through the objects list to find the object i want to look at current values for, and then find it in the details panel. arrays make that even more annoying, with arrays of objects containing arrays and so forth.
this looks useful
Sorry for the late reply, been super busy. I am not sure if I am ready for it to be shared yet, I keep adding to it haha. But thank you. Honestly, I would imagine better debug utilities exist out there, even if I am working on trying to make mine performant.
I got it to show some GAS info, but I would like to get it to sort it when displaying as the tags are showing up in the middle of where the attributes are, but that should be easy.
The redaction can't hide what you're making! It must be a porn game.
Debuff Punctured hehehehe.
I never considered getting a debug plugin so I haven't looked, but right now I'm interested in this one because I've seen it. I hope when you're ready to share it you remember I want a copy. (I don't have money, and yes I'm asking for free things. If you're thinking of selling it then that's ok. Don't feel obligated to give me a copy.)
Can I make a suggestion I just thought of though? I assume with a debugger like this you'll get a lot of bloat as the project grows, and you need categorization and space management.
I guess my ideas aren't rly revolutionary, but you should add collapsing functionality to object stuff (maybe taking advantage of the in-built 'Advanced' slate UPROPERTY mod). Tabs for different large categories, like World actors, level actors, game instance objects, player controller tied objects and such. Maybe filters on top of that to compartmentalize it more.
Idk, I'm sure you know this stuff already. I just like blabbing
It's not one though. Punctured is a code word
Yeah I agree, that's actually next to outline how I'm going to get it sorted.
Noice. I'm excited to see what you come up with then
Hey, is it possible to store an SOverlay::Slot to a variable and set its content in a function?
It's part of the slot interface, all slots have it i'm pretty sure.
Bear in mind, it returns a raw pointer. Not the best.
Content can always be replaced in panel widgets (and compount widgets)
It might be better to add an SBox to the slot and stored the shared ptr to that widget and put whatever you need in the box instead.
Depends how good you feel you are with pointer management.
Hmm I can't get expose to work, maybe it helps if I share the layout of my SCompoundWidget:
SOverlay
Slot -> Text Block
Slot -> multiple text blocks created/set by a function
Hey, im using a Data Struct for the inventory slots as well for the items, each item has a specefic Integer of the Max Stack possible and a boolean to see if its stackable or not. however what i want is to when the drop exceeds the max stacks i create another drag with the remaining but its not working and i think its because the operation end immediately because mouse isnt held down. do you know anyway to fix this please? maybe there is a way to make the drag and drop on click and not on press, like you have to click to drag and click to drop. is that possible?
We can help with the errors.
my dialogue junk has a "character asset" object picker widget. right now i have it hidden behind a pane, you press a button and out come the extra options. is there some way for me to define a custom drag/drop operation, so i can drop a character asset onto this button and have it run custom code?
gif starts with what i want to do, then shows my current workflow
maybe this would require a custom SButton which i add the functionality to?
like try to mix SButton and SDropTarget together?
Yes there are ways, there's something like FDragAndDropOverlay widget that is used all over the editor, you need to override some methods in your widget to give it the right replies for the object being dropped and stuff and you get the references to do with as you please. It's the class that makes a widget overlaid in blue when you hover a valid widget on top of it.
I think, my memory is a bit hazy to be honest, I 'half implemented' it once in my own asset editor thingie.
thanks! that gives me some keywords to dig at
must be FDragDropOperation
nailed it
SAssetDropTarget

