Here is a custom mouse module I made which has almost all the useful features of the legacy mouse. No function call involved and the good thing is that the values aren’t updated every frame or in a loop except for 2 which is reasonable.
I may plan to open source this module for anyone to use.
These are the current functions:
I like abstraction that layer on top of existing functionality, but we have to look at this from an unbiased perspective.
I can definitely see myself utilizing this if it had more to it. Right now, it’s a good replacement for the legacy mouse features; however it’s almost not feature-rich enough to warrant using it. Just yet.
For instance, you’ve done great in recreating some really handy properties that existed on the old mouse but not on the new user input service; however, to really sell it I’d love to see more functionality built off of this. Such as some custom methods that are annoying to script and people would rather just get your module for.
For example,
mouse:beginSelectionBox()
local coords = mouse:endSelectionBox()
local tableOfParts = mouse:getPartsInSelectionBox(coords)
Would be a cool addition and definitely make me wanna start using your module!