TheJim87
|
  |
| Joined: 12 May 2014 |
| Total Posts: 54 |
|
|
| 09 Sep 2016 04:39 PM |
Now, when I unhide the button it will work fine, hiding and unhiding the menu. But when I hide the button off screen (position 0,-51,1,-50 for hidden and position 0,0,1,-50) the first function won't unhide it and I don't know what to do. I tried almost everything. I hope someone here could help me with this issue. I am making this so only my daughter is able to change the music (Her name is Destiny, if you were wondering about the variable.) Any help would be most appreciated. Thank you.
CODE:
local Destiny = game.Players.LocalPlayer.UserId local locate = script.Parent.Parent:WaitForChild('ShowHide') function Unhide() if Destiny == 60787641 then locate:TweenPosition(UDim2.new(0,0,1,-50)) else end
end
Unhide()
local frame = script.Parent.Parent.Parent:WaitForChild('MusicList') local hidden = true script.Parent.MouseButton1Click:connect(function() if hidden == true then frame:TweenPosition(UDim2.new(0,0,1,-200)) hidden = false wait(1) else frame:TweenPosition(UDim2.new(0,-101,1,-200)) hidden = true wait(1) end end) |
|
|
| Report Abuse |
|
|
TheJim87
|
  |
| Joined: 12 May 2014 |
| Total Posts: 54 |
|
|
| 09 Sep 2016 04:44 PM |
| I tried it with a 10 second wait before running the function too. that also did not work... |
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 04:44 PM |
bruh ur moving frame and then moving locate lolo |
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 04:54 PM |
Scale not offset ( 0<----Scale, 0<---Offset, 0<---Scale, 0<---Offset)
|
|
|
| Report Abuse |
|
|
TheJim87
|
  |
| Joined: 12 May 2014 |
| Total Posts: 54 |
|
|
| 09 Sep 2016 04:57 PM |
| I just realized that ROFL I thought I was messing up xD I added an extra Parent and it works perfect now! Thank you so much for the help. My daughter will be thrilled now ^^ |
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 04:58 PM |
local Destiny = game.Players.LocalPlayer.UserId local locate = script.Parent.Parent:WaitForChild('ShowHide') function Unhide() if Destiny == 60787641 then locate:TweenPosition(UDim2.new(0,0,1,-50),"Out","Quad",1,false) else end
end
Unhide()
local frame = script.Parent.Parent.Parent:WaitForChild('MusicList') local hidden = true script.Parent.MouseButton1Click:connect(function() if hidden == true then frame:TweenPosition(UDim2.new(0,0,1,-200),"Out","Quad",1,false) hidden = false wait(1)
else frame:TweenPosition(UDim2.new(0,-101,1,-200),"Out","Quad",1,false) hidden = true wait(1)
end
end)
|
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 04:58 PM |
and yea the offset/scale thing XD
|
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 05:00 PM |
Are you really making a game for you daughter and if so what type of game is it?
|
|
|
| Report Abuse |
|
|
|
| 09 Sep 2016 05:04 PM |
Why not use the 'Visible' property :/
|
|
|
| Report Abuse |
|
|
TheJim87
|
  |
| Joined: 12 May 2014 |
| Total Posts: 54 |
|
|
| 09 Sep 2016 05:06 PM |
| It's an RPG and she wanted to be a big part of the game development. It's friends only. I literally only have the music, the world, and the first dungeon complete. I don't have any monster, bases, or objectives such as mining or woodcutting yet. I gave everyone a sword and a few toys and let everyone bring their own toys/weapons in as well. It's going to take me forever to make this, but I will add you if you would like to check it out. I made it with keeping about the Xbox in mind too, so I kept the GUI simple. |
|
|
| Report Abuse |
|
|
TheJim87
|
  |
| Joined: 12 May 2014 |
| Total Posts: 54 |
|
|
| 09 Sep 2016 05:06 PM |
| The green beam of light points you towards the "easy" dungeon that is complete... |
|
|
| Report Abuse |
|
|