Calculus 30 Share Posted May 7, 2016 Is there a way to add a component listener to the dreambot client? I've been searching for a way, but can't find one. I tried this: getClient().getInstance().getApplet().addComponentListener(new ComponentAdapter() { @Override public void componentMoved(ComponentEvent e) { MethodProvider.log("HI"); } }); Sadly, that's the applet (just the runescape screen inside of dreambot's JFrame). Is there a way to access component listeners for the dreambot JFrame itself? Thanks. Link to comment Share on other sites More sharing options...
Dogerina 330 Share Posted May 7, 2016 frame.getframes Link to comment Share on other sites More sharing options...
Calculus 30 Author Share Posted May 17, 2016 frame.getframes ......what Link to comment Share on other sites More sharing options...
Dogerina 330 Share Posted May 18, 2016 ......what use 2 get dreambot frame add component listener Link to comment Share on other sites More sharing options...
Calculus 30 Author Share Posted May 18, 2016 use 2 get dreambot frame add component listener M8 idk where you're finding this getFrames() method... Link to comment Share on other sites More sharing options...
Dogerina 330 Share Posted May 18, 2016 M8 idk where you're finding this getFrames() method... http://bfy.tw/5pS5 Link to comment Share on other sites More sharing options...
Calculus 30 Author Share Posted May 18, 2016 http://bfy.tw/5pS5 Smartass that's obvious. There is no method to GET the frame in dreambot. +1 way to go Link to comment Share on other sites More sharing options...
Dogerina 330 Share Posted May 18, 2016 Smartass that's obvious. There is no method to GET the frame in dreambot. +1 way to go ???? i literally just gave u a method to get it Link to comment Share on other sites More sharing options...
Calculus 30 Author Share Posted May 19, 2016 ???? i literally just gave u a method to get it No, you really didn't. There is no way to access dreambot's frames. Link to comment Share on other sites More sharing options...
Dogerina 330 Share Posted May 19, 2016 No, you really didn't. There is no way to access dreambot's frames. fuck off troll import org.dreambot.api.methods.*; import org.dreambot.api.script.*; import java.awt.*; import java.awt.event.*; @ScriptManifest(name = "i can get the dreambot frame haha", description = "xd", author = "cockulus", version = 69, category = Category.AGILITY) public final class TheresLiterallyNoWayToGetTheDreambotFrame extends AbstractScript { @Override public void onStart() { Frame calculusSaidThatItsLiterallyImpossibleToAccessTheDreambotFrame = getDreambotFrame(); if (calculusSaidThatItsLiterallyImpossibleToAccessTheDreambotFrame == null) { throw new RuntimeException("uh oh"); } calculusSaidThatItsLiterallyImpossibleToAccessTheDreambotFrame.addComponentListener(new ComponentAdapter() { @Override public void componentMoved(ComponentEvent e) { MethodProvider.log("LOOOOL IM SOKE BAKED MANG"); } }); } @Override public int onLoop() { return 69_420; } private static Frame getDreambotFrame() { for (Frame frame : Frame.getFrames()) { if (frame.getTitle().toLowerCase().contains("dreambot")) { return frame; } } return null; } } Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.