|
| 09 Mar 2014 06:21 PM |
Alright so I have put a surfacegui in startergui/playergui and have set the brick to adorn to. However, it is not reacting to any mouse events at all.
I've used events such as this:
script.Parent.MouseButton1Down:connect(function() print("regular script works") end)
I followed what the wiki has instructed: "Note: SurfaceGuis must be descendants of PlayerGui in order to know the player who is interacting with it."
What am I doing wrong? |
|
|
| Report Abuse |
|
|
mycheeze
|
  |
| Joined: 27 Jun 2011 |
| Total Posts: 6748 |
|
|
| 09 Mar 2014 06:25 PM |
What you're doing wrong is you forgot that scripting is, oh ho ho it's magik, like-
Also while you're at it, go to youtube and search mr.bean magic snort snort. It will cheer you up in this time of stressing testing. |
|
|
| Report Abuse |
|
|
| |
|
mycheeze
|
  |
| Joined: 27 Jun 2011 |
| Total Posts: 6748 |
|
|
| 09 Mar 2014 06:30 PM |
Oh, and umm if you have the player limit set to 1, you could do this.
Person = game.Players:GetChildren() if #Person == 1 then Player = Person[1]end
So now you can have a surface gui be a child of a part rather than a StarterGui and when you want to interact with a player you can just type
Player.Character.Head.Transparency = 1 -- For example |
|
|
| Report Abuse |
|
|
|
| 09 Mar 2014 06:32 PM |
| I'm sure that would work with a server with over 30 people. |
|
|
| Report Abuse |
|
|
mycheeze
|
  |
| Joined: 27 Jun 2011 |
| Total Posts: 6748 |
|
| |
|
| |
|
| |
|
Bebee2
|
  |
| Joined: 17 May 2009 |
| Total Posts: 3985 |
|
|
| 10 Mar 2014 04:38 AM |
Place the SurfaceGui inside StarterGui and replace the server script with a localscript
That's one option that I am 100% sure of. |
|
|
| Report Abuse |
|
|
|
| 10 Mar 2014 04:47 AM |
I tried that earlier. Also does the brick being part of a model affect it at all? |
|
|
| Report Abuse |
|
|
Bebee2
|
  |
| Joined: 17 May 2009 |
| Total Posts: 3985 |
|
|
| 10 Mar 2014 04:49 AM |
No, but the button has to be over the part to fire. Also, used a LocalScript. If there OTHER surface guis on the SAME part, neither events will fire I think. |
|
|
| Report Abuse |
|
|
|
| 10 Mar 2014 04:51 AM |
Actually being part of the model did effect it. Just tested it outside of the model. I'm thinking of a solution right now, thanks for the help. |
|
|
| Report Abuse |
|
|
Bebee2
|
  |
| Joined: 17 May 2009 |
| Total Posts: 3985 |
|
| |
|
|
| 10 Mar 2014 04:55 AM |
Nevermind that statement, I found that a brick mesh was blocking the actual surface. -___- |
|
|
| Report Abuse |
|
|