of course theres a way to do this!
first youll need to find the mousex?, mousey? as i call them
? just meaning change in but thats not important
to find these, your going to need to make 2 new variables, they can be global or object, doesnt matter really, personally id store them in the cursor sprite just to keep things organised
then your going to need your everyday vanilla "always" condition.
make your two variables called MDeltaX and MDeltaY
then set MDeltaX, to mousex, and MDeltaY to mousey
simple enough as it is
now youre going to want to make your event to move the cursor object, ill call the object CursorS since i dont know your cap
Make sure that you remove all events that change the position of this object in anyway in the events following this, or else it might not work
so make a new action of "set position" for CursorS
set X: .x+(mousex-'MDeltaX')*('MouseSpeed')
set y: .y+(mousey-'MDeltay')*('MouseSpeed')
this should be ABOVE the set MDeltaX,MDeltaY actions
MouseSpeed is another variable of CursorS, if you set it to 1, the mouse speed will be normal, 2 will be twice as fast, 0.5 half as fast, etc.
your code should look as follows:
[quote:qyf8c0xp]
Always:
CursorS: set position:[quote:qyf8c0xp]set X: .x+(mousex-'MDeltaX')*('MouseSpeed')
set Y: .y+(mousey-'MDeltay')*('MouseSpeed')
CursorS: Set 'MDeltaX' to:[quote:qyf8c0xp]MouseX
CursorS: Set 'MDeltaY' to:[quote:qyf8c0xp]MouseY
thats it!
As for smoothing... you wouldnt really need cos or sin, but youd have to make 2 more variables and make them "follow" MdeltaX and MdeltaY, so that they can only gradually change over time
its a bit complicated:
youd need 'Mfx' and 'Mfy', and youd need to change the set position event to use those instead of 'MdeltaX/MdeltaY'
then youd add two new actions above the set position event for CursorS
set Mfx to: 'Mfx'+('MdeltaX'-'Mfx')*0.5
set Mfy to: 'Mfy'+('MdeltaY'-'Mfy')*0.5
you could play around with the 0.5, if you made it closer to 0 it would smooth slower, if you made it closer to 1 it would smooth faster
your code should look as follows:
[quote:qyf8c0xp]
Always:
CursorS: Set 'Mfx' to:[quote:qyf8c0xp]'Mfx'+('MdeltaX'-'Mfx')*0.5
CursorS: Set 'Mfy' to:[quote:qyf8c0xp]'Mfy'+('MdeltaY'-'Mfy')*0.5
CursorS: set position:[quote:qyf8c0xp]set X: .x+(mousex-'Mfx')*('MouseSpeed')
set Y: .y+(mousey-'Mfy')*('MouseSpeed')
CursorS: Set 'MDeltaX' to:[quote:qyf8c0xp]MouseX
CursorS: Set 'MDeltaY' to:[quote:qyf8c0xp]MouseY
if any of this doesnt work just ask, i or u might of made a mistake.