# Thread: Complete Guide to Setting Up Simba and SRL

1. ## Complete Guide to Setting Up Simba and SRL

Complete Guide to Setting Up Simba and SRL
Verified Working On: October 21, 2019

Part 1: Simba & Old School Runescape
Part 2: Simba & Runescape 3 (OUTDATED)
Part 3: Questions and Help

Part 1: Simba & Old School Runescape

This post teaches you how to install and properly setup Simba to work with Old School Runescape.

Introduction

Simba is the open source program that we use to write, compile, and run all of the code used in the Runescape scripts found on the forum. This means that if you plan to write your own script or one that has been posted on the site, you will need to make sure Simba is installed correctly as well as the proper include (more on this later) to be able to have the script compile and run. The language used in Simba is called Lape.

Now that you have a bit of an understanding of Simba, let's get started.

Setting up

Before we jump into it, you should know about the different types of includes that we have on the forums. In the case you do not already know, an include or library is a collection of code that is already written in such a way to allow the programmer to accomplish a specific task with ease by giving the programmer a collection of methods/functions/procedures to use. Below you will find the different types of includes that are available for OldS chool Runescape. Each is linked to their development threads or Github pages, as well as some tutorials to help you make up your mind on which one you feel is best for you. For this tutorial, I will show you how to install the Old School Runesape SRL-OSR library.

Old School Runescape Includes

Installing Java
1. Get the latest 32-Bit version of Java from Oracle's Java Download Page.
2. After downloading the installer, run it and install to your computer. It is recommended that you install to the default location since there is a lower possibility that Simba cannot find the Java installation folder.

NOTE: You may be a little confused as to why we are needing to install Java since Runescape does not completely depend on it anymore. The primary reason we do this is that we use a program known as S.M.A.R.T. which is a virtual environment that runs the Java version of Runescape and allows you to have multiple bots running concurrently. We do this in the case that you want to be able to use S.M.A.R.T. but it is not always necessary. You can read here for more information about how to run multiple instances without S.M.A.R.T.

How to install/setup Simba 1.3 for Old School Runescape

