dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 10:03 AM |
| Hey, I'm wondering how Merely and a couple others made it so when you hover over someone it makes a BillBoard GUI visible, and if you click on them a GUI pops up? How is that made? Any idea's? I'm clueless :b |
|
|
| Report Abuse |
|
|
Looah
|
  |
| Joined: 22 Feb 2013 |
| Total Posts: 922 |
|
|
| 27 Feb 2013 10:05 AM |
| use mouse.Target and check if it hovers over a character. |
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 01:05 PM |
| How could I go about doing that? I'm rather new to coding.... |
|
|
| Report Abuse |
|
|
Zulsoras
|
  |
| Joined: 10 Sep 2008 |
| Total Posts: 963 |
|
|
| 27 Feb 2013 01:13 PM |
| im taking a WILD guess and saying that what they did is on respawn gave every player a script and clickdectector insert that made it so that when you clicked their chest it copied the billboard gui inside of the script inside of the players chest and made its parent the players head and made it visible |
|
|
| Report Abuse |
|
|
Zulsoras
|
  |
| Joined: 10 Sep 2008 |
| Total Posts: 963 |
|
|
| 27 Feb 2013 01:15 PM |
so 1.) make a on respawn script 2.) make it so it gives players a script, and a Click Detector 3.) Put a billboard Gui in that script 4.) code the script so that it is a OnClick() function that copies its child - makes it visible and makes its parent the players head |
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 03:15 PM |
Thing is, I want it so when your cursor hovers over the person the Billboard GUI comes up, and when you click on them it shows the GUI on your screen.
|
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
| |
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
| |
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 04:00 PM |
| BumberCow :3 But seriously, any idea's? |
|
|
| Report Abuse |
|
|
Fedorakid
|
  |
| Joined: 17 Jul 2010 |
| Total Posts: 7079 |
|
|
| 27 Feb 2013 04:02 PM |
| I doubt ur even new to it.This sounds like a request.NO REQUESTS. |
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 04:05 PM |
It's not a request. I am simply trying to figure out, how to call if someone hovers over you, the gui pops up. would I use "function OnMouseHover() end script.Parent.MouseEnter:connect(OnMouseHover)" Or something different? |
|
|
| Report Abuse |
|
|
|
| 27 Feb 2013 04:30 PM |
hmm try this in a localscript in StarterGui?
local player = Game.Players.LocalPlayer local mouse = player:GetMouse()
local function ClickedPlayer(WhoClicked,WhoWasClicked) print(WhoClicked.Name.." Clicked on: "..WhoWasClicked.Name) end
mouse.Button1Down:connect(function() local target = mouse.Target if target:IA("Part") and target.Parent then local Who = Game.Players:GetPlayerFromCharacter(target.Parent) if Who then ClickedPlayer(player,Who) end end end) |
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 04:40 PM |
| What exactly will that do?^^ |
|
|
| Report Abuse |
|
|
|
| 27 Feb 2013 04:40 PM |
| If you wanted to make it hover i would just use the .Changed event and not .MouseButton1Down |
|
|
| Report Abuse |
|
|
|
| 27 Feb 2013 04:42 PM |
this would to whatever is in the "ClickedPlayer" function whenever you hover over a person.
local player = Game.Players.LocalPlayer local mouse = player:GetMouse()
local function ClickedPlayer(WhoClicked,WhoWasClicked) --Make Gui Visible Here end
mouse.Changed:connect(function(l) if not l == "Target" then return end local target = mouse.Target if target:IA("Part") and target.Parent then local Who = Game.Players:GetPlayerFromCharacter(target.Parent) if Who then ClickedPlayer(player,Who) end end end) |
|
|
| Report Abuse |
|
|
dyudabomb
|
  |
| Joined: 06 Jun 2010 |
| Total Posts: 113 |
|
|
| 27 Feb 2013 05:04 PM |
Should this work?
local player = Game.Players.LocalPlayer local mouse = player:GetMouse()
local function ClickedPlayer(WhoClicked,WhoWasClicked) local gui = script.ScreenGui.Frame.Playername:clone() script.ScreenGui.Frame.Playername.Text = WhoWasClicked wait() gui.Parent = game.Players.WhoClicked.PlayerGui Players.WhoClicked.PlayerGui.ScreenGui.Frame.Visible = true end
mouse.Changed:connect(function(l) if not l == "Target" then return end local target = mouse.Target if target:IA("Part") and target.Parent then local Who = Game.Players:GetPlayerFromCharacter(target.Parent) if Who then ClickedPlayer(player,Who) end end end) |
|
|
| Report Abuse |
|
|