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 » Scripters
Home Search
 

Re: Mouse hover gui script

Previous Thread :: Next Thread 
Danfly is online. Danfly
Joined: 25 Feb 2012
Total Posts: 551
30 Aug 2016 09:36 PM
Hello,
Basically I need help fixing a script to make it so when your mouse hovers over a block a GUI comes up and when you move it off the block it disappears. An example of this is in the ROBLOX Library. or in this gy@zo#####h I will show below

f5e27314c2264a3ab69c56724740e333

I've had my friend look at it and he wrote a few notes on the script. Basically the items that you may need to edit or change or stuff that is related is
'book' in workspace (DON'T edit that script, that is just a script to show the pages etc)

'GUI' located inside the book part. You may need to change this from surface gui to screen gui and visa versa

RemoteEvent located in Replicated Storage

Another script that has something to do with playerGUI I'm not 100% sure located in ServerScript Service

MAIN ONE: Clickinator which is located in StarterGUI, my friend wrote some notes for it to help the scripter who is to script it

If someone could please make this work it will be very appreciated thanks :)


Report Abuse
Danfly is online. Danfly
Joined: 25 Feb 2012
Total Posts: 551
30 Aug 2016 09:36 PM
The hashed word is 'which'





Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
30 Aug 2016 09:37 PM
just use mouse.Changed

and use it to set the Target

and if the Target is on top of that object, make the gui visible
Report Abuse
Danfly is online. Danfly
Joined: 25 Feb 2012
Total Posts: 551
30 Aug 2016 09:37 PM
Forgot to add, this is the game, take a copy and fix it for me please

https://www.roblox.com/games/409815826/Danflys-Place-Number-101


Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
30 Aug 2016 09:38 PM
local targ
mouse.Changed:connect(function()
targ = mouse.Target
gui.Visible = (targ==part)
end)

(target == part) will return true if it is the same and if it is not, will return false
Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
30 Aug 2016 09:40 PM
the shortest way to do it:

local gui = yourgui
local part = thepart
game.Players.LocalPlayer:GetMouse().Changed:connect(function()
gui.Visible = (game.Players.LocalPlayer:GetMouse().Target==part)
end)
Report Abuse
Danfly is online. Danfly
Joined: 25 Feb 2012
Total Posts: 551
30 Aug 2016 09:44 PM
I'm inputting the code your saying above but I'm probably putting it in the wrong place. It would be well appreciated if you took the place and then fixed it and sent it back to me.
Thanks,


Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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