[Help] Reactor Issues...

Results 1 to 7 of 7
  1. #1
    Valued Member bleeditout364 is offline
    MemberRank
    Sep 2009 Join Date
    128Posts

    ! [Help] Reactor Issues...

    Hi Everybody, So I have been working on my server for a bit and I wanted to add a nostalgic old event from GMS. I have been looking around to see what is wrong but I just cant seem to find what the error is.

    Whats Happening is I want these boxes to drop Items. I dont think the Reactor Scripts are being read at all because when i tried to use the Eye of Fire a while back when I was seeing what worked in the source and what didn't it took the Eye of Fire but no Zakum Popped up.

    A point in the right direction or an explanation would be nice. This is a v83 source and it is a modified ToyStory source.. I have been working on it for 3 months now an answer to this would be nice!

    Thanks for your time!! :D

    EDIT: There is no .bat error also...
    Last edited by bleeditout364; 27-11-13 at 07:09 PM.


  2. #2
    Valued Member bleeditout364 is offline
    MemberRank
    Sep 2009 Join Date
    128Posts

    Re: [Help] Reactor Issues...

    Bump ---- Help please --- Payment may go to the one who fixes it...

  3. #3
    Omega sunnyboy is offline
    MemberRank
    Mar 2010 Join Date
    6,109Posts

    Re: [Help] Reactor Issues...

    Are well aware of reactors ever working before for you?

  4. #4
    Valued Member bleeditout364 is offline
    MemberRank
    Sep 2009 Join Date
    128Posts

    Re: [Help] Reactor Issues...

    Reactors have not worked before...

  5. #5
    Account Upgraded | Title Enabled! Syre is offline
    MemberRank
    Jan 2013 Join Date
    700Posts

    Re: [Help] Reactor Issues...

    do reactor drops work..? (e.g. the bolts and wood on maple island)

  6. #6
    Valued Member bleeditout364 is offline
    MemberRank
    Sep 2009 Join Date
    128Posts

    Re: [Help] Reactor Issues...

    No reactors work what so ever... There is nothing dropping and no errors in the bat

  7. #7
    Member Drum is offline
    MemberRank
    Jul 2013 Join Date
    80Posts

    Re: [Help] Reactor Issues...

    Common issue. Strange that no error was printed to your console though. As far as I know, most sources (v83 anyway) use the same classes for reactors, and the author caught and printed any exceptions to the console. I know that Moople has it fixed. It might help if you gave us a link to the source you're using so we can see the code!


    It's some silly error that's thrown because the script engine doesn't recognize the script if you have not implemented all of the methods defined in the ReactorScript.java interface (working off TiredStory here). I think it used to work when it was written, but with the new update in Java 7 or Rhino and it's now a requirement.


    The problem is when it calls this:
    Code:
    ReactorScript rs = iv.getInterface(ReactorScript.class);

    it returns null and assigns that to rs, and when rs.act() is called a NullPointerException is thrown. I don't think touch() or untouch() is actually used for much, so you don't need them.


    So you can either implement the methods (so they can be successfully be invoked) in all of your reactor scripts, and have them do nothing:
    Code:
    function act() {
        // act() is the main function for reactors
    }
    
    
    function touch() {
         // Leave blank
    }
    
    
    function untouch() {
         // Leave blank
    }

    The more elegant fix would be to comment out the touch() and untouch() definitions in the interface though.



Advertisement