Starting work on first script - AUTO BOLT FLETCHER !
Cigue
2009-11-12 23:12:40
I'm going to script a bolt fletcher since it looks pretty simple and I notice none is available right now. :) The primary job it's got to achieve is click on case 1 of inventory, then case 2, then case 1, etc. While looking out for randoms and avoiding ban.
This is the basic skeleton of the script I'm trying to achieve :
-login
-loop using while
--check inventory
---if unfinished, then continue, else exit
--check random
---if random, then exit, else continue
--check login using RSReady
---if logged in, then continue, else exit
--click case 1 using Mouse procedure
--click case 2, same
How would I add an antiban/antirandom to my script? And what are the commands for moving mouse/clicking mouse/logging out ?
Thanks a lot for reading, I'm getting a good vibe from this community and I hope I can contribute :)
EDIT : Can someone get me started on logging in? I've already got a basic loop that does nothing and SMART initialization.
EDIT3 : What is wrong with it?
{Include Mouse.scar}
Program Autominer;
var i: Integer;
Begin
i:=0;
while(i < 10) do
Begin
i:= i+1;
procedure Mouse(580,227,5,5: Integer);
procedure Wait(300+Random(800);
procedure Mouse(620,229,5,5: Integer);
procedure Wait(300+Random(800);
end;
End;
rogeruk
2009-11-13 00:52:06
Cigue
2009-11-13 10:52:01
From: rogeruk
Fletchers are here
http://www.villavu.com/forum/forumdisplay.php?f=108
First scripts are here. Your point?
Gu3st...
2009-11-13 13:43:24
From: Cigue
First scripts are here. Your point?
Maybe he though you looked so 1337 that you already made a nice script and asked u to post it there? :p
more likely he miss read the topic title or something.
rogeruk
2009-11-13 15:34:49
From: Cigue
First scripts are here. Your point?
I'm going to script a bolt fletcher since it looks pretty simple and I notice none is available right now.
Point being is that they ARE available.
Maybe getting your facts straight would be a good start.
And having an attitude like that isnt going to get you very far
Gu3st...
2009-11-13 17:12:02
From: rogeruk
Point being is that they ARE available.
Maybe getting your facts straight would be a good start.
And having an attitude like that isnt going to get you very far
I see no problems with his attitude. I had the same reaction when I saw your post because I though you meant that he posted in the wrong forum
EDIT: I hope you're not taking this personal, rogeruk :)
YoHoJo
2009-11-13 17:30:07
rogeruk the only one I see with an attitude here is you.
Stop being rude to new members. Could have just said
"Actually, there are some feltchers available here"
Anyways, lets get to the POINT of this thread and start helping this man.
Program Autominer;
{.include SRL\SRL.scar}
var i: Integer;
Begin
i:=0;
while(i < 10) do
Begin
i:= i+1;
Mouse(580,227,5,5,True);
Wait(300+Random(800));
Mouse(620,229,5,5,True);
Wait(300+Random(800));
end;
End.
Would be better, but its not good to use coordinates when scripting, try using color/bitmaps/dtms instead. Why not read up some more about basic scripting at the tutorial section? Also go the he fletcher script section and take a look at the code of some that have already been made to get some more ideas about stuff :D. Keep posting more questions here! :D Good luck learning!
Cigue
2009-11-13 18:10:04
Uh thanks all :) YoHoJo, how did it get all bold and stuff? :o and it still doesn't works… Something with arguments. I'll go check the tutorial section, thanks !
Gu3st...
2009-11-13 18:13:39
You're supposed to include the SRL.Scar and then call SetupSRL; as the very first procedure in the main loop (which YoHoJo obviously forgot.. *sigh* :rolleyes:), not only including the mouse.scar :)
The last "end" in the script has to end with a "." instead of a ";". You are currently ending the script with and "end;", it should be "end." Note: this is only for the last "end" in the script, every other "end"-s should have a ";".
Sandstorm
2009-11-14 00:41:19
Also, to post with all the bold and green, use
[./scar] tags, and remove the ..
~Sand
rogeruk
2009-11-14 06:51:16
From: YoHoJo
rogeruk the only one I see with an attitude here is you.
Stop being rude to new members. Could have just said
"Actually, there are some feltchers available here"
Anyways, lets get to the POINT of this thread and start helping this man.
Program Autominer;
{.include SRL\SRL.scar}
var i: Integer;
Begin
i:=0;
while(i < 10) do
Begin
i:= i+1;
Mouse(580,227,5,5,True);
Wait(300+Random(800));
Mouse(620,229,5,5,True);
Wait(300+Random(800));
end;
End.
Would be better, but its not good to use coordinates when scripting, try using color/bitmaps/dtms instead. Why not read up some more about basic scripting at the tutorial section? Also go the he fletcher script section and take a look at the code of some that have already been made to get some more ideas about stuff :D. Keep posting more questions here! :D Good luck learning!
How can my attitude be
wrong when i simply posted a simple URL link.
I guess people are getting offended by a http:// now?
Good Day Cigue,
You may not be aware there are several fletchers already posted at
http://www.villavu.com/forum/forumdisplay.php?f=108.
You can simply just take a look at other fletchers to see how they have done it and not necessarily copy them but just take ideas.
My working fletcher is located at
http://www.villavu.com/forum/showthread.php?t=51178, feel free to take a look at PM me with any questions/help you have.
Cigue
2009-11-14 17:20:18
Would anyone help me on MSN/AIM?
YoHoJo
2009-11-14 17:25:55
From: Cigue
Would anyone help me on MSN/AIM?
Tons of people, just add random people and ask for help :D, lots of people here dont mind helping others. At the top of anyone's post at the right side you'll see an MSN butterfly or AIM man, click them to see their aim/msn address.
@Rogeruk maybe I overreacted :p, but your last post is much nicer!
rogeruk
2009-11-14 18:56:39
@YoHoJo same here lol.
Cigue feel free to add me
JPHamlett
2009-11-14 23:18:20
cique feel free to add me also
[email]jphamlett@live.com[/email]
cycrosism
2009-11-18 22:10:41
If this thread is still semi-alive I suggest you to learn both DTM's and Bitmaps and replace them with the coord clicks. It can also work as a fail safe too because with a coord click it is clicking there regardless. With bitmaps/dtm's it checks then clicks (If you use it as a IF statement)
Awkwardsaw
2009-11-18 22:14:32
From: cycrosism
If this thread is still semi-alive I suggest you to learn both DTM's and Bitmaps and replace them with the coord clicks. It can also work as a fail safe too because with a coord click it is clicking there regardless. With bitmaps/dtm's it checks then clicks (If you use it as a IF statement)
^ that :)
also, you can add me on msn :D
Dervish
2009-11-19 16:47:31
Isn't there MouseItem(Itemslot#) ?
Cigue
2009-11-19 23:28:56
Thanks everyone, I'll be on it !
Here is a basic sketch, tell me what you think about it :
1. Use BMP to check that there are feathers AND (unf) bolts
1.5 Alternatively,use what Dr.Dervish said (MouseItem(Itemslot#)) and confirm with IsUpText
2. Click-a-chick
3. Repeat
EDIT: 4. Once in a while, check main chat to see if user gets the "You fletch ***** bolts" message. Also, put main instructions in a loop that say
i = random(80);
for i = 0-7 do antiban;
for i = 8-79 do instructions;
Cigue
2009-11-21 13:28:42
HALP. Just getting started with the script and I get an out-of-range error. Can someone help me out?
program AutoBolts;
{.include SRL\SRL.scar}
var Unf, Feather : Integer;//Variables for BMP
procedure DeclarePlayers;//Only one player ATM, will develop into more once it's working.
begin
Players[0].Name := '';//Error happens on this line.
Players[0].Pass := '';
Players[0].Nick := '';
Players[0].Active := True;//Use this player?
Players[0].Pin := '';//Bank pin. Leave blank if you don't have one.
end;
begin
ClearDebug;//Empties debug log.
SetupSRL;//Loads SRL.
DeclarePlayers;//Calls the procedure.
LoginPlayer;//Logs your player into the game.
end.
Ultra
2009-11-21 21:36:44
I suggest you read some more tutorials, looks like you haven't quiet got the basics…
Ghostman
2009-11-21 22:59:02
You may want to try this tut to fix that.
http://www.villavu.com/forum/showthread.php?t=50359Compiles just fine
rogeruk
2009-11-22 06:25:11
From: Cigue
HALP. Just getting started with the script and I get an out-of-range error. Can someone help me out?
program AutoBolts;
{.include SRL\SRL.scar}
var Unf, Feather : Integer;//Variables for BMP
procedure DeclarePlayers;//Only one player ATM, will develop into more once it's working.
begin
Players[0].Name := '';//Error happens on this line.
Players[0].Pass := '';
Players[0].Nick := '';
Players[0].Active := True;//Use this player?
Players[0].Pin := '';//Bank pin. Leave blank if you don't have one.
end;
begin
ClearDebug;//Empties debug log.
SetupSRL;//Loads SRL.
DeclarePlayers;//Calls the procedure.
LoginPlayer;//Logs your player into the game.
end.
program AutoBolts;
{.include SRL\SRL.scar}
var Unf, Feather : Integer;//Variables for BMP
Procedure DeclarePlayers;
Begin
HowManyPlayers := 1; // How many players declared?
CurrentPlayer := 0; // Number of player to start with.
NumberOfPlayers(HowManyPlayers);
With Players[0] Do
Begin
Name := ''; // Characters full RS username.
Pass := ''; // Characters RS password.
Nick := ''; // 3 non-caps letters of char's RS username.
Pin := ''; // Bank Pin
Active := True;
BoxRewards := ['XP'];
End;
End;
begin
ClearDebug;//Empties debug log.
SetupSRL;//Loads SRL.
DeclarePlayers;//Calls the procedure.
LoginPlayer;//Logs your player into the game.
end.
Like that
Cigue
2009-11-22 23:40:57
From: Ultra
I suggest you read some more tutorials, looks like you haven't quiet got the basics…
Bleh, I've read a tut on declareplayers, I just thought that maybe the first three lines weren't necessary to run the function if you only had one player…
Anyway thanks yall I'll be doing my homework some more before asking st00pid questions :/
Arcadium
2009-11-24 10:15:14
hey Cigue, ive been looking for a script just like the one you're making, cant wait for its release! any idea of how long for a basic working version?
Cigue
2009-11-25 11:15:19
Arcadium : About a week, I am making progress very fast atm :)
EDIT : I have let down the DTM/Bitmap approach since I learned there is a very special function that clicks inventory spot x called MouseItem. At the moment I'm still trying to make a successful antiban procedure, why won't this one work?
program AutoBolts;
{.include SRL/SRL.scar}
Procedure Antiban;
begin;
Case random(120) of
0: RandomRClick;
1: HoverSkill(Skill: 'fletching'; Click: False);//Error on this line
2: PickUpMouse;
4: RandomMovement;
5: BoredHuman;
6: ExamineInv;
end;
end;
begin
end.
Failed when compiling
Line 8: [Error] (20638:15): Unknown identifier 'Skill' in script
Arcadium
2009-11-29 06:59:53
Hows the progress going cigue?
(sorry i cant keep my enthusiasm down lol, this script will own!)
From: Cigue
Arcadium : About a week, I am making progress very fast atm :)
EDIT : I have let down the DTM/Bitmap approach since I learned there is a very special function that clicks inventory spot x called MouseItem. At the moment I'm still trying to make a successful antiban procedure, why won't this one work?
program AutoBolts;
{.include SRL/SRL.scar}
Procedure Antiban;
begin;
Case random(120) of
0: RandomRClick;
1: HoverSkill(Skill: 'fletching'; Click: False);//Error on this line
2: PickUpMouse;
4: RandomMovement;
5: BoredHuman;
6: ExamineInv;
end;
end;
begin
end.
Failed when compiling
Line 8: [Error] (20638:15): Unknown identifier 'Skill' in script
Remove 'skill:' before fletching and remove ';click:' before false
So that line should be like this
1: HoverSkill('fletching', False);
Also make it a habit to write
SetupSRL;
In your mainloop if you include SRL.
And make it a habit to write in proper standards. Trust me it becomes second nature after while ;)
Good Luck with your script :)
Heavenguard
2009-12-03 21:26:20
Hey Cigue, Im surprised at the perseverance that you show. I see that you strive for making each step. Im so proud of you for that, and never let that self esteem down, your healthy struggle is something I usually do not see.
As for learning, You wanna tell us what you do know about Scripting in general, Tell us if you know things like:
Variables: How to declare them.
Constants: How to declare them.
Basic of the Basic things, explain to us what you know. We want to hear. I want to hear :D.
Doing this will allow us to understand exactly to what extent you know and are capable of understanding. We cant just throw fixes and extra things at you if you can't really >.> read it appropriately. That will just give you a headache xD.
Im still a Low-level basic intermediate scripter, but when I was learning how to script, I made sure I had everything Down pack. Just thought I should add that in, because since you were here longer, You most likely know much more then I do :D
Cigue
2009-12-05 00:53:28
Wow thank you Heavenguard ! Down pack? What is that? :P
Anyway, I used to script C++, so I know about constants, variables, functions, procedures, some standards. What I do not know is the extent of the SRL library. I've never scripted automations, only basic math scripts to help me with comptability, math ops, games, etc.
I am trying to make my first script a complete one, out of stubbornness and thirst of success.
From what I figure, a good antiban must have the following :
-Human movement
-Sometimes will make errors
-Sometimes will pause for a while, change tabs, look at experience, etc.
-Pauses and sleeps
Rest of the script must include basic instructions, fail-safes (which I'm not sure how to implement accurately) and declareplayers.
Am I anywhere near a skeleton for a working script? Thanks for your support guys, it is much appreciated :D
Kyle Undefined
2009-12-05 04:33:42
If you need him just add me on IM.
~Camo
Heavenguard
2009-12-05 08:29:46
From: Cigue
Wow thank you Heavenguard ! Down pack? What is that? :P
Anyway, I used to script C++, so I know about constants, variables, functions, procedures, some standards. What I do not know is the extent of the SRL library. I've never scripted automations, only basic math scripts to help me with comptability, math ops, games, etc.
I am trying to make my first script a complete one, out of stubbornness and thirst of success.
From what I figure, a good antiban must have the following :
-Human movement
-Sometimes will make errors
-Sometimes will pause for a while, change tabs, look at experience, etc.
-Pauses and sleeps
Rest of the script must include basic instructions, fail-safes (which I'm not sure how to implement accurately) and declareplayers.
Am I anywhere near a skeleton for a working script? Thanks for your support guys, it is much appreciated :D
Wow C++ O.O Nice, Seems like you have tons of experience on your back. Anyways, Its good to know that you know how variables, constants, functions, procedures, and standards.
What I meant by Down pack pretty much means I had everything I read and practiced in tutorials embedded into my head so when I was at school I was able to write tons of scripts on things I learned.
I think I would suggest you read
Coh3n's All-In-One SCAR Scripting Tutorial! To get familiar on both scar and mostly SRL. The guide is extremely detailed and does not go over much about the basics of the basics which you all ready know.
Your skeleton for the script is beautiful, all thats left to do is just make it. Although, if you read the guide, You will actually understand how Scripts in Scar are actually written. You will know the standards of writing one, so your able to solve your own errors if you encounter them. Learning DeclarePlayers and Anti Randoms are actually taught at the end of the beginners section of that tutorial that I pointed out to you. I just suggest that you read all of the beginners section just to freshen up your mind.
In the beginners section you will learn the standards of scar, such as how things should be written, when to place our punctuation marks(such as (Semicolon) , (,), (.). Once you understand that, learning SRL from there really isn't a problem anymore. A lot of things clear up since you will know how to read it and type it efficiently.
In the Intermediates Section, A lot of nifty Scar and SRL Functions are introduced. Including Object Finding: Bitmaps, DTM's. MapWalking : DDTM's, RadialWalking, Symbol Finding. These are the things that your looking for in your script. Maybe not the mapwalking part, but bitmaps and DTM's are a must for item clicking :D. You will also learn better ways of finding Colors. :D
For the advanced….. i dont know lol, I have not gotten there yet. As far as I think, Coh3n Teaches Arrays, How to make your own Autocolor, Pretty much everything to get you set in overcoming any obstacle.
Your on your way dude, please take a look at that tutorial by Coh3n. It will explain a lot of things with time and practice. Dont give up :D
Cigue
2009-12-05 17:49:58
Why's this shit no werk
Heavenguard
2009-12-05 19:08:06
Cigue, The Script you made is well thought and is well put together as a beginners script, but I really do think your rushing it. Your missing a lot of things I would expect to be in the script. I mean, SMART is something usually added in as a final touch. As for the script, I can't read it. I have not gotten up to the point of learning how half of the things you put in work. I still don't know what byte's are and your ClickRaw Function is pretty confusing.
But since you did make the script yourself, it should do what you wanted it to do lol. What seems to be the problem if I may ask? If its not working the way you want it, its probably because you forgot to add some functions.
Update: Oh, lol thanks. I wish I could help you with the login part >.>, not up to there yet
Cigue
2009-12-05 19:24:18
I should clarify : it just won't log in. I probably rushed that part since I was eager to get a working script.
Heavenguard : ClickRaw has three inputs : Left (true or false), Item (string) and Slot (byte, 1-2-3-4-etc)
It moves mouse to inventory slot Slot, then proceed to check if the item corresponds to Item and clicks left or right depending on boolean. if it clicked right, it chooses "use" option.
Hope that clarified it :)
Cigue
2009-12-05 19:36:47
From: Heavenguard
I really do think your rushing this script. Your missing a lot of things I would expect to be in the script.
Could you name a few ? I'm always willing to improve :)
From: Heavenguard
As for the script, I can't read it.
Don't worry, I can't either
MylesMadness
2009-12-05 19:45:41
The reason you can't login is that srl became broken with the latest update, so you'll have to wait for it to be fixed.
I also cleaned up your code, alot of the ifs you had are built into the function:
program AutoBolts;
{.include SRL/SRL/misc/Smart.scar}
{.include SRL/SRL.scar}
{.include SRL/SRL/Misc/Users.scar}
{.include SRL/SRL/Misc/Reports.scar}
//Special thanks go to FEAR, Nava2, Rogeruk, YoHoJo, HigginsHax, Camo
const
SmartSigned = False;
SmartMembers = True;
procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
with Players[0] do
begin
Name := ''; //Character Name
Pass := ''; //Character Pass
Nick := ''; //Nickname 3 - 4 Letter's of char name
Active := true; //Use player in script?
Pin := ''; //Leave blank
end;
end;
procedure Antiban;
begin
case random(120) of
0: RandomRClick;
1: HoverSkill('fletching', False);
2: PickUpMouse;
3: RandomMovement;
4: BoredHuman;
5: ExamineInv;
6: RandomAngle('');
7..15: LevelUp;
16: MouseItem(3, True)
end;
end;
function ClickRaw (Left: Boolean; Item: String; Slot: Byte) : Boolean;
var
x, y: Integer;
begin
MMouseItem(Slot)
if(IsUpText(Item))then
begin
GetMousePos(x,y);
Mouse(x,y,0,0,Left);
Result := True;
end else
begin
Writeln('Something is wrong! logging out');
Logout;
Result := False;
end;
if(not Left) then Result := ChooseOption('use');
end;
procedure MainEvent;
begin
case random(12) of
0: ClickRaw(false, 'unf', 1);
1..11: ClickRaw(true, 'unf', 1);
end;
case random(12) of
0: Clickraw(false, 'eather', 2);
1..11: Clickraw(true, 'eather', 2);
end;
end;
begin
Smart_Server := 152;
Smart_Members:= SmartMembers;
Smart_Signed := SmartSigned;
Smart_SuperDetail := False;
SetupSRL;
DeclarePlayers;
LoginPlayer;
Gametab(tab_Inv);
repeat
MainEvent;
Antiban;
until(False);
end.
Cigue
2009-12-05 20:03:47
Thanks a lot! What does cleaning up mean? I see what you've done with the standards and you've replaced Left = false with not Left. :)
How can I copy+paste your code without losing the format?
EDIT : Can a humble beginner help with repairing SRL?
MylesMadness
2009-12-05 22:11:13
From: Cigue
Thanks a lot! What does cleaning up mean? I see what you've done with the standards and you've replaced Left = false with not Left. :)
How can I copy+paste your code without losing the format?
EDIT : Can a humble beginner help with repairing SRL?
Cleaning up code just means fixing the standards, removing unneeded things, changing things to be faster or shorter, stuff like that.
If you post the fixed code a developer will put it into srl.
marpis
2009-12-06 12:27:27
Don't use bytes, use Integer instead to avoid type mismatch.
Plus remember ; ends every statement.
case … end;
begin … end;
repeat … until(condition);
Cigue
2009-12-06 15:06:19
Thank you Marpis :)
I am really tired right now so this might not make sense.
repeat
begin
MainEvent;
Antiban;
end;
until(False);
Antiban and MainEvent are procedures, will this work?
MylesMadness
2009-12-06 19:11:22
No need for the begin and end, but besides that you got it
Heavenguard
2009-12-06 19:21:39
I still do recommend you reading the post I left (post # 32) and learn how to script :D. I do not think testing your own until you get it really helps. I have been down that path, The only way it works is if you write it yourself without needing help, know what your doing :D. Read the guides bro!
Cigue
2009-12-06 22:17:41
Through some homemade debugging, I found that the script won't go past SetupSRL; instruction. Does anyone have had similar problems with the procedure?
From: Heavenguard
I still do recommend you reading the post I left (post # 32) and learn how to script :D. I do not think testing your own until you get it really helps. I have been down that path, The only way it works is if you write it yourself without needing help, know what your doing :D. Read the guides bro!
I tried to read Cohen's tutorial. Made it to DDTM's and I realized that I did not understand anything more about SRL and scripting. This is my first dabble into the world of SCAR and automation, I'm not quite ready to go to hobby mode. I don't know how the forums work, where to find what I'm looking for so I'll just ask what's what until I work it out.
Cigue
2009-12-07 17:51:08
I am proud to announce I have completed the first working version of this script! At the moment it is extremely basic and includes no failsafe or features other than a basic loop.
I am going to add DTMs because isuptext failed me miserably. Then I'll release it to junior scripting.
Thanks everyone who's helped me so far :) I wouldn't have made it without you.
Kyle Undefined
2009-12-07 23:00:09
Woohoo! That's good news! :D
~Camo
Arcadium
2009-12-09 17:07:38
will the script be posted any time soon? I've got 90k bolts ready to be fletched :D
Heavenguard
2009-12-09 18:40:46
Sais its 66% done in his sig. This guys working overtime. :D Proud of him.
Cigue
2009-12-09 23:34:54
To Arcadium : I'll PM ya once I'm done ;)
HG : Thanks man ^^
To keep you updated, I just finished adding DTMs to my script. it now supports all feathers and all metals.
Now I'm stuck wondering : First, would checking finddtm twice per second considerably slow down the script or blow up my computer?
Second (which I might figure out on my own but help is still appreciated…)
You've found an item DTM, which is great: it means it's in your inventory. How do you make sure it's in inventory slot x, and move it if needed?
Arcadium
2009-12-10 02:55:44
ah ok, sorry i didnt see the signiature. I can see you've worked hard on your script cigue, hope all the best for you. And thanks!
Heavenguard
2009-12-10 08:29:25
Second (which I might figure out on my own but help is still appreciated…)
You've found an item DTM, which is great: it means it's in your inventory. How do you make sure it's in inventory slot x, and move it if needed?
ooooo i know what your saying, I think the Inv is the same thing as a bank. Although im not sure. It goes by Columns and then Rows. So I think if you wanted to check it, youd have to check a column(x) by Row(y) and see if it finds the item. I truly don't know the function, if its really needed and theres no other way around it you can post it up in Scripting Help Forum, or just post it up anyway.
Cigue
2009-12-10 12:43:33
not touching banks until my next script >.>
I guess I'll PM a few folks. Thank you !
eDiT : Meanwhile I'll just add breaks.
EDIT 2 : BOOM ! I love SRL Rep.
{*******************************************************************************
procedure DragItem(Inv1, Inv2: Integer);
By: NaumanAkhlaQ
Description: Drags Item from first position Inv1 to Inv2 (Inventory Slots)
*******************************************************************************}
procedure DragItem(Inv1, Inv2: Integer);
var
InvAr: array [0..1] of TBox;
begin
InvAr[0] := InvBox(Inv1);
InvAr[1] := InvBox(Inv2);
DragMouse(InvAr[0].x1, InvAr[0].y1, InvAr[0].x2, InvAr[0].y2,
InvAr[1].x1, InvAr[1].y1, InvAr[1].x2, InvAr[1].y2);
end;
Heavenguard
2009-12-10 19:56:56
Grats :D
iden1050
2009-12-11 05:03:37
script looks cool, excited for its release.
Cigue
2009-12-11 20:05:46
From: iden1050
script looks cool, excited for its release.
Thank you :D
Please, any SRL members or decent scripters passing by,
READ THIS PART PLEASE. If you could just leave a note to help me :)
Left to do :
-Add proggies;-Add multiplayer;
-Add a procedure that can find a DTM and return coords;If it's bold, I need help with it, or at least something to get me started. :)
Thanks all !
Feroc1ty
2009-12-12 00:01:04
Break is easy, after doing few hundred or thousand (random number) of shiet simply make it log off, wait a random amount of time that's at least 5 minutes upto 2 hours, log back in and go on.
could be easily made by placing a function inside ur main loop such as
if loads > x then
begin
wait(5 minutes + random( 2 hours));
x := x + 300 + random (600);
end;
this obv wont compile i just typed this out to give you an idea
Cigue
2009-12-12 15:04:58
@Feroc1ty : WOOHOO ! Thanks bro. Break procedure now working.
To find a DTM and return the coordinates of the location of it you can use this:
function FindTheDTM(DTM : integer; Area : TBox; var TP : TPoint) : boolean;
begin
TP := Point(-1, -1);
result := FindDTM(DTM, TP.x, TP.y, Area.x1, Area.y1, Area.x2, Area.y2);
end;
If it does not find the DTM within the specified area, it will return false as well as the TPoint being (-1, -1).
For a progress report you could for instance make a basic progress report like this. Don't flame me if this is outdated or whatever, it's the first thing I've written in three years ;).
procedure BasicProggy;
var
Seconds: Integer;
begin
Seconds:= GetTimeRunning Div 1000 + 1; // This will divide the TimeRunning
Writeln('Ran for' + IntToStr(Seconds)); // which is in milliseconds into seconds..
Writeln('Made a total of' + IntToStr(boltsmade));
end;
And then declare BasicProggy; procedure inside your main loop:
repeat
begin
MainEvent;
Antiban;
BasicProggy;
end;
until(False);
Now, I haven't even tested this or anything, but I think it should work :P.
Good luck!
Cigue
2009-12-16 16:43:13
For some reason, I came back from vacation to find the item position problem resolved, without remembering doing it xD. Oh well :) One more thing out of the way.
Thanks Dub for your basic proggy, it'll really help me !
Have nice holidays, I'm releasing this in juniors once I add proggies and multiplayer.
Kyle Undefined
2009-12-16 20:14:42
Dub's example is good, but here's another way:
procedure BasicProggy;
begin
Writeln('Ran for' + TimeRunning); // which is in milliseconds into seconds..
Writeln('Made a total of' + IntToStr(boltsmade));
end;
If you need help with multiplayer just let me know.
~Camo
From: Camo Developer
Dub's example is good, but here's another way:
procedure BasicProggy;
begin
Writeln('Ran for' + TimeRunning); // which is in milliseconds into seconds..
Writeln('Made a total of' + IntToStr(boltsmade));
end;
~Camo
Is that new or have I always been doing it the complicated way lol? :duh:
Kyle Undefined
2009-12-17 18:45:10
Either way doesn't matter, but TimeRunning; will display hours, minutes, seconds for you :)
~Camo
Cigue
2009-12-18 00:49:11
Never mind, worked it out. Now going to add multiplayer, and probably fix break procedure.
Camo : I'll see you on MSN :P
Kyle Undefined
2009-12-18 01:00:15
Ok, just message me :p
~Camo
Cigue
2009-12-22 23:30:47
There yall go ! I wish there was a "work in progress" forum because having this thread for checking progress greatly helped me on this.