Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Does PlayerRemoving event fire even if it's inside the LocalScript of the player who left?

Need to send some local variables located inside the LocalScript to the server, but I can only do this if the LocalScript with the PlayerRemoving event still fires despite the player with it being gone. If not, what method should I use?

I don't have a friend to test this at the moment, so I'm asking here.

2 comments

0

You shouldn't be needed values from the client when they leave. That's bad practice. And no, when the client leaves, it doesn't make sense for the LocalScripts within that client to continue executing.

0

No, it only fires in server Scripts. Btw, you don't need a friend to test this with - In studio you can start a test server with as many players as you want in it! https://developer.roblox.com/en-us/resources/studio/Test-Tab

1 answer

You don't Need a friend to test it! Go into Studio. At the Top click Test, and start a Local Server with 2 Players!

This discussion is preserved as it was. New answers, comments, and votes are closed.