Jump to content

Help me with a simple GE walking script (first script)


Recommended Posts

Posted

Position[] path = { new Position(3234, 3219, 0), new Position(3235, 3225, 0), new Position(3238, 3225, 0), new Position(3246, 3225, 0), new Position(3254, 3225, 0), new Position(3258, 3229, 0), new Position(3259, 3234, 0), new Position(3259, 3241, 0), new Position(3256, 3245, 0), new Position(3252, 3251, 0), new Position(3250, 3256, 0), new Position(3250, 3263, 0), new Position(3249, 3267, 0), new Position(3246, 3271, 0), new Position(3244, 3274, 0), new Position(3240, 3280, 0), new Position(3238, 3282, 0), new Position(3238, 3286, 0), new Position(3238, 3293, 0), new Position(3239, 3306, 0), new Position(3246, 3311, 0), new Position(3250, 3319, 0), new Position(3256, 3323, 0), new Position(3263, 3324, 0), new Position(3269, 3328, 0), new Position(3268, 3329, 0), new Position(3261, 3332, 0), new Position(3256, 3335, 0), new Position(3246, 3336, 0), new Position(3234, 3336, 0), new Position(3228, 3337, 0), new Position(3225, 3343, 0), new Position(3226, 3350, 0), new Position(3223, 3356, 0), new Position(3216, 3361, 0), new Position(3213, 3369, 0), new Position(3211, 3376, 0), new Position(3211, 3389, 0), new Position(3211, 3400, 0), new Position(3211, 3413, 0), new Position(3211, 3419, 0), new Position(3208, 3426, 0), new Position(3205, 3428, 0), new Position(3199, 3428, 0), new Position(3192, 3429, 0), new Position(3186, 3429, 0), new Position(3182, 3430, 0), new Position(3182, 3441, 0), new Position(3182, 3448, 0), new Position(3179, 3452, 0), new Position(3172, 3455, 0), new Position(3167, 3460, 0), new Position(3165, 3463, 0), new Position(3165, 3472, 0), new Position(3164, 3478, 0) };

above is the path code from Explv's Map

Problem is, I don't know how to put it into a completely clean easy to read script without any paint or GUI. I'm just going to be logging in fresh from tutorial island accounts and need the script to follow the exact path on each account, no randomisation or anti ban needed.

Posted (edited)

Those are the only 2 lines? So geArea is a function sort of that you created the name for in the line above? And the 4 cords? Isn’t it normally just an X Y? Example of how I could change it to stay or for example would be to just change the name to anything as long as the cords are correct?

 

and then what is the reason you are able to script coordinates of a path using his map tool?

Edited by Molten
Posted (edited)
@ScriptManifest(name = "GEWalker", author = "Your name", version = 1.0, info = "Script info", logo = "")  //Helps the client understand and find the script we compile

public class Skeleton extends Script {

    @Override

    public void onStart() {
        /**
         * Excellent for starting timers (getExperienceTracker.startAll(); , Timer afkTimer = new Timer(180_000) //180_000 ms = 3 mins)
         * Initiate variables here (Excluding NPC, RSObject, ....) [Uses: myVal = 99, currentXP = getSkills().getStatic(Skill.ATTACK)]
         * & More
         */
    }

    

    @Override

    public void onExit() {
        /**
         * Excellent for clearing listeners that we implement
         * Logging end script info
         * & More
         */
    }

    @Override

    public int onLoop() {
	Position[] positions = ...
	WalkingEvent event = new WalkingEvent();
	event.setPath(new LinkedList<Position>(Arrays.asList(positions)));
	execute(event);
       return 700; //Usually want to keep it over 600MS unless you need a fast loop. 1000MS = 1 second.
    }

    @Override

    public void onPaint(Graphics2D g) {
        
    }

}

 

5 minutes ago, Molten said:

 

 

and then what is the reason you are able to script coordinates of a path using his map tool?

 

Edited by Chris
Posted

Alright thanks for the fast replies everyone. I’ll take a bit of a look at that longer script that was posted after I’m off of work. Does this mean that webwalker already has a list of commands Or banks you can execute in a script like that? If so where can I find this list and also I was hoping it would be more flexible to be able to path anywhere in the game as I’m just starting here with my first scripts but I will eventually be making my own suicide bot farm

Posted
18 minutes ago, Molten said:

Alright thanks for the fast replies everyone. I’ll take a bit of a look at that longer script that was posted after I’m off of work. Does this mean that webwalker already has a list of commands Or banks you can execute in a script like that? If so where can I find this list and also I was hoping it would be more flexible to be able to path anywhere in the game as I’m just starting here with my first scripts but I will eventually be making my own suicide bot farm

webWalker lets you walk almost anywhere. It finds its own path.

Posted (edited)
2 hours ago, Molten said:

Those are the only 2 lines? So geArea is a function sort of that you created the name for in the line above? And the 4 cords? Isn’t it normally just an X Y? Example of how I could change it to stay or for example would be to just change the name to anything as long as the cords are correct?

 

and then what is the reason you are able to script coordinates of a path using his map tool?

People create their own Paths because they don't want to use the generic webwalker at times or if you want to take specific routes

Edited by Juggles
Posted
2 hours ago, Molten said:

I was hoping it would be more flexible to be able to path anywhere in the game

You can set any area as an area to webwalk to. The Area(X, Y, X, Y) you see is the X and Y for one point and X and Y for a second point to make a rectangle area.  Webwalk will finish somewhere in that area. API here

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...