Download

listbox

how create a listbox to select my servers
like this image
5369f7f1fad7624147de9e0762b50b5ac489cc0b.png

There is a lot to getting that set up and working properly, but I can get you started.

First, I would make some kind of base container like a Border. Then make a Scrollbox a child of that border.

Make sure the scrollbox has the isVariable ticked in the details panel. Over in the event graph, you need to do a ForLoop and create a new widget to for every server to become a child of that scrollbox.

Now, this requires you to have another widget that will be this “ServerEntry” Usually its easiest just to make it a horizontal box, then put whatever information you want to display to the user.

So something like this. EventBeginPlay->ForEachLoop(array of server entires)->CreateWidget->AddChild to scrollbox. As the children are getting filled, you can set the variable information like the server name and player count on the ServerEntry widget.

can you make a simple example

b50132f796aca4b80ecdec9820b2dee315f124fb.png

I have something very similar set up here. In this case, it’s adding to a uniform grid so you won’t be needing all that, but its the same setup.

When you do a search for sessions, it should return an array of the servers it found. So instead of using the ForLoop like I do here, you can use a ForEachLoop across the array of servers.

On the MapEntry widget itself I have a function you can see there called Set Parameters. Just pass in the values from the server array to fill in the text of that widget.

The added widget:
d92f96999b6503e3af2bd3ec9098e9715739d8f4.png

f19663df9c071f6b25a7d6bf903ae05ac3943de9.png

Each of those variables are bound to elements within that child widget.