Class MouseSettings


  • public class MouseSettings
    extends java.lang.Object
    Do not worry about this class too much. This class specifies the settings for the mouse controller.
    • Constructor Detail

      • MouseSettings

        public MouseSettings​(org.dreambot.core.Instance instance)
    • Method Detail

      • getMouseTiming

        public static MouseTiming getMouseTiming()
        Returns the client's mouse timing generator, used to determine the time in milliseconds between pressing down and releasing the mouse buttons
        Returns:
        The current mouse timing generator
      • setMouseTiming

        public static void setMouseTiming​(MouseTiming mouseTiming)
        Parameters:
        mouseTiming - Sets the client's mouse timing generator
      • getSpeed

        public static int getSpeed()
        Returns the client's current speed, between 1 and 100.
        Returns:
        Mouse speed, 1 (slowest) to 100 (hopping)
      • setSpeed

        public static void setSpeed​(int accel)
      • getRectDest

        public java.awt.Rectangle getRectDest()
      • setRectDest

        public MouseSettings setRectDest​(java.awt.Rectangle rectDest)
      • r

        public double r()
      • getMaxdTheta

        public int getMaxdTheta()
      • getDecelRadiusDeviation

        public int getDecelRadiusDeviation()
      • getDecayDistanceExponent

        public double getDecayDistanceExponent()
      • getMinMagnitude

        public int getMinMagnitude()
      • getAccelerationDeviation

        public int getAccelerationDeviation()
      • getMinDecelMagnitude

        public int getMinDecelMagnitude()
      • getMaxDecelDistance

        public int getMaxDecelDistance()
      • getAccelerationRate

        public int getAccelerationRate()
      • getMaxMagnitude

        public int getMaxMagnitude()
      • getDecelDecayRate

        public double getDecelDecayRate()
      • getAngleDeviationRate

        public int getAngleDeviationRate()
      • getMeanDecelRadius

        public int getMeanDecelRadius()
      • getCalcsPerSecond

        public int getCalcsPerSecond()
      • isWalking

        public boolean isWalking()
      • setTarget

        public MouseSettings setTarget​(java.lang.String action,
                                       java.lang.String object)
        Sets the target
        Parameters:
        action - Action to set as target
        object - Object to set as target
      • getAction

        public java.lang.String getAction()
        Gets the action of the target
        Returns:
        Action
      • setAction

        public MouseSettings setAction​(java.lang.String action)
        Sets the action
        Parameters:
        action - Action to set as target
      • getObject

        public java.lang.String getObject()
        Gets the object of the target
        Returns:
        object name
      • setObject

        public MouseSettings setObject​(java.lang.String object)
        Sets the object
        Parameters:
        object - Object to set
      • isMultiThread

        public boolean isMultiThread()
        Whether or not it is multithreaded
        Returns:
        True or false
      • setMultiThread

        public void setMultiThread​(boolean multiThread)
        Sets multithreaded true or false
        Parameters:
        multiThread - True or False
      • isLeftClick

        public boolean isLeftClick()
        Returns whether it's left click
        Returns:
        True or False
      • setLeftClick

        public MouseSettings setLeftClick​(boolean leftClick)
        Sets whether it's left click
        Parameters:
        leftClick - True or False
      • isRightClick

        public boolean isRightClick()
        Gets whether it's right click
        Returns:
        True or False
      • setRightClick

        public MouseSettings setRightClick​(boolean rightClick)
        Sets right click
        Parameters:
        rightClick - True or False
      • isClick

        public boolean isClick()
        Gets whether should click
        Returns:
        True or False
      • setClick

        public MouseSettings setClick​(boolean click)
        Sets click
        Parameters:
        click - True or False
      • isOvershoot

        public boolean isOvershoot()
        Gets whether it should overshoot
        Returns:
        True or False
      • setOvershoot

        public MouseSettings setOvershoot​(boolean overshoot)
        Sets overshoot
        Parameters:
        overshoot - True or False
      • isDrag

        public boolean isDrag()
        Gets whether it should drag
        Returns:
        True or False
      • setDrag

        public MouseSettings setDrag​(boolean drag)
        Sets drag
        Parameters:
        drag - True or False
      • getBounds

        public java.awt.Rectangle getBounds()
        Gets the Rectangle of the bounds
        Returns:
        Rectangle of bounds
      • setBounds

        public MouseSettings setBounds​(java.awt.Rectangle bounds)
        Sets bounds the mouse cannot leave during events
        Parameters:
        bounds -
      • reset

        public void reset()
        Resets mouse settings
      • getPreferredHand

        public MouseSettings.Hand getPreferredHand()
        Gets preferred hand
        Returns:
        Hand (Left/Right)
      • setPreferredHand

        public void setPreferredHand​(MouseSettings.Hand preferredHand)
        Sets preferred hand (Left/Right)
        Parameters:
        preferredHand - (Hand.LEFT, Hand.RIGHT)
      • isUseMiddleMouseInInteracts

        public boolean isUseMiddleMouseInInteracts()
      • setUseMiddleMouseInInteracts

        public void setUseMiddleMouseInInteracts​(boolean useMiddleMouseInInteracts)