Simba 1.3 has been updated to include more features and make writing and editing scripts a bit easier. This update currently only works with the OSR Include. If you are interested in trying it out, you can follow the steps to setting it up below.
1. Download Simba 1.3 from here and place it in the directory "C:\Simba 1.3".
2. Open up Simba and open the Package Manager by clicking the icon.
3. In the Packages window, press the Add button and paste the following link and hit 'OK'
Code:
https://github.com/srl/srl
4. Press Install and overwrite the installation directory.
5. Repeat the last two steps with the following links:
Code:
https://github.com/srl/srl-plugins
https://github.com/srl/srl-fonts
https://github.com/ollydev/RSWalker
6. Restart Simba and paste the following program into Simba:
Simba Code:
program new;{$define SMART} //If not using SMART, then comment this line out{$I SRL/OSR.simba}{$I RSWalker/Walker.simba}begin clearDebug(); srl.Setup([]);end. 7. Compile the program by selecting Script->Compile or by pressing Control Key + F9. After a couple of seconds you should see the output: Code: Compiled successfully in XXXX ms. 8. Since we now know that there are no errors in the code, we can run it by selecting Script->Run, by pressing F9, or by pressing the Green Play Button in the toolbar. This will cause SMART to load and will terminate the program. In the debug section in Simba, you should see: Code: Successfully executed. If you wish to read more about the features of Simba 1.3 and its updates, click here to view the original thread. In-game Graphics Congratulations! We are almost done! All we have to do now is worry about making sure our in-game interfaces are setup correctly. Each version of Runescape has to be setup a little differently, so be sure to pay close attention. • Open up the in-game settings after you have logged in on your account and set brightness to max and set zoom to max. • Set window size to 'Fixed'. • Then click on the Advanced Options button and enable Roof-removal. • Not needed but recommended you also enable Shift Click Drop under the Controls section. Now you are ready to get running with Old School Runescape scripts! Last edited by StickToTheScript; 10-21-2019 at 05:49 PM. Reason: Updated. 2. Part 2: Simba & Runescape 3 (OUTDATED) Note: The SRL for RS3 is not currently functional and needs to be updated. Once a functioning version is released, this post will be updated. This post teaches you how to install and properly setup Simba to work with Runescape 3. Introduction Simba is the open source program that we use to write, compile, and run all of the code used in the Runescape scripts found on the forum. This means that if you plan to write your own script or one that has been posted on the site, you will need to make sure Simba is installed correctly as well as the proper include (more on this later) to be able to have the script compile and run. The language used in Simba is called Lape. Now that you have a bit of an understanding of Simba, let's get started. Setting up Before we jump into it, you should know about the different types of includes that we have on the forums. In the case you do not already know, an include or library is a collection of code that is already written in such a way to allow the programmer to accomplish a specific task with ease by giving the programmer a collection of methods/functions/procedures to use. Below you will find the different types of includes that are available Runescape 3. Each is linked to their development threads or Github pages, as well as some tutorials to help you make up your mind on which one you feel is best for you. For this tutorial, I will show you how to install the Runescape 3 SRL-6 library. Runescape 3 Includes Installing Java 1. Get the latest 32-Bit version of Java from Oracle's Java Download Page. 2. After downloading the installer, run it and install to your computer. It is recommended that you install to the default location since there is a lower possibility that Simba cannot find the Java installation folder. NOTE: You may be a little confused as to why we are needing to install Java since Runescape does not completely depend on it anymore. The primary reason we do this is that we use a program known as S.M.A.R.T. which is a virtual environment that runs the Java version of Runescape and allows you to have multiple bots running concurrently. We do this in the case that you want to be able to use S.M.A.R.T. but it is not always necessary. You can read here for more information about how to run multiple instances without S.M.A.R.T. How to install/setup Simba for Runescape 3 1. Download and install Simba from here. 2. Open Simba.exe and select Script->Interpreter->Lape. 3. Open up View->Extensions 4. A window should appear with a list of red and green extensions. Make sure to enable the following (these lines should be green): Code: associate.sex extension.sex srl.sex 5. Close the window and click on Extentions->Check for Updates. 6. Restart Simba when the updates have finished. 7. Click on SRL->Check for Updates 8. Click on SPS->Check for Updates 9. Click on Plugins->Check for Updates NOTE: If you happen to run into any problems, you can download SRL-6 from here, download SPS from here and place their respective folders in "C:\Simba\Includes". You can download Plugins from here and place the folder in "C:\Simba". 10. Restart Simba one last time. 11. Paste the following program into Simba: Simba Code: program new;{$define SMART} //If not using SMART, then comment this line out{\$i srl-6/srl.simba}        begin  clearDebug();  setupSRL();  end.
12. Compile the program by selecting Script->Compile or by pressing Control Key + F9. After a couple of seconds you should see the output:
Code:
Compiled successfully in XXXX ms.
13. Since we now know that there are no errors in the code, we can run it by selecting Script->Run, by pressing F9, or by pressing the Green Play Button in the tool bar. This will cause SMART to load and will terminate the program. In the debug section in Simba, you should see:
Code:
SRL: Logfile = C:\Simba\Includes\SRL-6/logs/SRL log (XX-XX-XX at XX.XX.X XM).txt
-- setupSRL()
---- Setting up SRL...
---- attempting to spawn smart, attempt #: 1
---- initSmart():
------ Attempting to pair to a previously spawned client
------ smartPairToExistingClient():
-------- Found 1 free client(s), attempting to pair to one...
-------- Failed to pair to SMART[1424]
------ smartPairToExistingClient(): result = false
------ Attempting to spawn a new client..
------ smartCreateClient():
-------- getJavaPath():
---------- Attempting to search for your Java path
---------- Found your java path @ C:\Program Files (x86)\Java\jreX.X.X_XXX\bin\java.exe
-------- getJavaPath()
-------- Root: http://world1.runescape.com/
-------- Params: ,XX,XXXXXXXXXXXXXXXXXXXX
-------- Using plugins "OpenGL32.dll,d3d9.dll"
-------- Succesfully spawned a client, attempting to target
---------- smartSetAsTarget(): Succesfully set SMART[XXXX] as Simba's target
------ smartCreateClient(): result = true
------ Succesfully initialized via spawning a new client
---- initSmart() result = True
---- Waiting up to 5 minutes for RS to load...
---- Setup SRL in XX Seconds
-- setupSRL(): True
-- Succesfully freed SMART[XXXX]
Successfully executed.

NOTE: If you do not wish to have the console window visible, you can disable it by pressing the Hide/Show Console button in the to

In-game Graphics

Congratulations! We are almost done! All we have to do now is worry about making sure our in-game interfaces are setup correctly. Each version of Runescape has to be setup a little differently, so be sure to pay close attention.

• Open up the in-game settings after you have logged in on your account and set Load Layout to Old School.
• Then click on the Settings button and enter the Interface tab.
• Set your Interface Settings to match:
• Click on Graphics and set detail to Low.

