Nothing shows in the output. I thought about doing a .Changed but I don't know how to apply it.
It is a normal script in a TextButton
local Player = script.Parent.Parent.Parent.Parent.Parent function onClick() script.Parent.Parent.Visible = false Player.Character.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=261394422" Player.Character.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=261394385" end script.Parent.MouseButton1Click:connect(onClick)
Without using script.Parent.Parent.Parent.Parent.Parent
you could just stick to the LocalPlayer
, this property of Players
gains access to the localplayer
. Next, you should Double check if you are indexing
your variables or code correctly. Also use a localscript when using GUIs.
Note: A normal ServerScript can Not use localplayer
.
<html> </html>
local player = script.Parent.Parent.Parent.Parent.Player --try this instead. -- or script.Parent.Parent.Parent.Parent.Parent.Player
I basically know this is the same thing as your variable but this might work unless not.
local player = game.Players.LocalPlayer --Try using localscript for this type.
I've done your script but except it's like Parent.Player, not Parent.Parent.Parent.Parent.Parent and it works for me even without test mode. But again, it might just be roblox's update or something else. I've hope this helped you!