Ello! So this is the idea or what I wanted it’s that when a player finds a key and he gets the key I already figured that out BUT I want it so that whenever the key touches a trigger part a person named Jack to appear in a different way READ THIS PART I figured out how to make it in a normal script for the server but I don’t want that to happen in the server I want this to happen in a client with a local script so I put it in starterplayerscripts that it was already
easy explanation
Player clicks key and gets key, then he takes that key and and the key touches an invisible brick, then the brick makes a person named “Jack” appear and it’s I want it in a local script for the client not server.
Instances kept in ServerStorage and ServerScriptService are not replicated to the client. Use ReplicatedStorage instead. Also, when using clone, it returns the instance, and doesn’t affect the original instance, so you should instead assign the clone to a variable.
And the solution is to move Jack2 to ReplicatedStorage
local player = game.Players.LocalPlayer
local KeyBoy = game.Workspace.Dresser2.Drawer.Key
local Jack = game.Workspace.Jack
local Jack2 = game.ReplicatedStorage.Jack2
local TriggerTheThing = Jack.ClickPart
TriggerTheThing.Touched:Connect(function(hit)
if hit.Parent.Name == KeyBoy.Name then
Jack:Destroy()
local jack2Clone = Jack2:Clone()
jack2Clone.Parent = game.Workspace;
end
end)
Whatever that’s inside ServerStorage will nevertheless replicate to the client and will not run, especially useful for module scripts. ServerScriptService is important for running normal server scripts.