SRL Archive - General

MoveWindMouseEx in Simba


Gub

2011-03-30 14:43:03

Hi,
I have been using scar for ages and finally decided to switch to simba. Was just wondering if there was any way of moving the mouse like a human in simba?
Also is there anyway of stopping the script from running when simba isnt the active window? as F9 dosnt seem to work.
Thanks :)

Ogre

2011-03-30 14:48:12

{*******************************************************************************
procedure MMouse(x, y, rx, ry: integer);
By: Benland100
Laptop Movement by Hobbit with help from nielsie95!
Description: Moves the mouse.
*******************************************************************************}

{*******************************************************************************
procedure Mouse(mousex, mousey, ranx, rany: Integer; left: Boolean);
By: Mutant Squirrle, with a small fix by hy71194
Description: Moves then clicks mouse.
*******************************************************************************}
rx/ry and ranx/rany are an additional random amount to move the mouse

Those are the functions most people use to move or click the mouse, but there's others. (check out core/Mouse.scar)
I would think that would be the functions you were using in SCAR too, assuming you were using SRL..

sorry don't know about the second question

kitchenrange

2011-03-30 14:54:58

I believe the new button is F12. Could be wrong though.. Just hover your mouse over the stop script button for a second and it will show the shortcut.

i luffs yeww

2011-03-30 14:56:09

The second question, no. You have to make it the active window. :/

Gub

2011-03-30 15:11:17

From: i luffs yeww
The second question, no. You have to make it the active window. :/


That sucks, could stop scar when it wasn't active…

I was using MoveWindMouseEx in scar, will try using MMouse see what it looks like :)

i luffs yeww

2011-03-30 15:12:43

I know. The reason was how it was involved in the Windows API or something. And Delphi and closed etc.

Gub

2011-03-30 16:03:28

Tried using MMouse but it doesn't seem to work, just creeps along really slowly. Is it because i'm not using it for runescape?

i luffs yeww

2011-03-30 16:05:36

No, it's because you didn't add SetupSRL; at the start of your main loop. ;)

Dgby714

2011-03-30 16:05:45

From: Gub
Tried using MMouse but it doesn't seem to work, just creeps along really slowly. Is it because i'm not using it for runescape?


You need to SetupSRL;
or set MouseSpeed := 20;

Gub

2011-03-30 16:10:09

Brilliant thanks for the super fast replys! also just found that ctrl+alt+s stops the script :)

Wizzup?

2011-03-30 16:11:23

Ctrl + Alt + S stops the script (just like in SCAR). Globally bound on windows. :)

Camaro'

2011-04-06 21:46:46

From: Wizzup?
Ctrl + Alt + S stops the script (just like in SCAR). Globally bound on windows. :)


Is this feature new on Simba, because a while ago I remember I tried it and it didn't work.

Rich

2011-04-07 03:08:47

[QUOTE=Camaro';796689]Is this feature new on Simba, because a while ago I remember I tried it and it didn't work.I think it's just that the Simba window needs to be active for it to work.

Wizzup?

2011-04-07 03:59:14

From: Rich
I think it's just that the Simba window needs to be active for it to work.


No, it's globally bound in Windows. Perhaps it doesn't work when you are running multiple Simba's, but it should work.

i luffs yeww

2011-04-07 12:20:52

Multiple Simbas + Ctrl Alt S don't work. It will stop the one that's open first and then won't stop the second one, even if the second one is started first, and if the first one is closed.

Even if I open one then another, close the first one, and then run the second one I can't Ctrl Alt S.

(Just pointing these things out for info, not because I'm butthurt or anything :p)