SRL Archive - Help

draging an inventory item


Footy

2012-07-08 09:21:25

So in my alching script, which is purely for rune arrows, at the beginning, im trying to get the rune arrows into slot 17, which is where most humans would have it when they are alching. Im using a dtm of rune arrows to find rune arrows, but the dragitem function requires an invspace, not co-ordinates. How would I get it so it would find the arrows, then move them to invspace 17?
E: this is what I have so far
Gametab(25);
If not existsitem(17) then
finddtm(RArrows, x, y, MIX1, MIY1, MIX2, MIY2);
dragitem(

CephaXz

2012-07-08 09:25:09

Use dragmouse.

Footy

2012-07-08 09:26:31

Thanks Cepha! wasnt aware of that function! It should work fine now!

The Killer

2012-07-08 09:29:12

From: CephaXz
Use dragmouse.

an alternative would be
MouseMouse(1, 1)
Holdmouse(1, 1, 1)
Movemouse(2, 2)
releasemouse(2, 2)

CephaXz

2012-07-08 09:30:43

From: The Killer
an alternative would be
MouseMouse(1, 1)
Holdmouse(1, 1, 1)
Movemouse(2, 2)
releasemouse(2, 2)


DragMouse works more like a human, even with randomization :p

Footy

2012-07-08 09:31:44

@killer
Generally, those functions are very bot like, never ever use movemouse, it will move it a straight line, always use Mmouse. dragmouse is like what you showed, but much much much more human like.

The Killer

2012-07-08 09:35:48

From: Foooty
@killer
Generally, those functions are very bot like, never ever use movemouse, it will move it a straight line, always use Mmouse. dragmouse is like what you showed, but much much much more human like.


ima be a noob :p
so Mmouse is move mouse but less robotic??
feeling stupid now :p:duh:

CephaXz

2012-07-08 09:39:03

From: The Killer
ima be a noob :p
so Mmouse is move mouse but less robotic??
feeling stupid now :p:duh:


Mouse speed is different. MoveMouse moves like godspeed :D

I once used those functions too :p
You can still use those functions if you're making a script for maybe a flash game or private servers.

The Killer

2012-07-08 15:42:31

From: CephaXz
Mouse speed is different. MoveMouse moves like godspeed :D

I once used those functions too :p
You can still use those functions if you're making a script for maybe a flash game or private servers.


what do i need to put in brackets for Mmouse if my cords are (498, 25)?

Footy

2012-07-08 15:52:29

If you are planning to click, use Mouse, it moves and clicks all in one function. The parameters for mouse are(x, y, ranx, rany, button) x and y are the coordinates, ranx and rany are randomness, I usually do 5-10, and button is 1 for left click, 2 for right click, and im not sure what 3 is. If you just want to move the mouse, MMouse parameters are (x, y, ranx, rany)

The Killer

2012-07-08 16:14:32

From: Foooty
If you are planning to click, use Mouse, it moves and clicks all in one function. The parameters for mouse are(x, y, ranx, rany, button) x and y are the coordinates, ranx and rany are randomness, I usually do 5-10, and button is 1 for left click, 2 for right click, and im not sure what 3 is. If you just want to move the mouse, MMouse parameters are (x, y, ranx, rany)


yes i plan on clicking, i just typed aload of
Mmouse (123, 123)
Clickmouse(123, 123)

-.- thanks for this so it should be
Mouse(123, 123, ranx, rany, 1)

? bit lost on what ranx and rany is :s

Footy

2012-07-08 16:17:20

Exactly, if you are planning on clicking, always use Mouse, its the most humanlike. ranx, and rany are randomness to your x and y variables. say your x value was 10, and your y value was 20. Should you set the randomness to 5 for both x and y, it will click between 5 and 15 for x, and 15 and 25 for y. Basically, it ensures you arent always clicking on the same pixel. Does that clear up any confusion? if not, I could go more indepth with a diagram, :D

The Killer

2012-07-08 16:20:36

From: Foooty
Exactly, if you are planning on clicking, always use Mouse, its the most humanlike. ranx, and rany are randomness to your x and y variables. say your x value was 10, and your y value was 20. Should you set the randomness to 5 for both x and y, it will click between 5 and 15 for x, and 15 and 25 for y. Basically, it ensures you arent always clicking on the same pixel. Does that clear up any confusion? if not, I could go more indepth with a diagram, :D


no need, thats great :) i actually understand :p
now to edit my first script

Footy

2012-07-08 16:22:47

Good luck! May I ask what its a script for? Id be more then happy to test it for you when you're done.

CephaXz

2012-07-10 07:54:40

Sorry, went out after I replied you yesterday :p

Good luck on your script!