Introduction & Understanding
The reasoning behind this issue is mainly due to FilteringEnabled. Before continuing, please learn more about this by watching this quick video covering a bit of FE, and some reading. It’s mandatory you gather a collective knowledge on this as it is an imposed requirement as of ROBLOX’s Experimental Mode update of early September 2017. It’s also quite interesting and can increase performance between both the Client and the Server.
FilteringEnabled prevents automatic communication of LocalScripts to ServerScripts, primarily to reduce the probability of exploitation. Though because of this, these Scripts have been ultimately divided into their proper relationships.
####LocalScripts - Client, ServerScripts - Server
Meaning that any work related or directed towards these categories can only be achievable accordingly. Though loopholes can achieve some amount of work in its opposite.
FilteringEnabled doesn’t fully cut off communication though, it only prevents automatic communication. You can learn how to gain manual connection between these Scripts with RemoteEvents
Going About Fixing Your Issue
GUI’s are apart of the Client. Therefore all they should be Scripted with LocalScripts. Your ServerScript was denied access to the Player thus rendering it useless, being unable to complete it’s designated task. Luckily though, there’s a simple fix for this. Convert your ServerScript to a LocalScript.
Extra Pointers
Your Avitar Will Behead Itself!
• Yes, this is going to occur once your Scripts begin running properly. This is because the Head isn’t classified as the PrimaryPart of the Character. Think of PrimaryPart as the Part that everything else attaches itself to, meaning wherever it goes, they go. Since the Head isn’t the PrimaryPart, the Characters attempted reposition won’t follow through, instead, removing the Head from the Rig. - Your Player will die.
#####Consider targeting the HumanoidRootPart for R15 or Torso for R6. For Universal compatibility refer to Character.PrimaryPart
There Are Different, Easier Ways To Teleport Players
• The path you're taking is quite unnecessary, though it still works there are faster, easier methods that potentially are smoother and more efficient.
Since the Character is a Model, I suggest using :SetPrimaryPartCFrame() or :MoveTo().You can read more about this here and here too
Lowercase Connect Was Deprecated
• Though this still works, it's preferred that all developers become accustomed to the renewed functions. Please use :Connect().
References & Read-ups
• Eperimental Mode |
Lay-over video |
Stackoverflow post |
Remote Events |
Primary Parts
Hope this helps! Or brings you into the world of FE, if so don’t forget to accept and upvote! Questions, like me to further interpret? Comment!
4 comments
It's not printing anything because it's not running at all, being placed in a Script instead of a LocalScript.
Please consider reading my answer
I don't like being rude, but why did you accept Aniline's answer over mine? I worked very hard on that
Id mark both of yours if i could. Aniline gave me the code i used, but you helped me understand it more. Trust me, i felt bad doing it haha if i could upvote or something i would. I do appreciate your answer.