generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: How To Display A GUI When...

Previous Thread :: Next Thread 
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:02 PM
Mouse hovers over a different one? I have no clue how to do this...
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:05 PM
im pretty sure the command is MouseEnter
Report Abuse
fireblade2 is not online. fireblade2
Joined: 18 Nov 2007
Total Posts: 4666
25 Mar 2014 03:07 PM
Yes,

GuiObject.MouseEnter:connect(function()
--Code here executes when the player mouses over GuiObject
end)
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:09 PM
thanks fire ! :D
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:12 PM
yes, thank you!
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:15 PM
Erm. How do I make it so that when the mouse leaves that area, it goes away? Is that in the same script?
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:16 PM
i hope your juggernaut game turns out nicely :D
Report Abuse
KEVEKEV77 is not online. KEVEKEV77
Joined: 12 Mar 2009
Total Posts: 6961
25 Mar 2014 03:16 PM
MouseLeave?
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:17 PM
yes it is MouseLeave
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:18 PM
Nevermind. I got it. You just use "MouseLeave."
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:18 PM
Lol I didn't see all of your replies. And thanks, yum!
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:18 PM
so it would turn out

blah.MouseEnter:connect(function()
blah.Visible = true
end)

blah.MouseLeav:connet(funtion()
blah.Visible = false
end)
Report Abuse
YumERAGON is not online. YumERAGON
Joined: 18 Apr 2012
Total Posts: 3893
25 Mar 2014 03:19 PM
MouseLeave:connect* sorry
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:37 PM
I got it all figured out. I don't know if you want to see how I implemented it, but you can by inviting me to a party and following me. Also, if you want to see my game. xD
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:52 PM
Um, why does it only work in solo mode for me?
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
25 Mar 2014 03:56 PM
Localscript and getmouse?
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 03:58 PM
Local script, yes, but no GetMouse? How do I do that?
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 04:08 PM
Bump
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
25 Mar 2014 04:12 PM
Define the player and do
local mouse = player:GetMouse()


I think that's correct, don't use it much.
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 04:16 PM
And you don't even have to use it in the actual script?
Report Abuse
RoflBread is not online. RoflBread
Joined: 18 Jun 2009
Total Posts: 3803
25 Mar 2014 04:18 PM
You don't need to define the mouse if you are using GUI events.
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
25 Mar 2014 04:18 PM
Before you do the rest of the script just do

local player = game.Players.LocalPlayer

mouse = player:GetMouse()

--rest of script with mouse enter and stuff





That should work.
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 04:21 PM
Didn't work in online mode, but it solo. Who knows why?
Report Abuse
RoflBread is not online. RoflBread
Joined: 18 Jun 2009
Total Posts: 3803
25 Mar 2014 04:23 PM
err, could you post the script~?
Report Abuse
TexasTech717 is not online. TexasTech717
Joined: 24 Apr 2012
Total Posts: 1129
25 Mar 2014 04:47 PM
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()
local info = script.Parent.Parent.AJInfo

script.Parent.MouseEnter:connect(function()
info.Visible = true
end)

script.Parent.MouseLeave:connect(function()
info.Visible = false
end)
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image