GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 06:50 PM |
i want to make a button on a gui that says get up for my skate park. this is my first gui ever. i read that article on roblox wiki on making my first gui. so far i got the frame the size i want. lol. i want to make a textbutton that says "Get up". how do i make the rest and how do u insert bodygyro into the players torso wen they enter?
thanks in advance GGss6 |
|
|
| Report Abuse |
|
|
|
| 15 Aug 2011 07:04 PM |
To make a Reset Gui. Get the Local Player (Must be a LocalScript):
guy = game.Players.LocalPlayer
And then when they click the button. Find the character and Change the Humanoid's Health to Zero. ______________________________________
And for BodyGyro. Use .PlayerAdded or .ChildAdded Example:
game.Players.PlayerAdded:connect(function(p) --Code here end)
I have a question. Why do you want BodyGyro for??? It's only used to keep a brick a facing a certain way i think last time i checked. |
|
|
| Report Abuse |
|
|
|
| 15 Aug 2011 07:07 PM |
"Skate park"
I think he wants Bodygyro to keep a character facing the way of the board.
~Greedy |
|
|
| Report Abuse |
|
|
GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 07:17 PM |
| i need bodygyro because im making a skate park and if u fall u need to b able to get back up. |
|
|
| Report Abuse |
|
|
tdog158
|
  |
| Joined: 08 Jul 2008 |
| Total Posts: 5413 |
|
|
| 15 Aug 2011 07:18 PM |
Actually BodyGyro's can be used to keep the TopSurface of a brick facing upwards, or your way, or both. Here is the script for your simple button.
on=false script.Parent.MouseButton1Down:connect(function() if not on then on=true b=Instance.new("BodyGyro",script.Parent.Parent.Parent.Parent.Character.Torso) wait(2) b:remove() on=false end end)
This might not work with skateboards but it's worth a shot. |
|
|
| Report Abuse |
|
|
GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 07:41 PM |
| well how do u put the bodygyro in the torso? |
|
|
| Report Abuse |
|
|
tdog158
|
  |
| Joined: 08 Jul 2008 |
| Total Posts: 5413 |
|
| |
|
GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 07:51 PM |
ok, now this is my first gui so where do i put the script? i have it startergui>screengui>frame>textbutton>script (the one that you gave me). is this how you do it is there somthing wrong?
|
|
|
| Report Abuse |
|
|
|
| 15 Aug 2011 08:00 PM |
| You can do it inside of the TextButton or outside of it or anywhere inside the ScreenGui. Doesn't matter. As long as you define what they click correctly. |
|
|
| Report Abuse |
|
|
GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 08:03 PM |
| y doesnt anyone understand?!?! im asking if i did this right!! look 2 posts above! im asking if i have everything in the right places!! |
|
|
| Report Abuse |
|
|
GGss6
|
  |
| Joined: 20 Dec 2009 |
| Total Posts: 30 |
|
|
| 15 Aug 2011 08:04 PM |
| actually i obv dont cuz i cant press the button |
|
|
| Report Abuse |
|
|
tdog158
|
  |
| Joined: 08 Jul 2008 |
| Total Posts: 5413 |
|
|
| 15 Aug 2011 08:29 PM |
| Then use a TextButton and not a TextLabel. |
|
|
| Report Abuse |
|
|