Jump to content

zulul123

Members
  • Posts

    2
  • Joined

  • Last visited

  • Feedback

    0%

Profile Information

  • Gender
    Male

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

zulul123's Achievements

Newbie

Newbie (1/10)

1

Reputation

  1. Hi. Trying to split up my script into multiple classes but getting null pointer error when trying to access methods from a different class like in this example: public class Main extends Script { Test test = new Test(); @Override public void onStart() throws InterruptedException { test.exchangeContext(getBot()); } @Override public int onLoop() throws InterruptedException { test.testLog(); return 256; } @Override public void onExit() throws InterruptedException {} } public class Test extends MethodProvider { TestTwo testTwo = new TestTwo(); public void testLog() { testTwo.logFromTestTwo(); } } public class TestTwo extends MethodProvider { public void logFromTestTwo() { log("Test Two"); } }
×
×
  • Create New...