Now you are ready to get running with Runescape 3 scripts!
Last edited by StickToTheScript; 10-21-2019 at 05:48 PM.

3. Part 3: Questions & Help

This post is about what to do if you have any questions or need help.

Places To Get Help

There are multiple places to get help from other members of the forums. You can:

Start Programming

Visit the Help & Tutorials section if you are ready to try writting your first script! You will find lots of help and tutorials for Runescape 3, Old School Runescape, other programming languages, and more!

Here are a couple of generic scripting tutorials that I would recommend you check out:

Once you have completed your first script and you would like some feedback, feel free to post them to the First Scripts Section. Otherwise, you can freely post them in the Runescape 3 Public Scripts Section or the Old School Runescape Public Scripts Section.

Simba Documentation

The Simba Documentation has lots of information that can often answer general questions and inform you about how Simba works. If you have not taken a look through it yet, I would highly recommend it.

NOTE: Keep in mind that some of the information in the documentation is out of date but that does not mean it is not relevant.

Below you will find common frequently asked questions and their solutions. As more are discovered, they will be posted here.

Currently under construction

• What is Simba and is it safe to use?
Most of your questions regarding Simba can be answered by visiting the Simba Documentation. You will also find that since it is an open source project, both your computer and your account are safe.

• There are so many includes. Which one do I choose?
If this is your first time ever programming, I'd recommend that you start with SRL-6 for RS3 and either SRL-OSR or AeroLib for Old School. If you are a little more advanced already, feel free to experiment and look through the information given by the others. If you're still stuck on trying to figure it out, feel free to post or PM me and I'll help you out!

• I am getting errors while attempting to install. What is wrong?
If you are ever stuck with getting errors while attempting to install an include, feel free to jump in on our chat services and ask away! There is a large number of people willing to help! Just remember, be specific when asking questions!

• I followed the tutorial but nothing works. What do I do?
It is possible that you happened to skip over a step, place something in the wrong location, or just made some sort of mistake along the way. If this happened, just try to uninstall Simba and delete the installation folder and try all the steps again. If this still did not work, you are more than welcome to post here and we will do our best to help you out!

• I am getting errors when attempting to load SMART (or any other Java related errors)
When choosing which version of the Java Development Kit (JDK) to install, make sure you choose the 32-Bit version. The 64-Bit version will not work.

• I am able to load an instance of SMART but cannot get my player to log in.
It is possible that even though SMART gets loaded, Simba hasn't be setup to target the client. To do this you can simply:
Targeting SMART

And in the output, you should get:
Code:
New window: XXXXXX
Try pressing 'Run' again.
• I am getting the error: 'Error: File "XXX/XXX.simba" not found at line X'
This error is most likely because you have not installed the include you are attempting to use properly. Make sure that the include you downloaded is named properly in your Includes folder to what you are attempting to run. For example, the Old School Includes should be labled as such:
Example of Folders

Credit: @slacky
This means that you have not correctly updated all of your libraries/includes. To do this, we can follow the following instructions:
Update via Simba

Originally Posted by slacky
Open Simba 1.1 [Simba.exe], find the SRL menu, navigate down to "Automatically.." disable "Update" and "Check for update". Now repeat these steps under the plugin menu as well.

Once done, you must naviage to the plugin menu once more, and this time under "Settings" select override update if it's not already. Now still under the plugin menu, click "Update" and wait for it to update.

The problem should no longer appear, nor reappear.

Again, as always, use Simba 1.2Rc to run your script. Let there be no confusion about that.
• I am getting the error: 'Error: Plugin(SimpleOCR32) has not been found'
This is most likely because of a problem with your antivirus. The file is completely safe to use, it just gets flagged by certain AV's. You can add the Plugins folder to your AV's ignore list if you wish to continue using it regularily.

If anything is missing or needs to be corrected, please let me know and I'll update it as soon as possible.

If you have anything to contribute, please let me know and I can include it.

NOTE: For those with their own modified versions of the includes, I have not included those since I am trying to keep things simple.
Last edited by StickToTheScript; 09-07-2018 at 03:21 AM. Reason: Updated FAQ

4. Wow, this is awesome! Thanks for putting all of this together. It must have been a lot of work.

One thing I noticed:
You probably shouldn't replace the official version of Simba. There's no reason not to keep both around (for now).

5. Originally Posted by Citrus
Wow, this is awesome! Thanks for putting all of this together. It must have been a lot of work.

One thing I noticed:

