Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
IceKontroI

Pattern Breaking and Account Preference

Recommended Posts

Hello, everyone. Recently I've been interested in how Jagex's pattern detection works. I ran a simple easily detected script which opens the GE, buys 1 lobster at 100 GP, waits 30 seconds, then cancels the offer and closes the GE on a loop with tribot's AI antiban turned off. After a few minutes of runtime some abnormal things started happening. Most commonly my input to the game was blocked, meaning I could move my mouse around, but the game server never accepted my input, and as a result my account's actions had no effect on the game world. I've been able to semi-reliably recreate this scenario multiple times on different accounts and IP addresses. It's worth noting that players and NPCs continue their normal action while my account's been frozen, which also indicates no connection errors. The input blockage happens fairly often to the point that it's very unlikely it has anything to do with my network connection or Jagex servers. I believe this is Jagex's first line of defense against bots (or at least one of them).

  • Real players will typically try to perform various actions in-game like arranging inventory, clicking on random tiles or objects, world hopping, and even restarting the client.
  • Bots may repeatedly click the same action (big red flag) or do nothing (moderate red flag)

I have no doubt that botters/scripters with more experience than me have noticed this, but this is not a thread about Jagex input blocking, it's about preventing it from happening through pattern breaking.

Pattern breaking is centered around the imperfections and variability of the human mind and judgment. Regular player activity does form patterns to some degree, but typically it isn't as pronounced as those of bots. There are two categories of pattern breaking:

  • Large scale
    • More useful for public scripts or large farms
    • Focuses on creating differences between accounts through account preference
      • Different methods of performing tasks
      • Different subsets of antibans per account
        • Each account may be only able to use 7 out of 12 generic antibans available for the script
        • This increases the longevity of the script by allowing less opportunities for Jagex to group accounts via similar actions
      • Different frequencies of antibans per account
        • Account A may perform one antiban more frequently than account B
      • Changes in sleep and delay times per account
      • Accounts all have different run times
        • This is mainly for farm detection, not for public scripts
      • Different accounts running the script in different worlds/locations if possible
      • Unique break patterns per account
      • Different muling cycles
  • Small scale
    • Focuses on preventing accounts from producing patterns through their actions
      • Changes the order of sub-actions within a larger action when order does not matter
      • More useful when incorporated as part of a complex script process
      • Avoid hardcoding script processes as first A, then B, finally C
        • Instead use fluid condition checks to see what action should be performed
        • Then use account preference and probability to determine which of several actions it prefers over the others
        • Action[] actions = getActions(situation); // This should perform action condition checks and return only relevant actions
          
          boolean performed = false;
          
          for (action : actions) {
          	if (accountPrefers(action) && accountProbability(action)) {
          		performed = performAction(action);
          		if (performed) {
          			break;
          		}
          	}
          }
          
          if (!performed) {
          	performAction(action[General.random(0, action.length)];
          }

          While this may seem excessive, this is how players decide what to do next in a sequence of events

    • Antiban is a large part of pattern breaking
      • Performing actions you don't usually do is an effective way to break patterns
      • Misclicking can be seen as a form of antiban as it's infrequent but deviates from your normal activity
    • Avoid randomization
      • Randomizing everything from antibans to sub-actions within a larger action schedule may seem like an appealing idea
      • While it's likely to work to some degree, it will make accounts on the large scale appear too similar to each other
      • We're trying to get our accounts to operate in the grey area between a well defined pattern and no pattern at all
      • If all accounts operate in this grey area their patterns will be loosely defined but dissimilar from each other

The idea of pattern breaking shows promise, however it has many requirements. One of which is account preference which is something Tribot has some support for, but this support is limited. For example a scripter has no way of applying Tribot preference to custom made functions. The solution is to make your own preference system where the account's username and a seed value is used to derive a value from 0 to 100. Below is my own way of doing so:

    /**
     * Performs a probability check on the input value. Input a percentage (0 - 100).
     */ public boolean chance(double chance) {

        return General.random(0, 100) <= chance;
    }
                                               
    /**
     * Scales a value based on its original range so that its position in that range is in the same position in the new range.
     */ public double normalizeValue(double value, double oldMin, double oldMax, double newMin, double newMax) {

        double percentage = (value - oldMin) / (oldMax - oldMin);

        return newMin + percentage * (newMax - newMin);
    }
    
    /**
     * Generates a username based preference value for the given seed (0 - 100).
     */ public double preference(double seed) {

         try {

             String hash = Double.toString(Player.getRSPlayer().getName().hashCode() * Math.sqrt(seed)).replaceAll("[^\\d.]", "").replaceAll("\\.", "");

             String int1 = Character.toString(hash.charAt(hash.length() - 1));
             String int2 = Character.toString(hash.charAt(hash.length() - 2));
             String int3 = Character.toString(hash.charAt(hash.length() - 3));

             return normalizeValue(Double.parseDouble(int1 + int2 + "." + int3), 0, 99, 0, 100);

         } catch (NullPointerException e) {return 50.0;}
    }

    /**
     * Generates a username based preference value for the given seed, but normalized to match the provided range.
     */ public double preference(double seed, double min, double max) {

        return normalizeValue(preference(seed), 0, 100, min, max);
    }

    /**
     * Performs a probability check on a preference value normalized to match the given range.
     */ public boolean preferenceChance(double seed, double min, double max) {

        return chance(preference(seed, min, max));
    }

Hopefully I've included all the necessary functions for the above to work. If you for example wanted to test an account's preference for performing Action A over Action B, you could take the hashcode of each actions, remove all non-integer characters from each, input them into the functions above, and receive a preference for each. I recommend using custom ranges like preference(100, 15, 85), where 100 is the seed, 15 is the min chance, and 85 is the max chance. That way the preference range will always be within 15% and 85% and you won't ALWAYS or NEVER perform that action above other actions. It should also be mentioned that you shouldn't be using these preferences to determine which actions to do, only to determine which actions should be performed above other actions. All actions should be performed as long as they're part of your script.

This post ended up being much longer than I originally wanted but it's good to get your thoughts out in writing so I'm glad I spent the time. Going forward I would appreciate a healthy discussion, please add to the thread with your comments rather than just taking up space with pointless nay saying.

Edited by IceKontroI
  • Like 3
  • Thanks 5

Share this post


Link to post
Share on other sites
3 hours ago, Encoded said:

I've never had input blocked.

Your "pattern breaking" is ABC2.
Of course they aren't the same, but the general concept is the same.

I never noticed it until I started looking for it which was recently, but you can semi-reliably make it happen like I stated at the beginning. 

Yes, ABC2 does use this, but doesn't allow a scripter to apply it to custom methods. A scripter can add in multiple ways of doing a process and prioritize those ways across different accounts by using the functions I've provided at the end. I'm really just publicly advocating variety in activity both from a single account perspective and across multiple accounts. This could be used to improve the longevity of both the account and script.

Edited by IceKontroI
  • Like 2

Share this post


Link to post
Share on other sites

idea sounds great.. i think the biggest issue i see is i can easily tell bots using the same script because some functions they all act exactly the same.
though when selecting anti ban options they should become a saved set, with say there being 12 options but of those 12 there are 5 more sub options of pattern and the chosen patterns will be saved with the account info so they're always performing the same kind of options because no human acts alike and they usually perform the same way every day some may do things a little slower than others like clicking precision or mouse movement always being within a range of pace.

Share this post


Link to post
Share on other sites
On 10/28/2017 at 10:31 PM, Crystal Elite said:

I think the point IceKontrol made is the ideal script creates actions that are separate and distinct, but not bot-like.

And he's suggesting "preferences" in order to accomplish this goal, so that each bot can have its own habits and operate within them. Is this the case? Feel free to reply.

Yeah, basically that. I went into a lot of detail but the idea boils down to what you said. For any action that can be performed more than one way, each account should have its own "preference" for which variant method to use. When I say preference I mean 75% of the time they may do it the preferred way, and the remaining times it's a selection of the remaining possibilities.

Edited by IceKontroI

Share this post


Link to post
Share on other sites

I know I'm a bit late to this, but ABC antiban can be extended/replaced. It's my current project.

Just do "class x extends ABCUtil". Let's you override the methods that you don't think are right, and possibly deprecate them if you don't think they are useful.

You can also add new functionality. 

 

Adding new antiban must be taken with care. It must be something that humans definitely do. You must implement with the same timing as humans. You must also implement it with the same distribution frequency.

If any of those above conditions aren't met, you could very easily end up giving Jagex another heuristic factor for detecting bots. 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Similar Content

    • By Optimus
      (Formerly known as Tri AIO Combat & Magic)
      This script is an all in one combat script that can fight every monster in Runescape safely with extensive features
      Combined with a premium all in one magic trainer that can train your magic up using nearly every magic training method available! 
      Features Overview:
      AIO Combat Features:
       VIP is not required!
        10 Hour free trial on the repository 
      Complete all in one combat system that can fight every single monster in Runescape including but not limited too:
       Brutal black dragons! *NEW*
       Wyverns! *NEW*
       Everything in the stronghold of security *NEW*
       Slayer dungeons *NEW*
       Sand crabs (automatically resets aggressiveness) *NEW*
       Rock crabs (automatically resets aggressiveness) 
       Dragons
       Giants
       Goblins
       Ghouls
       Dagganoths
       Druids
       And hundreds more different monsters!
        Can bank at every bank in Runescape
        Can use all teleports
        Supports all food types
        Guthans healing
      Dwarf multicannon support
        Supports all weapons and special attacks
        Re-equips ammo and can withdraw more from the bank
        Supports all potions
        Automatically uses the Looting bag and Herb sack
        Customisable looting by Item Name, Item ID, or items worth more than x price (Automatic price lookup).
      Full prayer support
      Resets Rock crabs and Sand crabs aggro (Including 10k island).
        Safe spotting optional
      Full worldhopping system that can worldhop when many different conditions are met
      Bones to peaches support
      Herb cleaning and dropping
        ABC2 antiban with a 10/10 rating
        Telekinetic grab support
      Progressive training (Upgrade gear, switch training spots & more)
        Can bury bones
        Load & save GUI settings
        Profit calculations and xp tracking 
        Start the script from anywhere
      AND MORE!
      AIO Magic Features:
      This script isn't just an AIO combat script, it's also an All In One Magic script!
      The script can train magic using the following methods:
       
        Every single combat spell available, from air strike to ice barrage; It's all supported
        Every single curse spell available
        Stun/combo alching!
      This is the best magic xp in the game, you cast a regular combat spell or curse, quickly followed by a high level alchemy spell.
      This can earn you up to 180k magic xp/hour!
        Splashing!
        All alchemy spells
        All enchantment spells
        Superheat item
        All teleport spells
      The script can also train with the following lunar spells!
        Humidify
        Plank make
        Superglass make
        Tan leather
        Spin flax
        and More!
       
      Purchase info and script trial info:

      Packages:
      ~Free Trial~
      Price: $FREE
       Every month you're allowed a free 10 hour trial with the script, enjoy
       Complete access to all features

       ~2 week Package~ 
      Price: $5
       VIP is not required to run the script
       The ability to train all of combat and magic effortlessly and safely for 2 weeks
       Complete customer support via discord and the TRiBot forums

      To purchase the script or activate your free trial, click the image below:
      https://tribot.org/repository/script/id/651-optimus-combat-magic/

      Gallery
      Click show on the spoiler to view images of the script running
       
      FAQs
    • By gef30
      I've decided to update an old script i wrote 3 years ago, and here it is: Multi Fisher v2! Completely rewritten, with a full implementation of ABC2, Multi fisher allows you to fish anything, anywhere! 
      get it HERE
      Source code: https://github.com/frankkeuning/fisher
      Screenshot(s):
       
      Setup guide:
    • By Optimus
      Hey TRiBot community!
      The script has been in development for the past ~4 Years, but I've recently just rewrote the entire script, and it now performs better than any other. It's been engineered in a way that mimics a human player down to the littlest detail. It uses human like behavior, playing strategies and teamwork, while also simulating human reaction times and mouse movements, making the script extremely powerful and safe to use.
      To purchase the script or activate your free 1 hour trial, visit the repository:
        https://tribot.org/repository/script/id/2770-optimus-pest-control/
      The current features of the script are:
      VIP is not required Free 1 Hour Trial Advanced ABC2 Antiban Three different playing styles:

      -Defend the knight : The script will defend the void knight, and also kill monsters around the portals to keep your activity bar high.

      Attack the portals: The script will kill the portals as they open up, while also attacking spinners and surrounding npcs when necessary.

      -Repair mode (gain no hp XP): Perfect for defence pures, the script will keep you activity high by chopping down trees and repairing the doors / barricades around the map.
        The script generates unique characteristics for each different account. Point spending feature that will purchase desired items from the void shop when you have enough points. Can join a clan chat and follow the team to different worlds. Can fight with quick prayers Uses the special attack of all weapons Drinks all potions Uses a complex algorithm to calculate the order in which portals will open up. Works well with TRiBot's break handler feature You can start the script from anywhere! It will use the PC minigame teleport if necessary. Randomized pathing each game. Efficiently handles brawlers & splatters' User friendly UI with extensive customization Can play in all boats (Novice, Intermediate, Veteran) Fast at entering the boat ( Multi threaded ) Simple and effective paint that displays points / XP gained.
        Below is a video of the script in action, and some screenshots of results that users have achieved. 

      Reaching max points in a single run:

      Reaching max points again:


      Spending max points on 99 HP: 
       
      Spending max points again:
       
      Spending max points again:







      Thanks, 
      Optimus
    • By warlordslay3r
      Hey i recently got the vip with tribot i tried the rockcrabs bots but it was shit it runs around for no reason and script turns of automatically whats a good flawless bot for rockcrabs any recommendation ?
    • By Thebot13
      I think I may have figured out a technique used by the software botwatch they may look at a new account since the new account is at an extremely low ranking of several 100,000 if you continuously train on that account including other methods it uses to detect it must go by ranks as the most primary method of finding and flagging new accounts that are being botted.
       
      This also concerns mains that are botted let's say if you go over an increase of 80,000+ ranks in 24 hours. Then the botWatch system flags or account for a mod to look at. 
       
      I suggest tracking you account closely on CrystalMathlabs and watch your ranking. I would suggest that you stay under the 30,000 rank increase in any given skill
       
      **EDIT This is purely thought based, noone knows how the botwatch programme detects botters.
    • By Zepix
      Hi guys, i have this annoying issue, that whenever i open my Tribot client, it shows a white box, where it says TRiBot Login in the top left, and the rest is just white/blank.
       
      It's been like this for days. I've tried to install and uninstall Java 8, I also tried using Jarfix, etc etc. What can i possibly do, to fix this? 
    • By Optimus
      TRiBot's #1 Script For Training Pures & Mains
      Description:
      Tri Experiment Fighter is a flawless script designed to kill Experiments in the Canafis Dungeon.
      The script was designed not just to be fast, but also to be very stable and human like. With many many people often using the script for days at a time without stopping it. Tri Experiment Fighter is one of the fastest & safest script available to train any type of account with.
       
      Experiments are one of the best monster in the game to train on for all account types because:
      They have 100 hitpoints - Which means you don't have to attack another one often.
      They have a max hit of 2 - Which means they are ideal to train on for pures.
      There are ALOT of them to train on, and the script is capable of fighting in all areas of the dungeon
      They are close to a bank - They are about a 30 second walk away from the Canafis Bank.
      Features:
      Pictures:
      Contact Info / Support:
      If you ever need help with the script, feel free to send me a pm on the forums, or add me on skype and I usually reply within a few hours. My skype is: tri.tribot
      Purchase Information / Pricing:
      Simply click the button below or search for the script on the repository

       
      Thanks for reading
  • Our picks

    • This release will:

      Fix LG for both OSBuddy and RuneLite


      Fix issue where the resizable client isn't able to be made smaller (Thanks @JoeDezzy1)


      Fix detection of the logout game tab when resizable mode and side panels are enabled (Thanks @JoeDezzy1)


      Add initial support for Sentry to allow us to identify and easily debug exceptions happening with all TRiBot users


      Add methods to determine if the bank is actually loaded, and not just the overarching interface (Thanks @wastedbro)



      Upcoming updates:

      Improved CLI support


      Full Sentry support


      Much more
        • Like
      • 62 replies
    • This release will:

      Fix NPE in Camera API (Thanks @wastedbro)


      Update deposit box interface ids (Thanks @Encoded)


      Add various bank methods (Thanks @wastedbro)


      Banking#getWithdrawXQuantity


      Banking#getDefaultWithdrawQuantity


      Banking#arePlaceholdersOn




      Fix resizeable minimap bug (Thanks @wastedbro)


      Remove Java 8 requirement


      Please note: TRiBot is not yet fully compatible with Java 10+




      Fix the break handler issues by ensuring the break handler thread never gets paused


      Fix broken settings hooks



      Upcoming updates:

      Improved CLI support


      Much more



      Note: If you are using LG, please restart both the RS client and TRiBot
        • Like
      • 68 replies
    • This release will:

      Add support for using custom F key bindings to switch between game tabs (Thanks @erickho123)


      Fix tab opening for "Skills" and "Kourend Tasks" (Thanks @erickho123)



      Note: If you are using LG, please restart both the RS client and TRiBot
        • Like
      • 34 replies
    • This release will:

      Fix an issue where breaks would stop firing


      Fix Combat#getWildernessLevel, use dynamic search for text and cache ID for later calls


      Fix an NPE in the Combat API


      Fix Mouse#leaveGame bug where the mouse wouldn't actually leave the game screen
        • Like
      • 21 replies
    • This release will:

      Add LG support for Runelite


      Fix NPCChat issues


      Fix a bug where the camera angle setter would just hold down a key for 5 seconds (the timeout)


      Slightly adjust the rotation via keys to be more accurate


      Add the ability for asynchronous camera movement via keys


      Make Camera rotation via mouse more fluid, with more antiban, and work much better in resizable mode


      Add a "Camera#setCamera" method, allowing the rotation and angle to be set in parallel


      Increase the likelihood of using the mouse for camera movements


      Add support for adjusting the camera to positionable entities (Positionable#adjustCameraTo)



      Upcoming updates:

      Improved CLI support


      Much more



      Note: If you are using LG, please restart both the RS client and TRiBot
        • Thanks
        • Like
      • 59 replies
  • Recently Browsing   0 members

    No registered users viewing this page.

×