SlothScripts
2012-04-14 17:54:02
Hello everyone,
I hope this is the right section; if not someone let me know so I can have it moved or if a mod is reading this, that would be awesome!
Now before I get to my concern, I'd like to start off by saying that I am a novice scripter when it comes to Simba. These are just my observations, not meant to be spoken as though there is any more merit here than simple inquiry. I figured it was worth a post!
As a bot user in the past, and a present day scripter - even if you have only read tutorials - it is more than evident that the difference between a good script and a poor one is the scripts ability not to get you banned. Though there is much that goes into it, I'd like to specifically address one concern; the main Antiban procedure. What I mean by this is a frequently called procedure (or function) which has the sole purpose of performing random antiban procedures.
The clear reason for this is to make the bot appear more human, less bot-like. They will do things like, move the mouse around, mess with the camera angle, hover over the skill you are training, etc. In principle there is nothing wrong here. However, in terms of actual functionality it has come to my attention that perhaps the common way to do this is, less than ideal.
For sake of my example, I will be taking the antiban procedure used by Coh3n in this tutorial (http://villavu.com/forum/showthread.php?t=58935 check it out, it is excellent!)
My concern stems from the math of the situation. This procedure generates a number, 0 through to 59 and if it is one of six it will perform a task. This gives the same probability that the user will hover their skill as it does that they will move their mouse randomly. This clearly isn't the case; as humans there are some tasks which you will perform with higher frequencies than others. It would take a very strong argument to convince me that anyone examines items in their inventory as frequently as they say, move their mouse around or adjust their camera angle.
I went through the list quickly and ranked these six tasks in order that I perform them personally (frequency wise) for sake of example:
I then decided to create a check, which instead of merely being based on number generation; is based on frequency. My original code was something like this:
Now, on paper, in 1000 tests, this would result in:
The actual results for 5532 tests were:
Realizing that this still occurred with too much frequency, I changed the random number to 10,000; but capped all the number checks off at 1000. I then ran the loop 7200 times; this would simulate running it every 500ms for an hour.
It resulted in:
Now please note that some of my math may be off, it was rushed out quickly without the use of a calculator; however, the trial results are all done correctly.
The question that I am posing is; why run a basic, generic procedure when one can create a much more realistic one based on number frequency? Now my function clearly is not perfect, it would require touch-ups, and catering to specific needs (for instance, if you are power training a skill your focus all together will be higher, thus less antiban.)
I apologize in advance for the wall of a thread; but it is mainly codes and trial results.
Any input on this is lovely! Do people use Antiban procedures which take into account more than just randomness? Why or why not?
I hope this is the right section; if not someone let me know so I can have it moved or if a mod is reading this, that would be awesome!
Now before I get to my concern, I'd like to start off by saying that I am a novice scripter when it comes to Simba. These are just my observations, not meant to be spoken as though there is any more merit here than simple inquiry. I figured it was worth a post!
As a bot user in the past, and a present day scripter - even if you have only read tutorials - it is more than evident that the difference between a good script and a poor one is the scripts ability not to get you banned. Though there is much that goes into it, I'd like to specifically address one concern; the main Antiban procedure. What I mean by this is a frequently called procedure (or function) which has the sole purpose of performing random antiban procedures.
The clear reason for this is to make the bot appear more human, less bot-like. They will do things like, move the mouse around, mess with the camera angle, hover over the skill you are training, etc. In principle there is nothing wrong here. However, in terms of actual functionality it has come to my attention that perhaps the common way to do this is, less than ideal.
For sake of my example, I will be taking the antiban procedure used by Coh3n in this tutorial (http://villavu.com/forum/showthread.php?t=58935 check it out, it is excellent!)
procedure Antiban;
begin
case Random(60) of // Random(60) generates a random integer from 0 to 59
10: RandomRClick;
20: HoverSkill('Mining', False);
30: PickUpMouse;
40: RandomMovement;
50: BoredHuman;
59: ExamineInv;
end;
end;
I have looked through a few scripts around the forums and this is generally how the procedures look; catered to the direct needs on occasion.My concern stems from the math of the situation. This procedure generates a number, 0 through to 59 and if it is one of six it will perform a task. This gives the same probability that the user will hover their skill as it does that they will move their mouse randomly. This clearly isn't the case; as humans there are some tasks which you will perform with higher frequencies than others. It would take a very strong argument to convince me that anyone examines items in their inventory as frequently as they say, move their mouse around or adjust their camera angle.
I went through the list quickly and ranked these six tasks in order that I perform them personally (frequency wise) for sake of example:
1. Random Movement.
2. Border Human.
3. RandomRClick.
4. Pick Up Mouse.
5. Hover Skill.
6. Examine Inventory
I then decided to create a check, which instead of merely being based on number generation; is based on frequency. My original code was something like this:
program AntibanMathTest;
var
x: Integer;
procedure Antiban;
var
i: Integer;
begin
i := Random(1000);
if (i > 99) and (i <= 1000) and (i mod 2 = 0) then
Writeln('RandomMovement [Most Common].')
else if(i <= 500) and (i mod 3 = 0) then
Writeln('BoredHuman [Second Most Common].')
else if(i <= 99) and (i mod 2 = 0) then
Writeln('RandomRClick [Third Most Common].')
else if(i > 99) and (i <= 500) and (i mod 5 = 0) then
Writeln('PickUpMouse [Fourth Most Common].')
else if i = 1 then
Writeln('HoverSkill [Fifth Most Common].')
else if i = 7 then
Writeln('ExamineInv [Fifth Most Common Also].')
else
Writeln('No Antiban');
end;
begin
repeat
Antiban;
until(false);
end.Now, on paper, in 1000 tests, this would result in:
Case 1: 450 Times
Case 2: 100 Times
Case 3: 34 Times
Case 4: 14 Times
Case 5: 1 Time
Case 6: 1 TimeThe actual results for 5532 tests were:
Case 1: 2533
Case 2: 579
Case 3: 168
Case 4: 145
Case 5: 3
Case 6: 5
None: 2102Realizing that this still occurred with too much frequency, I changed the random number to 10,000; but capped all the number checks off at 1000. I then ran the loop 7200 times; this would simulate running it every 500ms for an hour.
program AntibanMathTest;
var
x: Integer;
procedure Antiban;
var
i: Integer;
begin
i := Random(10000);
if (i > 99) and (i <= 1000) and (i mod 2 = 0) then
Writeln('RandomMovement [Most Common].')
else if(i <= 500) and (i mod 3 = 0) then
Writeln('BoredHuman [Second Most Common].')
else if(i <= 99) and (i mod 2 = 0) then
Writeln('PickUpMouse [Fourth Most Common].*Should be third')
else if(i > 99) and (i <= 500) and (i mod 5 = 0) then
Writeln('RandomRClick [Third Most Common].*Should be fourth')
else if i = 7 then
Writeln('HoverSkill [Fifth Most Common].*Should not Occur')
else if i = 1 then
Writeln('ExamineInv [Fifth Most Common Also].')
else
Writeln('No Antiban')
end;
begin
for x := 1 to 7200 do
Antiban;
end.It resulted in:
None: 6771
Case 1: 297 - Once every 12 Seconds
Case 2: 77 - Once every 47 Seconds
Case 3: 31 - Once every ~2 Minutes
Case 4: 22 - Once every ~3 Minutes
Case 5: 2 - Once every 30 Minutes
Case 6: 2 - Once every 30 MinutesNow please note that some of my math may be off, it was rushed out quickly without the use of a calculator; however, the trial results are all done correctly.
The question that I am posing is; why run a basic, generic procedure when one can create a much more realistic one based on number frequency? Now my function clearly is not perfect, it would require touch-ups, and catering to specific needs (for instance, if you are power training a skill your focus all together will be higher, thus less antiban.)
I apologize in advance for the wall of a thread; but it is mainly codes and trial results.
Any input on this is lovely! Do people use Antiban procedures which take into account more than just randomness? Why or why not?