Cloned script not working

Hello.
I have a server script that clones a part that is in ReplicatedStorage into a folder in the workspace. I have a localscript inside of the part that contains the following:

print("Hello?")

The localscript is disabled by default. I change disabled to false after I parent it. Unfortunately, nothing is being printed after I parent it into the folder in workspace. Does anyone know why this may be happening?

Thanks,
Ham

Local scripts must be inside a player or a character in order to run, if they are just in a folder or a part then they don’t know what client to effect and therefore cannot run. That’s why they’re called local scripts, the changes made are local to that players client.

2 Likes

Thanks! Now time to completely change my code just because roblox wanted things to be hard.

Now I wouldn’t really say that’s Roblox’s problem but I understand why you’d be mad. I’ve made mistakes like that before, it’s important to remember that there’s a server (roblox’s computer running the server) and a client (the players computer). Happy coding :slight_smile:

Don’t really have to describe what a client and server are to someone that’s been developing on Roblox for a decade, but thanks anyway!