Buying script for the Union client

Forum for discussing in game trades, offers and deals.

Buying script for the Union client

Postby overtyped » Sun Sep 01, 2013 11:16 am

Paying 1 LC of jorbonzola valued around 800 points or 16 pearls

for a script that will do the following in the union client
-transfer curd from the inventory into cheese trays

1st person to post the script *functioning* in this thread, wins.
Last edited by overtyped on Sun Sep 01, 2013 11:26 am, edited 1 time in total.
Early world exploit: Put your hearthfire inside a cave, then hold shift to position a claim right in front of a cave. After 8 hours the claim will be unbreakable. Since your hearthfire is inside the cave, you can still get back inside, and leave, but nobody will be able to enter, effectively making you unraidable for the first 3-7 days. Enjoy
User avatar
overtyped
 
Posts: 3906
Joined: Tue Sep 28, 2010 2:09 am
Location: Quaran book burning festival

Re: Buying script for the Union client

Postby Arcanist » Sun Sep 01, 2013 11:23 am

Where are the cheese trays?
User avatar
Arcanist
 
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Buying script for the Union client

Postby overtyped » Sun Sep 01, 2013 11:24 am

Arcanist wrote:Where are the cheese trays?

in a cupboard, but the script doesn't need to open the cupboard, it just needs to transfer the curd into the trays in the cupboard that I have opened.
Early world exploit: Put your hearthfire inside a cave, then hold shift to position a claim right in front of a cave. After 8 hours the claim will be unbreakable. Since your hearthfire is inside the cave, you can still get back inside, and leave, but nobody will be able to enter, effectively making you unraidable for the first 3-7 days. Enjoy
User avatar
overtyped
 
Posts: 3906
Joined: Tue Sep 28, 2010 2:09 am
Location: Quaran book burning festival

Re: Buying script for the Union client

Postby dfgcvb2 » Sun Sep 01, 2013 12:17 pm

what about pming than posting
Last edited by dfgcvb2 on Sun Sep 01, 2013 2:36 pm, edited 1 time in total.
dfgcvb2
 
Posts: 22
Joined: Wed Jul 10, 2013 5:34 am

Re: Buying script for the Union client

Postby Foetuses » Sun Sep 01, 2013 12:48 pm

This was meant to be a PM. :roll:
Foetuses
 
Posts: 79
Joined: Tue Mar 27, 2012 11:55 pm

Re: Buying script for the Union client

Postby ChildhoodObesity » Sun Sep 01, 2013 1:39 pm

y SO LAZY IT TAEKS LIEK 3 SECONDS
User avatar
ChildhoodObesity
 
Posts: 4165
Joined: Tue Apr 10, 2012 8:16 am

Re: Buying script for the Union client

Postby Arcanist » Sun Sep 01, 2013 2:41 pm

I almost have it working. But I've run out of curd to test it on...
User avatar
Arcanist
 
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Buying script for the Union client

Postby Arcanist » Sun Sep 01, 2013 2:58 pm

Code: Select all
//#! name = curd mover
//#! uniq = Curd_Mover_Arcanist
//#! tooltip = moves curd
//#! icon = gfx/invobjs/cheese-curd

var inventory = checkInventory();
var inv = jGetWindows("Inventory");
var cupboard = checkCupboard();

function checkCupboard() {
   if(!jHaveWindow("Cupboard")) {
      return;
   }
   return jGetWindow("Cupboard").getInventories()[0];
}

function checkInventory() {
   if(!jHaveWindow("Inventory")) {
      jToggleInventory();
      while(!jHaveWindow("Inventory"))
         jSleep(100);
   }
   return jGetWindow("Inventory").getInventories()[0];
}

/*function main() {
     //var tray = jGetWindow("Cupboard").getInventories()[0].getItems("cheese-tray")[0];
      var curd = jGetWindow("Inventory").getInventories()[0].getItems("cheese-curd")[0];    //getting 1st curd at inventory
     var trays = cupboard.getItems("cheese-tray");
         curd.take();
         jWaitDrag();
         if (trays.length > 0) {
            var trays = trays[0];
            if (trays.isActual()) {
               trays.itemact(0);
               jSleep(200);
            loop();
            }
         }
     jSleep(200);
     loop(); }
     */
    
    
/*function main() {
   inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = inventory.getItems("cheese-curd");
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      if (bucket.isActual()) {
         bucket.take();
         jWaitDrag();
         var flasks = cupboard.getItems("cheese-tray");
         if (flasks.length > 0) {
            var flask = flasks[0];
               flask.itemact(0);
               jSleep(500);
            transfertray();
            }
         }
      }
   
   loop();
 }
 */
 
 function main() {
    inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = inventory.getItems("cheese-curd");
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      if (bucket.isActual()) {
         var flasks = cupboard.getItems("cheese-tray");
         if (flasks.length > 0) {
            var flask = flasks[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            transfertray();
            loop();
            }
         }
      }
   
   loop();
 }
 
 function transfertray() {
   inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = cupboard.getItems("cheese-tray-curd");
   var freeSlot = inventory.freeSlotsCoords()[0];
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      while (bucket.isActual()) {
         bucket.take();
         jWaitDrag();
       inventory.drop(freeSlot)
       jSleep(500)
       }
       }
       return;
       }
   


 

 
function loop() {main();}
loop()