You probably shouldn't replace the official version of Simba. There's no reason not to keep both around (for now).
Ha ha! Thanks! I completely agree. I accidentally wrote replace instead of place. All fixed.
Last edited by StickToTheScript; 04-22-2018 at 10:00 AM.

6. Very nice tutorial, something the forum desperately needed. Thank you!

7. Great work! Nice to see this on the front page as well!

8. Registered User
Join Date
Apr 2018
Posts
1
Mentioned
0 Post(s)
Quoted
0 Post(s)
good post

9. SRL Junior Member
Join Date
Jul 2017
Posts
30
Mentioned
0 Post(s)
Quoted
15 Post(s)
SRL Updater: Local Version - "1" | Remote Version = "1403"
SRL Updater: Update File - "http://wizzup.org/static/srl/srl-6.tar.bz2"
SRL Updater: Decompressing...

5 Minutes later.
You'll have to manually update the SRL.
Last edited by Grendal; 04-29-2018 at 05:33 AM.

10. Originally Posted by Grendal
SRL Updater: Local Version - "1" | Remote Version = "1403"
SRL Updater: Update File - "http://wizzup.org/static/srl/srl-6.tar.bz2"
SRL Updater: Decompressing...

5 Minutes later.
You'll have to manually update the SRL.
You just have to use the package manager in the referred Simba version to update. And if you also use the old simba (<= 1.1), and there are update conflicts, then you just disable it's updater.

The "SRL Updater", is not part of the Simba version recommend in this tutorial (hereafter referred to as Simba X). So that message is from Simba 1.1, and only happens because of the package manager which is in Simba X isn't compatible with the updater in 1.1. So roughly what happens is that the updater in Simba 1.1 doesn't know what version of SRL-6 you have, so it just updates SRL-6 itself.

Refering to the referenced version of Simba as Simba X because it's NOT Simba 1.3 as the name suggest, nor is it Simba 1.2, just simply a fork of Simba that expands on Simba 1.2 with experimental features and changes.
Last edited by slacky; 04-29-2018 at 07:37 PM.

11. Registered User
Join Date
Apr 2018
Posts
5
Mentioned
1 Post(s)
Quoted
4 Post(s)
Hey, thanks very much for the tutorial. I'm having an issue though... Despite uninstalling and starting over a couple times my script doesn't return from the srl.Setup procedure. The SMART window opens but nothing called after the setup procedure is executed. Any ideas?

12. Originally Posted by doodle3
Hey, thanks very much for the tutorial. I'm having an issue though... Despite uninstalling and starting over a couple times my script doesn't return from the srl.Setup procedure. The SMART window opens but nothing called after the setup procedure is executed. Any ideas?
Does anything show up in the debug box in Simba when you run it?

Also, since SMART does open, it does mean that Simba, as well as the includes, are installed properly.

13. Originally Posted by StickToTheScript
Does anything show up in the debug box in Simba when you run it?

Also, since SMART does open, it does mean that Simba, as well as the includes, are installed properly.
for runtime hints about errors that occur:
> srl.Setup();
> srl.Setup([]);

@doodle3 ^

14. Registered User
Join Date
Apr 2018
Posts
5
Mentioned
1 Post(s)
Quoted
4 Post(s)
So with srl.Setup() I get the following time out error

Code:
Compiled successfully in 2703 ms.
Setting up
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
[00:00:00]: Smart.Init()
[00:00:00]: -Smart.PairToExisting()
[00:00:00]: --Free clients: [3832]
[00:00:00]: --Succesfully paired to existing client; SMART[3832]
[00:00:00]: -Smart.PairToExisting(): Result = True
[00:00:00]: Smart.Init(): Result = True
[00:03:00]:[FATAL]: Timed out waiting for client. Make sure OSRS is setup correctly
[00:03:00]: Freeing SMART[3832]
Successfully executed.
Seems as though isClientReady isn't returning true

15. Originally Posted by doodle3
So with srl.Setup() I get the following time out error

Code:
Compiled successfully in 2703 ms.
Setting up
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
[00:00:00]: Smart.Init()
[00:00:00]: -Smart.PairToExisting()
[00:00:00]: --Free clients: [3832]
[00:00:00]: --Succesfully paired to existing client; SMART[3832]
[00:00:00]: -Smart.PairToExisting(): Result = True
[00:00:00]: Smart.Init(): Result = True
[00:03:00]:[FATAL]: Timed out waiting for client. Make sure OSRS is setup correctly
[00:03:00]: Freeing SMART[3832]
Successfully executed.
Seems as though isClientReady isn't returning true
Thought so. This should be able to be fixed by click and dragging the cross-hairs in simba to the SMART window:

