"LocalScript" Code and Explorer I need to know how to change this into a script that can be used in the Workspace instead of the StarterPack so I can make a crate that explodes when you touch it and press "Enum.KeyCode.E." I'm sorry if this question is a bit vague.
COMMUNITY QUESTION
How to make this script work in the workspace rather than the StarterPack?
2 answers
Impossible to do.
What you can do is use remoteevents to communicate with the server however.
https://developer.roblox.com/articles/Remote-Functions-and-Events
I'm still learning this myself, but I think what you could do is create a regular script in the object you want to explode that will detect when a player is nearby and then fire that client to display the GUI to the player. If the player then interacts with the GUI, fire the server again to do whatever it is you want to do with the object (explode).
At least I think that's how it goes.
This discussion is preserved as it was. New answers, comments, and votes are closed.

3 comments
Does that mean I have to use a different method?
You write the scrit inside a localscript, then use a removeevent to transfer the required values to the server. In this case, it is when the button is pressed.
Will try to when I have time.