flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
|
| 24 Jul 2013 06:45 PM |
To my understanding, roblox doesn't detect seat gui's anymore, so I was wondering how I would get he seat to. I don't think anything in my lua script is wrong, except I don't have a way for the seat to detect my gui, and I'm not sure how to make the script stop after the textbox is pressed (press once, and the script will run, press again and it will stop).
If anyone could write a piece of lua that makes the gui appear when sitting, and disappear when not on the chair/dead, that would be nice, thanks!
My lua script :
function onClick(mouse) game.Workspace.HEAT MP SUV.HEAT MP SUV.MPLights.Red1.PointLight.Brightness = 10 wait (.25) game.Workspace.HEAT MP SUV.HEAT MP SUV.MPLights.Red1.PointLight.Brightness = 0 wait (.25) game.Workspace.HEAT MP SUV.HEAT MP SUV.MPLights.Red2.PointLight.Brightness = 10 wait (.25) game.Workspace.HEAT MP SUV.HEAT MP SUV.MPLights.Red2.PointLight.Brightness = 0 wait (.25) game.Workspace.HEAT MP SUV.HEAT MP SUV.MPLights.Blue1.PointLight.Brightness = 10 wait (.25) while true do end
|
|
|
| Report Abuse |
|
|
|
| 24 Jul 2013 07:19 PM |
You could put a script in the seat that detects when a weld is added. From there you can trace the player through the weld and give said player the gui.
As for the actual script, most people on scripting helpers would rather edit a script than make one for you. |
|
|
| Report Abuse |
|
|
flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
|
| 24 Jul 2013 07:45 PM |
| Thanks, and the reason I was asking for the script section to be made is that this is my first script, aside from "hello world". I hate to say this next part, but how do i trace the weld back? ._. |
|
|
| Report Abuse |
|
|
flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
| |
|
Xtreme101
|
  |
| Joined: 03 Jan 2009 |
| Total Posts: 4385 |
|
| |
|
flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
|
| 24 Jul 2013 09:40 PM |
:(
How would I go about doing that, Xtreme? |
|
|
| Report Abuse |
|
|
flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
| |
|
flager67
|
  |
| Joined: 03 Jul 2008 |
| Total Posts: 205 |
|
| |
|
Xtreme101
|
  |
| Joined: 03 Jan 2009 |
| Total Posts: 4385 |
|
|
| 25 Jul 2013 01:13 PM |
A the parent of an object is what the object is located under. As an example if a part is not in a model, it's likely located under workspace. I cannot fix your script because I don't know the origins of the weld, but here's another example of locating the Parent:
If a script is under a part, and that part is not in a model workspace would be:
script.Parent.Parent |
|
|
| Report Abuse |
|
|