Hello, I created a ped server-sided so that it is synchronized on all clients. That works really well so far (I want the ped to repair the vehicle of the user when asked). However, if a player reconnects, how would I go about getting the netID or ped handle of that ped again? Since the ped handle will turn to nil once a player disconnects.
2 Likes
Find the ped via FindFirstPed() in a logic loop, then get its NetID via this I guess. There should be an easier way to do this, though, so I hope someone else chimes in
I don’t really understand how I could use this native, could you give an example?
Do you think saving the net id of the npc in a database would work? Or would that just over complicate things?
1 Like
You could save the net id’s of the peds on the server-side.
1 Like
When I tried that, it somehow didn’t work. But now I somehow got it to work like that. Thanks