so i made a simple scroll box to select a country that will appear as a flag when i hit play.
the countries and flags are taken from a datatable and I populate the scrollbox with a widget “bottoni”
then when i select a country, the flag’s dynamic material instance updates with the new texture.
The issue is all of this is working, just not at runtime.
As soon as i stop the simulation the flag changes to the one i chose.
I’m kinda new to unreal so any advice is welcome
Everynone
(Everynone)
March 25, 2024, 2:22pm
2
Looks like you copy-pasted this variable from the level blueprint, cheeky - but it will not work.
You do not get an error when you compile this?!
In order to suggest a tangible solution, we’d need to know where / when / how this widget gets created:
Yes i do get an error. How can i reference that skeletal mesh otherwise?
I’m not sure if i understand what you’re asking me but here’s how the main menu widget is created:
Everynone
(Everynone)
March 25, 2024, 3:58pm
4
You got me right. While there’s a lot of ways to handle this, here’s something that could fit into your existing script:
a new exposed variable in the button widget:
another one in the main menu:
The direct referencing from the scene only works in the Level Blueprint
I do not understand how you get those nodes to work.
I may be stupid but I can’t connect them.
edit: nevermind i figured it out.
1 Like
so I di that but i’m only able to control one flag.
It does work at runtime tho so i guess the issue is solved(?) hahaha
Everynone
(Everynone)
March 25, 2024, 5:25pm
7
Could you show the updated script for this:
Everynone
(Everynone)
March 25, 2024, 5:42pm
9
Looks OK-ish at a glance Scratch that, you’re sending just the last flag from the array. You do not need that first loop. Just send a specific flag to each execution sequence.
Yeah i figured.
Thanks for the help!
system
(system)
Closed
April 24, 2024, 7:17pm
11
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.