Code: Select all
var inventory = checkInventory();
var inv = jGetWindows("Inventory");
var cupboard = checkCupboard();

function checkCupboard() {
   if(!jHaveWindow("Cupboard")) {
      return;
   }
   return jGetWindow("Cupboard").getInventories()[0];
}

function checkInventory() {
   if(!jHaveWindow("Inventory")) {
      jToggleInventory();
      while(!jHaveWindow("Inventory"))
         jSleep(100);
   }
   return jGetWindow("Inventory").getInventories()[0];
}

function transfertrayback() {

   inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = inventory.getItems("cheese-tray-curd");
   var freeSlot = cupboard.freeSlotsCoords()[0];
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      while (bucket.isActual()) {
         bucket.take();
         jWaitDrag();
       cupboard.drop(freeSlot)
       jSleep(500)
       }
       }
       loop();
       }
      
function loop() {transfertrayback();}

transfertrayback()   


Worked for the 7 curd I managed to find to test it on. It doesn't seem possible for the bot engine to differentiate between "cheese-tray" and "cheese-tray-curd", so the only way of doing this is to take "cheese-tray-curd" out of the cupboard after it is full.

The second script puts them all back in.
User avatar
Arcanist
 
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Buying script for the Union client

Postby Arcanist » Sun Sep 01, 2013 3:07 pm

Code: Select all
//#! name = curd mover
//#! uniq = Curd_Mover_Arcanist
//#! tooltip = moves curd
//#! icon = gfx/invobjs/cheese-curd

var inventory = checkInventory();
var inv = jGetWindows("Inventory");
var cupboard = checkCupboard();

function checkCupboard() {
   if(!jHaveWindow("Cupboard")) {
      return;
   }
   return jGetWindow("Cupboard").getInventories()[0];
}

function checkInventory() {
   if(!jHaveWindow("Inventory")) {
      jToggleInventory();
      while(!jHaveWindow("Inventory"))
         jSleep(100);
   }
   return jGetWindow("Inventory").getInventories()[0];
}

/*function main() {
     //var tray = jGetWindow("Cupboard").getInventories()[0].getItems("cheese-tray")[0];
      var curd = jGetWindow("Inventory").getInventories()[0].getItems("cheese-curd")[0];    //getting 1st curd at inventory
     var trays = cupboard.getItems("cheese-tray");
         curd.take();
         jWaitDrag();
         if (trays.length > 0) {
            var trays = trays[0];
            if (trays.isActual()) {
               trays.itemact(0);
               jSleep(200);
            loop();
            }
         }
     jSleep(200);
     loop(); }
     */
    
    
/*function main() {
   inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = inventory.getItems("cheese-curd");
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      if (bucket.isActual()) {
         bucket.take();
         jWaitDrag();
         var flasks = cupboard.getItems("cheese-tray");
         if (flasks.length > 0) {
            var flask = flasks[0];
               flask.itemact(0);
               jSleep(500);
            transfertray();
            }
         }
      }
   
   loop();
 }
 */
 
 function main() {
    inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = inventory.getItems("cheese-curd");
   var bucket_coord = bucket.coord();
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      if (bucket.isActual()) {
         var flasks = cupboard.getItems("cheese-tray");
         if (flasks.length > 0) {
            var flask = flasks[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag();
               flask.itemact(0);
               jSleep(500);
            var buckets = inventory.getItems("cheese-curd");
            var bucket = buckets[0];
            bucket.take();
            jWaitDrag;
            inventory.drop(bucket_coord)
            transfertray();
            loop();
            }
         }
      }
   
   loop();
 }
 
 function transfertray() {
   inventory = checkInventory();
   var cupboard = checkCupboard();
   var buckets = cupboard.getItems("cheese-tray-curd");
   var freeSlot = inventory.freeSlotsCoords()[0];
   if (buckets.length > 0) {
      inventory.sortItems(buckets, "amount", false);
      var bucket = buckets[0];
      while (bucket.isActual()) {
         bucket.take();
         jWaitDrag();
       inventory.drop(freeSlot)
       jSleep(500)
       }
       }
       return;
       }
   


 

 
function loop() {main();}
loop()


A minor edit to the main() incase one of the trays is already partly full, it takes another curd and drops it in inventory, before transfering full trays.

These scripts will work best if there is already a free slot (or two) in inventory, and you haven't put the curds in inventory in any weird order, eg vertically, the same with the trays. As if takes the last curd that went in first, and fills the last tray that went in first.
User avatar
Arcanist
 
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Buying script for the Union client

Postby aghmed » Sun Sep 01, 2013 4:04 pm

Arcanist wrote:
Worked for the 7 curd I managed to find to test it on. It doesn't seem possible for the bot engine to differentiate between "cheese-tray" and "cheese-tray-curd", so the only way of doing this is to take "cheese-tray-curd" out of the cupboard after it is full.

The second script puts them all back in.


you have to search for blob value or second res
don't remember wich one it was :P
public static class StupidJavaCodeContainer {
/* oh, i love swing. */
class checkOutMyPathfinder{
Image
}}
User avatar
aghmed
 
Posts: 238
Joined: Fri Sep 07, 2012 7:20 pm
Location: between London and third part of LSD

Next

Return to Apples For Oranges

Who is online

Users browsing this forum: Claude [Bot] and 0 guests