dokato Posted January 14, 2016 Share Posted January 14, 2016 (edited) Ok so i've made this class that interacts with my mysql db and it worx excellent in java. But when i try it out with the osbot script, the client gives me a nullpointerexception which shouldnt be there (cause it worked fine with another non bot script program) and it instanlty crashes. Now that's if i put it in the onLoop(), if I place it in the onStart() the script just stops, it says excited ... This is what I get: http://i.imgur.com/4szNNoY.png Am I doing something wrong? Plz help? Edited January 15, 2016 by dokato Quote Link to comment Share on other sites More sharing options...
The Hero of Time Posted January 14, 2016 Share Posted January 14, 2016 why do you want to establish a connection to your sql databse in a runescape script? 1 Quote Link to comment Share on other sites More sharing options...
dokato Posted January 14, 2016 Author Share Posted January 14, 2016 why do you want to establish a connection to your sql databse in a runescape script? So that another account could see when that acc is rdy to trade its farm. It will update some values in the db and based on that the other account can see which acc it should trade when. I dont see any other way of making that possible without using a remote database. Quote Link to comment Share on other sites More sharing options...
Chicken Wing Posted January 14, 2016 Share Posted January 14, 2016 Post code? What line is the npe Quote Link to comment Share on other sites More sharing options...
The Hero of Time Posted January 14, 2016 Share Posted January 14, 2016 So that another account could see when that acc is rdy to trade its farm. It will update some values in the db and based on that the other account can see which acc it should trade when. I dont see any other way of making that possible without using a remote database. write values to a .txt , booleans or whatever you like, and make the other script check the .txt also if you want to use a databse, don't you need something running 24/7? or pay for hosting? 1 Quote Link to comment Share on other sites More sharing options...
dokato Posted January 14, 2016 Author Share Posted January 14, 2016 write values to a .txt , booleans or whatever you like, and make the other script check the .txt also if you want to use a databse, don't you need something running 24/7? or pay for hosting? Ye i get your point, but what if you've got multiple remote servers where bots run on? And it's a free mysql hosting 24/7 thingy, so it's free, i dont need to pay anyhting, accept for the servers ofcourse. Quote Link to comment Share on other sites More sharing options...
The Hero of Time Posted January 14, 2016 Share Posted January 14, 2016 Ye i get your point, but what if you've got multiple remote servers where bots run on? And it's a free mysql hosting 24/7 thingy, so it's free, i dont need to pay anyhting, accept for the servers ofcourse. i dont know the scenario, but if you have multiple accounts, set the name of the .txt document to the bot's name, so they can use their individual file 1 Quote Link to comment Share on other sites More sharing options...
dokato Posted January 14, 2016 Author Share Posted January 14, 2016 Post code? What line is the npe I'll tell you tomorrow, im not on my pc atm Quote Link to comment Share on other sites More sharing options...
dokato Posted January 15, 2016 Author Share Posted January 15, 2016 (edited) Post code? What line is the npe This is what I get: http://i.imgur.com/4szNNoY.png Edited January 15, 2016 by dokato Quote Link to comment Share on other sites More sharing options...
Chicken Wing Posted January 15, 2016 Share Posted January 15, 2016 This is what I get: http://i.imgur.com/4szNNoY.png Quote Link to comment Share on other sites More sharing options...
dokato Posted January 15, 2016 Author Share Posted January 15, 2016 Quote Link to comment Share on other sites More sharing options...
dokato Posted January 16, 2016 Author Share Posted January 16, 2016 i dont know the scenario, but if you have multiple accounts, set the name of the .txt document to the bot's name, so they can use their individual file I think osbot doesnt support the mysql driver thing and that's why i get the erorr. I'll just let the program run seperately so that it can write the database values into a txt file and then the osbot script will read from that txt file. That should work i think Quote Link to comment Share on other sites More sharing options...