Welcome to TRiBot Forums

Register now to gain access to all of our features. Once registered and logged in, you will be able to contribute to this site by submitting your own content or replying to existing content. You'll be able to customize your profile, receive reputation points as a reward for submitting content, while also communicating with other members via your own private inbox, plus much more! This message will be removed once you have signed in.


  • Content count

  • Joined

  • Last visited

  • Feedback


Community Reputation

0 Neutral

About Endecs

  • Rank
    New Botter
  1. @TRiLeZ Hey, thanks for the answer, but MyPlayer is not RSPlayer MyPlayer: public class MyPlayer implements Serializable { public int Distance = 0; public int CombatLevel = 0; public int Gold = 0; public int World = 0; public int Energy = 0; public MyPlayer() { } } And the Class that I run in the Bot: public class Handler extends Script implements Sock_Client.MessageHandler { public void run() { MyPlayer myPlayer = new MyPlayer(); myPlayer.CombatLevel = 100; myPlayer.Distance = 100; myPlayer.Energy = 10; myPlayer.Gold = 1000; myPlayer.World = 50; File path = new File(Util.getWorkingDirectory().getAbsolutePath(), "test.xml"); String Path = path.getAbsolutePath(); General.println(Path); Easy.save(myPlayer, Path); MyPlayer mobj = MyPlayer.class.cast(Easy.load(Path)); } So and when I run this in Tribot then comes this: But when I run this out of Tribot: public class test { public static void main(String[] args) { MyPlayer myPlayer = new MyPlayer(); myPlayer.Energy = 10; Easy.save(myPlayer, "test"); MyPlayer mobj = MyPlayer.class.cast(Easy.load("test")); } } Then its work. greets, Endecs
  2. @TRiLeZ Maybe you can say something. greets Endecs
  3. Hello, I'm trying to serialise a Class (MyPlayer) and currently just to store it on HDD and to loading it again. Saving works, but not the last line, he can't cast it to MyPlayer. It's only happens in TriBot, when I debug the Code, it cast the Object without problems. File path = new File(Util.getWorkingDirectory().getAbsolutePath(), "test.xml");path.createNewFile();String Path = path.getAbsolutePath(); Easy.save(myPlayer, Path); MyPlayer pl = MyPlayer.class.cast(Easy.load(Path));//alsopl = (MyPlayer)Easy.load(Path);//isn't working, no cast operation is working Error: greets, Endecs
  4. It should and you can check also the status of it and so on, just read this: https://tribot.org/doc/org/tribot/api2007/types/RSGEOffer.html offer.getItemName() you have to check if its "null" by this function. greets, Endecs
  5. You can find it here: https://tribot.org/doc/ under "Grand Exchange". RSGEOffer[] Offers = GrandExchange.getOffers(); //And then you can use the RSGEOffer methods, like this: if (Offers.Length > 0){ for(RSGEOffer offer : Offers) { if (offer.getItemName().Equals("Iron ore")) { //Do your things with this offer, like this offer.click(); break; } }} I don't tested it, just wrote it here without IDE, so typo can be there. greets, Endecs
  6. Delete hooks.dat from you .tribot folder. For more information, read this: https://tribot.org/forums/topic/52934-tutorial-when-tribot-doesnt-work-correctly/ And this: https://tribot.org/forums/topic/15478-this-section-is-for-programming-related-questions-only/ greets, Endecs
  7. Goto %AppData%\.tribot\ and delete the folder dependancies, then start your client and it should work again. greets, Endecs
  8. Yes, it does need an update. When I start this in Motherlode-mine, I get Java exceptions, with something about Canvas, when I start a script, NPC...getall returns like it seems null and in the script is not a check. greets, Endecs
  9. Here is my greets, Endecs Xmouse_data-254047-1437832217817.dat