And in the output, you should get:
Code:
New window: XXXXXX

Then try running the program again and it should work for you.

16. Registered User
Join Date
Apr 2018
Posts
5
Mentioned
1 Post(s)
Quoted
4 Post(s)
Ahh that looked promising but it still doesn't seem to be able to detect the login screen

Code:
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
[00:00:00]: Smart.Init()
[00:00:00]: -Smart.PairToExisting()
[00:00:00]: --Free clients: [11480]
[00:00:00]: --Succesfully paired to existing client; SMART[11480]
[00:00:00]: -Smart.PairToExisting(): Result = True
[00:00:00]: Smart.Init(): Result = True
New window: 4917400
[00:03:00]:[FATAL]: Timed out waiting for client. Make sure OSRS is setup correctly
[00:03:00]: Freeing SMART[11480]
Successfully executed.
After more digging it seems to be the procedure LoginScreen.IsOpen never returns true

17. Originally Posted by doodle3
Ahh that looked promising but it still doesn't seem to be able to detect the login screen

Code:
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
[00:00:00]: Smart.Init()
[00:00:00]: -Smart.PairToExisting()
[00:00:00]: --Free clients: [11480]
[00:00:00]: --Succesfully paired to existing client; SMART[11480]
[00:00:00]: -Smart.PairToExisting(): Result = True
[00:00:00]: Smart.Init(): Result = True
New window: 4917400
[00:03:00]:[FATAL]: Timed out waiting for client. Make sure OSRS is setup correctly
[00:03:00]: Freeing SMART[11480]
Successfully executed.
After more digging it seems to be the procedure LoginScreen.IsOpen never returns true
make sure you got the latest SRL release. There was a bugfix like 11 days ago that solved an issue that caused something like this error. So just make sure.

18. Registered User
Join Date
Apr 2018
Posts
5
Mentioned
1 Post(s)
Quoted
4 Post(s)
Originally Posted by slacky
make sure you got the latest SRL release. There was a bugfix like 11 days ago that solved an issue that caused something like this error. So just make sure.
Here's a quick video of my update/run process, I should be using the most recent SRL code

Apologies, I can't actually link it yet

19. Registered User
Join Date
Apr 2018
Posts
5
Mentioned
1 Post(s)
Quoted
4 Post(s)
Code:
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
Range check error at line 197
Execution failed.
The following bitmaps were not freed: [0, Minimap mask]
New error, this is after commenting out smart and using the regular oldschool client.

This is right after logging in manually, on the welcome screen. Error occurs in FindColorsTolerance file.

20. Originally Posted by doodle3
Code:
[00:00:00]: Setting up SRL for OSR
[00:00:00]: Waiting for client to load...
Range check error at line 197
Execution failed.
The following bitmaps were not freed: [0, Minimap mask]
New error, this is after commenting out smart and using the regular oldschool client.

This is right after logging in manually, on the welcome screen. Error occurs in FindColorsTolerance file.
Retarget RS with simba, and try again

when i try to compile script, i have downloaded all the files i needed to>

My includes folder :includes.PNG

Simba folder :
simba.PNG
Last edited by randy marsh; 05-07-2018 at 05:43 PM.

22. Originally Posted by randy marsh

when i try to compile script, i have downloaded all the files i needed to>

My includes folder :includes.PNG

Simba folder :
simba.PNG
Your include setup is wrong - you need to put the contents of the extracted zips into \Includes\ so it ends up being \Includes\srl\osr.simba, without the extra SRL-1.03 directory in between.

23. Originally Posted by Clarity
Your include setup is wrong - you need to put the contents of the extracted zips into \Includes\ so it ends up being \Includes\srl\osr.simba, without the extra SRL-1.03 directory in between.

Arghhh im so confused sorry I never used simba before just used to use srl way back in the day.
Do you have a screenshot of correct folder layout?

I did put the extracted zips in to \Includes\
Last edited by randy marsh; 05-07-2018 at 08:29 PM.

24. Originally Posted by randy marsh
Arghhh im so confused sorry I never used simba before just used to use srl way back in the day.
Do you have a screenshot of correct folder layout?

I did put the extracted zips in to \Includes\

The contents may differ slightly, but should by quite similar, like the .gitattr file is irrelevant.

Here is my a little tutorial for setting up SRL and RSWalker, it contains some extra steps (that are implied in this tutorial) that may clarify shit for you:
Last edited by slacky; 05-07-2018 at 09:12 PM.

25. Ty so much!!!!!!!!!!!!!!!!
Now i got set up aerolib

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•