Skip to content

McLib Framework Documentation

bmckalip edited this page May 23, 2018 · 14 revisions

W.I.P. Docs

Getting started

There are two ways to install McLib. Each with pros and cons. Method 1 allows you to make many scripts in a streamlined fashion with an extra step when it comes time to

There are two ways to install this module. You can either install it in the same package as your script's entrypoint file location, which allows you to quickly upload to the SDN without any extra steps, or the second method where you can add McLib as a module in your project, create a module dependency on it from your script, which allows you to easily reuse that added package in other scripts you write. However, when it comes time to upload your script to the SDN, this comes at the cost of having to copy McLib to your script's package before compiling, because Dreambot doesn't support uploading project dependencies.

First Option (Quick and Dirty):

W.I.P. Docs

Second Option (Extensible setup):

  1. Open or create your DreamBot script project in Intellij
  2. Clone McLib to your project directory
  3. Open Project Settings > Modules, and import McLib directory as a module.

image1

  1. Click your script's name in the module list, then go to Dependencies > Green Cross > Module Dependency

image2

Select McLib, then click okay twice to save and exit your project settings.

image3

You should now be able to use McLib with import com.bmc.mclib and use it in conjunction with your current scripting workflow, and build jars normally.

Build Preparation for the SDN

Using module dependencies is clean, but comes with an extra step when it comes time to build for your SDN upload. Luckily, it's short and easy.

W.I.P. Docs

Clone this wiki locally