I have wanted to achieve move the map with your mouse, like in shown in the video from ERLC.
I’m using a picture of the map rendered in a Viewport Frame.
Maybe I am just bad at searching, or nobody really had a problem with it.
I hope somebody can help me.
I assume that the origin of the ViewportFrame is being translated by mouse movement. It is like being able to control the position of the camera man.
That is basically the question: How do I track the mouse Movement and translate it into camera Movement.
You can listen for
MouseButton1Down event (on a image button that covers the viewport frame) then use
I tought, Mouse.Move is only an event, that fires when the mouse is moved.
It is, but if you combine it with
MouseButton1Down you can detect click and drag, just make sure you disconnect the event once the mouse is let up (
So, I have made this messy Script.
local Maus = Player:GetMouse()
local Move = Maus.Move:Connect(function()
But in Output, it only gives me a Signal and no Data to work with.