I’m surprised drag detectors still have the same problem as click detectors: they simply don’t work on fast moving parts. I’ll drop a link below if a staff ever notices this message and decide to resolve this problem.
@PrinceTybalt there still is an issue with the dragdettectors on mobile if I want to drag my puzzle it doesn’t directly drag and it are time based puzzles so it almost impossible to complete it in 1 min but I think I want it 30 sec buy the camera go before the dragdetectors able if I drag on the left
When the Drag Detector is added during the game and the responseStyle being physical, it does not work. It seems to only work if it is present from the beginning of the game.
I assume this is a bug, if not how am I able to fix this
I have been having problem with DragDetector while developing a plugin with widget window, it worked first time but after I relaunch studio DragDetector just stopped working.
Related problem: Drag Detectors not working in studio Introducing UIDragDetectors [Studio-only Beta] - #285 by PepeElToro41
I couldn’t pin point the problem but dragdetector just doesn’t work in plugin widget. I tried turning off all plugins(beside one am developing) and it still doesn’t work.
I resolved this problem though it is weird, drag is disable whenever tool or UIEditor is in-use… but in my situation an UI covered your screen when you launch studio it disable the drag? If anyone experiencing drag not working while making plugin disable GUI Overlay.
Hello! I’ve been working on a system as of late that uses DragDetectors in order to move stuff.
The main problem I am facing is that DragDetectors dont work when created via the client. I assume this is for safety reasons, but if there was a way to allow the client to create and use a DragDetector, that would automatically on run locally (for obvious reasons) would be very useful!
Since that probably wont happen I was wondering if you had any recommendations for a work around that’d help a ton, as I’ve been stuck on this issue for a couple hours now.
Currently not exactly something I can do, as changing the parent of the DragDetector via the client also makes it stop working. And I cant exactly parent the DragDetector via the server, as the thing I need to parent it to is only on one client.
FIXED [cursorRay gives a distance of 2048 and shapecasts max distance is half of that]
is it possible to do shapecast for the drag detectors?
I tried to do it but it says there is an error
--module script
return function(cursorRay, dragDetector, object)
local raycastParams = RaycastParams.new()
raycastParams.FilterDescendantsInstances = {object}
raycastParams.FilterType = Enum.RaycastFilterType.Exclude
local raycastResult = workspace:Shapecast(object, cursorRay.Direction, raycastParams)
local hitPosition = raycastResult.Position
return CFrame.new(hitPosition)
end
I also got another question, is it possible to tween the drag detector’s geometric response style to be smooth as physics without the physics.
i got it to work, just had to zero out the distance
and also return the distance of the blockcast rather than the position of where blockcast hits
return function(cursorRay : Ray, dragDetector : DragDetector, object : BasePart) : CFrame
local params = RaycastParams.new()
params.FilterDescendantsInstances = {dragDetector.ReferenceInstance, object}
params.FilterType = Enum.RaycastFilterType.Exclude
local direction = (cursorRay.Direction).Unit
local blockcast = workspace:Blockcast(CFrame.new(cursorRay.Origin), object.Size, direction * 1000, params)
if blockcast then
return CFrame.new(cursorRay.Origin + direction * blockcast.Distance)
end
end
i believe for it to work on the client, you’ll need a local script and check run locally on drag detector
just tested it and the client physics are quite broken