Project2dJoin Date: 2010-07-19 Post Count: 417 |
Is it possible to compare UDim2 position to mouse position to position a Gui at where the mouse is?
Or is this not possible? Help! :P |
|
walter232Join Date: 2009-06-07 Post Count: 451 |
gui.Position=UDim3.new(0,mouse.x,0,mouse.y)? |
|
SIimeJoin Date: 2010-11-02 Post Count: 16 |
script.Parent.MouseButton1Down:connect(function(x,y)
script.Parent.Parent.LolFrame.Position = UDim2.new(0,x,0,y)
end) |
|
walter232Join Date: 2009-06-07 Post Count: 451 |
Whoops, UDim2... |
|
jmbombJoin Date: 2008-11-26 Post Count: 2311 |
OHAI ALT :P |
|
KenetecJoin Date: 2009-11-26 Post Count: 1662 |
If you use a tool, you have constant access to the mouse. If you use a normal GUI, you can only access the mouse if the mouse is inside a TextButton or Image Button. |
|
Julian365Join Date: 2008-07-19 Post Count: 980 |
[ Content Deleted ] |
|
AgentFirefoxTop 100 PosterJoin Date: 2008-06-20 Post Count: 22404 |
"If you use a tool, you have constant access to the mouse. If you use a normal GUI, you can only access the mouse if the mouse is inside a TextButton or Image Button."
Wrong.
All non-frame and non-ScreenGui objects have the MoveMoved event. The MouseMoved event returns the X, Y coordinates of the mouse with respect to the ScreenGui. |
|
DuVaLPwnTJoin Date: 2010-08-15 Post Count: 190 |
AgentFirefox, does it return the absolute position? I might make one. |
|
AgentFirefoxTop 100 PosterJoin Date: 2008-06-20 Post Count: 22404 |
That's what the position is with respect to the ScreenGui, so yes. |
|
DuVaLPwnTJoin Date: 2010-08-15 Post Count: 190 |
Thanks. |
|
hyrumcoopJoin Date: 2009-03-21 Post Count: 618 |
function Move(mouse)
Frame.Position = UDim2.new(0, mouse.X, 0, mouse.Y)
end |
|
AgentFirefoxTop 100 PosterJoin Date: 2008-06-20 Post Count: 22404 |
He doesn't want a Tool/HopperBin. |
|
|
But is it possible to cover the mouse and change it's icon. |
|
AgentFirefoxTop 100 PosterJoin Date: 2008-06-20 Post Count: 22404 |
The mouse always has a higher ZIndex than the GUI objects. |
|
|
Udim19291731321312312321321321 |
|
KaluosiJoin Date: 2010-04-05 Post Count: 6361 |
So is that a yes or no?!? |
|
KenetecJoin Date: 2009-11-26 Post Count: 1662 |
You can't change the mouse from a GUI, or cover the mouse witha GUI. But, you CAN change the mouse with a tool/HopperBin.
mouse.Icon="htttp://www.roblox.com/asset/?id=######" |
|
KaluosiJoin Date: 2010-04-05 Post Count: 6361 |
Amen. |
|
turbodazeJoin Date: 2008-12-17 Post Count: 2169 |
"Amen."
lol |
|
KaluosiJoin Date: 2010-04-05 Post Count: 6361 |
Yes, Amen. |
|