Qubit Posted June 8, 2015 Share Posted June 8, 2015 I completely forgot how to listen for a message ingame.... can someone show me a snippet of code for it. I thought u have to make a message method and implement message http://gyazo.com/6bc26d78de43ea549ad9f073b5875200 but i clearly am wrong. helps plz Quote Link to comment Share on other sites More sharing options...
Flamezzz Posted June 8, 2015 Share Posted June 8, 2015 (edited) implement MessageListener and define the listener method class ... extends Script implements Painter, MessageListener public void onMessage(Message m) { if(m.getType().equals(Message.MessageType.GAME)) { // game message } if(m.getType().equals(Message.MessageType.PLAYER)) { // player message } } Edited June 8, 2015 by Flamezzz Quote Link to comment Share on other sites More sharing options...
Qubit Posted June 8, 2015 Author Share Posted June 8, 2015 implement MessageListener and define the listener method class ... extends Script implements Painter, MessageListener public void onMessage(Message m) { } gracias Quote Link to comment Share on other sites More sharing options...
Eagle Scripts Posted June 8, 2015 Share Posted June 8, 2015 Wrote stuff down in pastebin, implement all that's in here and it should work --> http://pastebin.com/2eMkwpX6 Quote Link to comment Share on other sites More sharing options...