For some reason my script won’t work, it is supposed to disable swimming after using gear but it will not work but when I have it not disabled when I start it works and I don’t know why.
![]()
From the image I see that you placed the local script it in ReplicatedStorage as it’s above the blue blip which I’m assuming is a server script service.
A LocalScript will only run Lua code if it is a descendant of one of the following objects:
- A Player’s
Backpack, such as a child of aTool- A Player’s
charactermodel- A Player’s
PlayerGui- A Player’s
PlayerScripts.- The
ReplicatedFirstservice
Also, make sure to post the script next time using three back ticks in between the code ``` to format it properly like so:
print("hello world")
Also it helps us a-lot to help you debug your code.
I looked more and I made it so the separate script was part of the gear script and now it works
I found the problem but thanks for helping anyways!