[RESOLVED] Player model change by itself on death

Hi everyone, im having an issue with player models.

I have a script that give a specific model to a player. It works perfectly but when the player die, the game freeze for a second and goes back to the “default” skin i suposse.

Do you guys know why it does that ? :c

When I had this problem, I solved it by commenting line 255 of /resources/[system]/spawnmanager/spawnmanager.lua

From:

 SetPlayerModel(PlayerId(), spawn.model)

To:

-- SetPlayerModel(PlayerId(), spawn.model)

I think it fixed it !

Thank you ! :smiley:

I hate to revive this thread here, but I seem to only have this issue when using Skin Control. I know the mod is no longer developed, but I wanted to see if anyone had any solutions. I don’t recall having this issue on another server, so maybe it’s something do with something server side that stops that from happening after death?

Did you try making the change I suggested above?

Indeed, I tried that edit and it still changes me to Franklin each time.

Edit: Just want to state that this only happens while spawning a ped using Skin Control.

I would do a file contents search for SetPlayerModel in your resources directory. Something is setting your character and if you find it, you can comment it out.

im having the same issue ive done everything i can do and still does it to me and only me nobody else has this issue in my server

1 Like

This is happening for a friend of mine, and is not happening for anyone else in the server.

I hate to revive this again, but i have had no luck finding out where those files are and i cant find anything relating to it in my Simple Trainer or Lambda Configs.

What script are you using for: giving a specific model to a player?

2 Likes

Hi, it’s my first post and I’m sorry for reliving this again. What mod should i use so that my franklin skin always remains on the fivem server? thanks greetings

Should I apply this to every line in spawnmanager.lua which contains setplayermodel word in it ?

I still seem to be having trouble with the model changing on character death, edited my spawnmanager file, but no luck unfortunately.

I did a check through my entire resources file for the code, and it’s present in spawnmanager, adminmenu/clients, and qb-clothing/main.


I edited out this large section of code for refreshing the playerskin, but alas no change
I noticed it takes roughly 1 second for the model to change on death, could this be tied to “citizen.wait(1000)” ?

It’s frustrating because after it happens, it disables my menyoo and i have to restart my game client to use it again.