Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

Sign up now!

Tutorial Setting up IntelliJ for RuneMate on Windows - Tutorial 1

The only thing Alpha about me is my bots
Joined
Sep 22, 2014
Messages
618
Tutorial 1: Setting up IntelliJ for RuneMate on Windows

This is the first tutorial in a series, if you'd like to see more, take a look at this thread:
https://www.runemate.com/community/...bots-for-runemate-from-novice-to-expert.2322/

This is a comprehensive tutorial which takes you through the steps of downloading, installing, and setting up IntelliJ for RuneMate, assuming a clean install of Windows 8.1 x64:​

To view this content we will need your consent to set third party cookies.
For more detailed information, see our cookies page.
Text-based instructions::
  • Either click here or search 'download jdk' on Google (and select the first result) in order to download JDK. On the download page, select this button:
EwFSxm.png
  • On the next page, select 'Accept License Agreement', and download the appropriate binary for your system (make sure to download the 64-bit binary if you're using a 64-bit operating system).
wZ2Jwh.png
  • Next, once the installer has finished downloading, launch it and complete the installation. You do not need to configure the installer in any way whatsoever.
  • Now, either click here or search 'download intellij' on Google (and select the first result) in order to download IntelliJ. On the download page, select the Community Edition:
AwlRIR.png
  • Next, make sure you've got a copy of the RuneMate.jar file - click here to get the latest version or go to the "Download" page on the website.
  • When the IntelliJ download is finished, you can go ahead and install it - no special configuration is needed here. Next, run IntelliJ.
  • This screen may show up. Unless you have a previous installation, just click "OK".
LdM5Tj.png
  • Next, the 'Customize Idea' screen will show up. Select any options you want, or alternatively, click 'Skip All and Set Defaults':
mb8YgQ.png
  • On the next window, select "Create New Project":
JGb5xt.png

  • Next, you'll be confronted with the window below. You'll need to pick the project SDK.
rgYCbA.png
  • On this window, you'll need to:
    1. Click the "New" button.
    2. On the popup list which appears, click "Java"
    3. Select the path of your JDK installation. This ought to be in the format %Program Files%\Java\jdkx.x.x_xx.
    4. Click "OK".
  • Then, click "Next", and keep doing so until you reach the "Project name" textbox. I called my project Runemate, but you can call it whatever you want:
8DI9xM.png
  • Take note of the Project location. Next, take the RuneMate.jar file which you downloaded earlier, and Copy & Paste it into the Project location directory.
  • Next, you should see an image like the one below. Press Alt+1 in order to open up the sidebar, as shown below:
KwZ2Tm.png
  • Next, click the button circled in red in the image above in order to open the "Project Structure" dialogue, as shown:
KMr63U.png
  • Once the dialogue is visible:
    1. Select "Modules"
    2. Ensure that the "Java x.x" module is present
    3. Click the green "+" button
    4. Select "JAR"
  • Next, a dialogue should appear prompting you to select a file. Select RuneMate.jar, as which you should have just pasted into your project's base directory, as shown:
rAjltR.png
  • Once this is done, click "OK" on both dialogues to close them.
  • Next, on the main IntelliJ window, select Run -> Edit Configurations...
dAgb68.png
  • On the dialogue which appears, click the "+" button, and select "Application", as shown:
f3M1C7.png
  • Fill out the information on the debug configuration likeso (but replace my username with yours):
XIYaqq.png

  • For convenience, the contents of each of the fields is:
    • Code:
      com.runemate.Boot
    • Code:
      -sdk -login=FORUMUSERNAME:FORUMPASSWORD:GAMETYPE
    • Note that only -sdk is necessary in this field. GAMETYPE can be OSRS or RS3. The rest is for convenience
    • You might also do well to give the configuration a name, as the name is specified as "Untitled" in the screenshot
    • When this is done, click "OK".
  • Now you're ready to start creating some packages. If it's not open, press ALT+1 in order to open the project sidebar.
    • Now right click the "src" folder, and create a new package. You can call the package something along the lines of "com.yourname.bots".
    • Inside this package, create a new class called "testbot". When finished, your package structure should look like this (not that I've disabled flattening of packages in this screenshot, so yours might look slightly different.
ccy4nw.png
  • Open the testbot class, and add the following code:
NTi0wY.png
  • If you'd like a cursory explanation of what this code actually does, please refer to the video tutorial at 7:30.
  • Next, right click your "testbot" package on the project sidebar, and create a new file called "testbot.manifest.xml". After you're done, your project structure ought to look something like this:
PrZ4Tb.png

  • Open the testbot.manifest.xml and add the following XML:
IyhvUg.png
  • Again, if you'd like an explanation of what this does, please refer to the video tutorial.
  • You're now ready to debug for the first time. Press the green play button on the top right of the IDE:
Kh209n.png
  • RuneMate ought to show up. Once it's loaded, press the "Start Bot" button. If no bots show up, then click the "Change Directory" button (this is expected but may not always be the case). An open file dialogue ought to appear.
    • Make sure that once it appears, you select the directory above the "com" directory in the "out" directory of your project. It ought to look something like this:
1jRQ1G.png
  • If you did everything correctly, a bot ought to show up in the list called "Test bot". Once it appears, then select it and click the start button.
  • If a message appears in the debug window like the one below, then you've got your first bot set up with RuneMate! Congratulations!
oQ02Wu.png



If you'd like to see more tutorials by me, see the tutorial index, here: https://www.runemate.com/community/...bots-for-runemate-from-novice-to-expert.2322/
 
Last edited:
The only thing Alpha about me is my bots
Joined
Sep 22, 2014
Messages
618
Pretty well. I'm currently uploading & processing no.2
 
The only thing Alpha about me is my bots
Joined
Sep 22, 2014
Messages
618
How can I use proxy with this? Cuz now it skips the settings for proxy.

I'm unsure of whether RM accepts proxy configuration as a commandline argument, so for now you can probably just remove the username & password configuration, or you could ask @Cloud if this feature is planned/implemented.
 
Joined
Jun 5, 2015
Messages
5
It says "Unrecognized option: -sdk" for me when I run it.

----------------------------------
Wrote it in the wrong field. My bad.
 
Last edited:
Joined
Oct 2, 2015
Messages
44
I followed all the steps its not giving me any errors its opening Runemate when I compile but my test bot isn't showing up even going into development mode I change the directory and its not showing my scripts
 
Joined
Jun 28, 2015
Messages
39
I followed all the steps its not giving me any errors its opening Runemate when I compile but my test bot isn't showing up even going into development mode I change the directory and its not showing my scripts

I'm having the same issue as whitlock is there any chance we can get some help with this?
 
Joined
Oct 13, 2015
Messages
10
What about DarkScape in the part where I need to input my forum credentials and the game type? DS? or what?
 
Joined
Sep 25, 2015
Messages
8
Nov 05, 2015 10:36:15 AM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
(10:36:16) [Login] Attempting to login with the specified credentials
(10:36:18) [Login] The requested user 'Oh_Gawd' could not be found.
(10:36:18) [Debug] Version: 1.2.17
(10:36:18) [Debug] Operating System: Windows 8.1 (x64)
(10:36:18) [Debug] Java: 8 Update 65 (x64) (Oracle Corporation)

I have a space in my name, so how exactly would that work? It won't log in automatically even if I enter a space.
 
Joined
May 1, 2016
Messages
42
com.runemate.boot.Boot (if you're still having an issue)

Was an issue with IntelliJ and Spectre. I have to launch spectre manually in -sdk mode. Launching it from the IDE causes 32bit/64bit issues even with proper run configurations.
 
Top