View Full Version : Drop method?
Gaston7eze
12-22-2011, 10:53 PM
What´s the "Drop" Method to do ,when you want to drop things?
Thanks in advance.
YoHoJo
12-22-2011, 10:59 PM
What are you referring to?
A script's settings?
A specific piece of code?
I'm totally lost explain better please!
Gaston7eze
12-22-2011, 11:01 PM
What are you referring to?
A script's settings?
A specific piece of code?
I'm totally lost explain better please!
If i want to for example drop a "Log" on Runescape,what piece of code should i use?Thanks.
onilika
12-22-2011, 11:03 PM
There are two methods of dropping. One is slower than the other.
Using mousekeys ( YoHoJo made one procedure/function ), and there is the normal dropping method ( when you use mouse to drop it ).
Both of them can be used on scripts.
using mouse:
begin
for I := 1 to 28 do // these are the slots from your inventory
begin
DropItem(I); // Will drop items from Slots mentioned on 'I'
Wait(50 + Random(100));
end;
mousekeys procedure:
http://villavu.com/forum/showthread.php?t=68528&highlight=mousekeys
Hope that was your doubt!
~onilika
YoHoJo
12-22-2011, 11:05 PM
Onilika, that would work but only if your entire inventory was logs. Would be better to make sure they were logs first.
You can watch this video
http://youtu.be/SlS4q9MiFX4
Or read this guide
http://villavu.com/forum/showthread.php?t=564
To learn how to make DTMs, dtms are nice for dealing with items.
:D
Gaston7eze
12-22-2011, 11:05 PM
There are two methods of dropping. One is slower than the other.
Using mousekeys ( YoHoJo made one procedure/function ), and there is the normal dropping method ( when you use mouse to drop it ).
Both of them can be used on scripts.
using mouse:
mousekeys procedure:
Hope that was your doubt!
~onilika
Thanks,and ,one more thing,
Im actually searching for the player to stay in a determinated zone,as it goes chopping all the trees a long Runescape,How can i do the player to stay in one spot?Thanks.
onilika
12-22-2011, 11:07 PM
Hmmm, that part. You would have to 'draw' a box around the ' screen '. I've heard about it, not very well, but never tried :/
Can't help you with that. As soon as I understand it, I will happily share :)
E: Yes YoHoJo, was only giving an example! That would drop all your items from the inventory of course.
YoHoJo
12-22-2011, 11:08 PM
Is it a certain spot in particular?
Or, are you saying wherever you do happen to start it, you want it to stay near there?
Get what I'm asking?
Gaston7eze
12-22-2011, 11:11 PM
Is it a certain spot in particular?
Or, are you saying wherever you do happen to start it, you want it to stay near there?
Get what I'm asking?
It´s at Draynor Village,i want the player to stay there all the time.
onilika
12-22-2011, 11:23 PM
I'm sure it won't leave the place, unless you tell it to do so.
Make a good procedure to find the tree (right colours and all that), and you won't have that problem.
If runs from that spot, terminate the script, or do like a 'death path':
1- teles to lumbridge
2- use sps to go from lumbridge to Draynor Village, to that especific spot.
It Might not the be the best method. There might someone else with better ideas :)
~onilika
Gaston7eze
12-22-2011, 11:27 PM
I'm sure it won't leave the place, unless you tell it to do so.
Make a good procedure to find the tree (right colours and all that), and you won't have that problem.
If runs from that spot, terminate the script, or do like a 'death path':
1- teles to lumbridge
2- use sps to go from lumbridge to Draynor Village, to that especific spot.
It Might not the be the best method. There might someone else with better ideas :)
~onilika
Sorry,What is "Sps"?
onilika
12-22-2011, 11:28 PM
http://villavu.com/forum/showthread.php?t=66266&highlight=position+system
SRL Positioning System (a.k.a. SPS) is a 100% color "reflection-like" positioning system that allows for "tile-like" color walking. SPS was originally developed by marpis, and has since been developed by the SRL community.
Gaston7eze
12-22-2011, 11:33 PM
http://villavu.com/forum/showthread.php?t=66266&highlight=position+system
Ok,let me check it out,im gonna see.
Gaston7eze
12-23-2011, 10:51 AM
I have one more question.
Procedure DropLog;
Var
x,y,I:Integer;
begin
for I := 2 to 28 do
DropItem(I);
Wait(50 + Random(100));
end;
How could i replace the I in red?
onilika
12-23-2011, 11:46 AM
The I in red? What you mean?
Kyle Undefined
12-23-2011, 02:25 PM
Why do you want to replace the variable "I"?
Gaston7eze
12-23-2011, 02:32 PM
Why do you want to replace the variable "I"?
I want to replace I for Logs.
Kyle Undefined
12-23-2011, 02:37 PM
You don't have to replace "I" for logs. "I" is just a variable. What you have there will drop anything from Inventory spot 2-28.
Gaston7eze
12-23-2011, 02:38 PM
You don't have to replace "I" for logs. "I" is just a variable. What you have there will drop anything from Inventory spot 2-28.
The case is that it dont drop nothing when inventory is full
I will show you:
Begin
Status(wat);
Disguise(wat);
End;
Function InvMMouse(InvSlot:Integer) : boolean;
Var TB: TBox;
CurrPT : TPoint;
Begin
result := false;
GameTab(tab_inv);
Result := true;
Writeln('InvMousing:' + IntToStr(InvSlot));
TB := InvBox(InvSlot);
GetMousePos(CurrPT.x,CurrPT.y);
If PointInBox(CurrPT,TB) Then
MouseBox(Max(CurrPT.x-random(2),TB.x1),Max(CurrPT.y-random(2),TB.y1),
Min(CurrPT.x+random(2),TB.x2),Min(CurrPT.y+random( 2),TB.y2),3) //LOL Pro-human much!
Else
MouseBoxEx(TB.X1, TB.Y1, TB.X2, TB.Y2,14, 3);
End;
Procedure MouseKeyDrop;
var I, X, Y, tree: Integer;
SlotBox:TBox;
Begin
RockPattern:=[1,5,9,13,17,21,2,6,10,14,18,22,3,7,11,15,19,23,4,8 ,12,16,20,24];
OreMid := DTMFromString('78DA63CC626260E0606440054C601226CA5 84' +
'C849A3C209F8F809A6C209F19BF1A00AD2101F4');
For Tree:=0 to 23 Do
Begin
StatsGuise('Dropping Logs: ' + IntToStr(I));
SlotBox:=InvBox(RockPattern[I]);
If FindDTm(OreMid, X, Y, SlotBox.X1, SlotBox.Y1, SlotBox.X2, SlotBox.Y2) Then
Begin
Writeln('dtm found');
Writeln('I is:' + IntToStr(Logs));
If InIntArray([0,6,12,18], Logs) Then
Begin
Writeln('TopBox');
//InvMMouse(RockPattern[I]);
MMouse(X, Y, 5, 3);
End;
GetMousePos(X, Y);
Mouse(X, Y, 0, 0, False);
WaitOptionMultiEx(['Us'], 'item', Nothing, 5000);
MoveMouse(X, Y+40);
GetMousePos(X, Y); ClickMouse(X, Y, mouse_Left);
Wait(50+Random(20));
End;
End;
End;
Begin
SetUpSRL;
MouseKeyDrop;
end.
Procedure AntiBan;
Begin
If(Not LoggedIn)then
Exit;
Case Random(8)of
0:
Begin;
HoverSkill('Woodcutting',false)
Wait(2453+random(432));
End;
1: Wait(100);
2 : PickUpMouse;
End
If(FindColorTolerance(x,y,857114,MMX1, MMY1, MMX2, MMY2, 5))then
begin
Mouse(x,y,5,5,true);
End;
end;
Procedure Start;
Begin
MakeCompass('N');
Wait(100+random(133));
MakeCompass('S');
Wait(50+random(133));
MakeCompass('N')
End;
begin;
Smart_Server := 1;
Smart_Members := False;
Smart_Signed := false;
Smart_SuperDetail := False;
ClearDebug;
SetUpSRL;
ActivateClient;
DeclarePlayers;
ChopTree;
Start;
end.
onilika
12-23-2011, 03:04 PM
Did you copied that from somewhere else? It says:
RockPattern:=[1,5,9,13,17,21,2,6,10,14,18,22,3,7,11,15,19,23,4,8 ,12,16,20,24]; OreMid := DTMFromString('78DA63CC626260E0606440054C601226CA5 84' + 'C849A3C209F8F809A6C209F19BF1A00AD2101F4');
Gaston7eze
12-23-2011, 05:07 PM
Did you copied that from somewhere else? It says:
Yeah,i copy it from someones tutorial,i dont remember exactly from who.He says to copy it and then use it for our Scripts.Then i forgot to replace the "Mining" methods,for "Woodcutting"Methods.Sorry.Thanks.
Replaced all the "Ores"for "Logs" and i get the same error,what should i do?
Edit:Bump
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.