Lbg-char - Standalone character creator

Hello, how i can change the initial outfit? It’s impossible to recognize the categories? [3],[11] etc what are?

{

    [3] = {5, 0},

    [11] = {5, 0},

    [8] = {2, 0},

    [4] = {1, 0},

    [6] = {1, 0}

},

You can find the categories here

1 Like

Good evening, I noticed a problem, I state that I am using OneSync infinity, when the players log in for the first time they do not see anyone, exiting and returning from the server the problem is solved, this problem has appeared since I entered this script, you know from what could it have depended?

No idea.

Nice work.BTW is possible to add clothes and any item like hat,shoes?

If you modify the code then yes. At this point I’m not so active on FiveM and busy with other stuff.

Hello, I’m trying to implement it on my QBCORE server by exchanging the clothes menu from the beginning of the players for ExecuteCommand(‘charedit’) all good but it doesn’t save the character’s clothes… help please!

so when the player is done with the clothing, an event is sent to the server, containing a table with the clothing, and a 1 or 0 if the player has sunglasses or not.

Where in the code does character creation end? :frowning:

Line 1075

1 Like

when I leave the server the character is not saved.

It doesn’t automatically change. That’s up to a developer to code.
It should be saved on your client however

1 Like

This is a really nice script. I have added quite a bit to it like functions to load all the clothing pieces found on the server dynamically and I am trying to create a way to save characters in either different json files or an array of characters in one. But thanks for the very good place to start.

1 Like

Amazing.

1 Like

is there a way i can open the menu?

check usage

How to set the saved Character when the player spawned?

Found the Solution

firstSpawn = true

AddEventHandler('playerSpawned', function()
    if firstSpawn then
		RefreshModel()
        firstSpawn = false
    end
end)

Hey Lamb thanks for the plugin!

First off, do you know how to connect the function to (open) automadically? I got a custom framework.

  1. They Create their name.
  2. They select their spawn point.
  3. The spawn with the Character Creator open.

I get I could do it via tiger. But got no clue on how to trigger and event to auto open once a spawn is selected. Idea’s?

oohah it has been quite a while since i touched it, let me see
you need to trigger the clientside event lbg-openChar. or they could run the console command charedit, but if you don’t want it, you can remove the last 3 lines of the script
and by the way, default behavior is to put players back where the event was triggered
also serverside there is a comment that says The event triggered by the client when they quit character creation is 'lbg-chardone', with the character table passed as an argument, so you could do something serverside using that, like change position if you are going to say something about the position of the player