[FREE] Lobby style menu framework

Auto detect for your local language(fontmap.xml):
 "<font face='$Font2'>謝謝你</font>"
or(custom font):
 "<font face='YaHei Black CN'>謝謝你</font>"

thank you :slight_smile:

hmm where should i put this? thanks :slight_smile:

You can use it like this:

TriggerEvent('lobbymenu:AddPlayer', 'examplemenu',"<font face='$Font2'>謝謝你</font>", '', "", 65, 2, true, 12, 6)

oh ok i’ll give it a try tommrow cuz fivem’s auth is down now :sweat_smile:
thank you very much

1 Like

New functionality Update:

More info on the wiki page

2 Likes

this is great !
i am really happy about this release as i am still learning scaleforms
Thank you for sharing

Glad you like it!
If you want to check more scaleforms, I recommend [Release] Event-based Scaleform Library too

1 Like

thank you for you recommendation !
I think i am gonna leave my current WIP script and go play with these scaleforms now lol

is it posible if that i can see all the players join in one event? cause im using this and only my name is in the list the other player cant see my name they just see theirs

TriggerEvent(‘lobbymenu:AddPlayer’, ‘critMenu.ExampleMenu’, GetPlayerName(PlayerId()) , ‘’, “Player”, 65, 1, true, 12, 6)

Because it’s client-side.
GetPlayerName(PlayerId()) will only give your name (the client). In order to get the other player’s name, you need to change PlayerId() with the ID of the other player, or get a list of player names from the server.

ohh hope you have that in update haha lol

Can’t really implement something like that, as a default event that can be used by anyone, because the player list can be used for a lot of situations.

For example, this is how you can get all online players:

--Serverside
AddEventHandler('GetPlayersForLobbyMenu', function()
    Citizen.CreateThread(function()
        local table = {}
        for _,player in ipairs(GetPlayers()) do
            local row = #table + 1
            table[row] = {name = GetPlayerName(player), id = player, status = "whatev."}
        end
        TriggerClientEvent('UpdateLobbyMenuPlayers', table)
    end)
end)
--Clientside
AddEventHandler('UpdateLobbyMenuPlayers', function(_onlineList)
    TriggerEvent('lobbymenu:ResetPlayerList',"exampleMenu")
    for i,k in pairs(_onlineList) do
        local col = 8
        if k.name == GetPlayerName(PlayerId()) then --this makes you a different color on your screen only.
            col = 11
        end
        TriggerEvent('lobbymenu:AddPlayer', "exampleMenu", "["..k.id.."]"..k.name, '', k.status, 65, i, true, col, col)
    end
    TriggerEvent('lobbymenu:ReloadMenu')
end)

TriggerEvent('lobbymenu:OpenMenu', 'exampleMenu')
Citizen.Wait(10)
TriggerServerEvent('GetPlayersForLobbyMenu')

The player list doesn’t have to be scripted only for players connected to an event, or for online players. The framework is designed, and it will continue to be designed.
You can use it as a leaderboard, or as a Hall-of-Fame type thing. It’s up to you.

cant work for me can you help me?
client side


this is the server

just want to see the player join in my event

Do you have any messages in console? (both server and client)

no error

Add RegisterNetEvent('UpdateLobbyMenuPlayers') clientside and RegisterNetEvent('GetPlayersForLobbyMenu') serverside