Jump to content

imancity

Trade With Caution
  • Posts

    323
  • Joined

  • Last visited

  • Feedback

    100%

Posts posted by imancity

  1. Intro for Youtube

    Outro for Youtube

    Skype: Jonny.Yagami

     

    Ohh videos. I can do generic intros but nothing flashy and 3D with like AE or Blender and stuff. Sorry! Thought you meant like moving pictures/gifs/etc.

  2. afK8jEP.png

    (Since I have just opened, prices are very cheap and negotiable, and customer satisfaction is guaranteed or money back!)

     

     

     

     

     

     

     

     

    EXAMPLES

     

    Logo done for Omnificent:

    vK0BSmh.png

     

    My own paint:

    HblLzCs.png

     

     

    A paint for lg_juggles:

    d7OshIh.png

     

     

    A thread layout for lg_juggles:
    bWjN4Nr.png

     

     

     

    • Like 1
  3. 		if (getInventory().contains("ITEM1") && getInventory().contains("ITEM")) {
    			if (!getWidgets().isVisible(309, 4)) {
    				if (getInventory().interact("Use", "ITEM1")) {
    					if (getInventory().interact("Use", "ITEM2")) {
    						new org.osbot.rs07.utility.ConditionalSleep(5000) {
    							@Override
    							public boolean condition() throws InterruptedException {
    								return getWidgets().isVisible(309, 4);
    							}
    						}.sleep();
    					}
    				}
    			} else {
    				if (getWidgets().interact(309, 4, "Make All")) {
    					new ConditionalSleep(100_000) {
    						@Override
    						public boolean condition() throws InterruptedException {
    							return !getInventory().contains("ITEM1") || getDialogues().isPendingContinuation();
    						}
    					}.sleep();
    				}
    			}
    		}
    

     

    Perfect!!! :D Thanks a ton man. (I'm sure you know what those 'items' are supposed to be too :P)

  4. So I have a personal script where I use one item on another and then interact with the widget to "Make All". So far, the script works, but my only problem is that the player will "Use" multiple times before actually interacting with the widget, and then after using the widget "Make All" he'll also select the item in the inventory again randomly until it's time to bank.

     

    This doesn't affect the script itself but I feel like its very clearly bot behavior and would like to fix it.

     

    Here's my code for that part (I've changed variable names to anonymize it).

     

    Thanks in advance for any help!

    case MAKE:
                    sleep(500);
    
                    if ((getInventory().contains("ITEM1")) && (getInventory().contains("ITEM2")) && !myPlayer().isAnimating()) {
                        inventory.interact("Use", "ITEM1");
                        inventory.interact("Use", "ITEM2");
                        sleep(500);
    
                        if (getWidgets().isVisible(309, 4)) {
                            getWidgets().interact(309, 4, "Make All");
                            new ConditionalSleep(5000) {
                                @Override
                                public boolean condition() throws InterruptedException {
                                    return myPlayer().isAnimating();
                                }
                            }.sleep();
                        }
                    }
                    break;
    
  5. I do zombies in stronghold lvl 2, its like 20k+ an hour, was years ago but.

     

    Hmm not bad. Was looking for a place that's bottable tho :P and idk if any AIO fighters are solid at the zombies.

  6. Shouldn't be necessary, my script buys and opens feather packs using three states BUY,OPEN,WAIT.

     

    Yeah I figured it doesn't need to be so complicated. Before I left I switched it back to just 3 simple Buy, Walk to Shop, and Bank. I'm gonna have to look at it and see what I can do when I get home. Currently clueless as to what to fix.

  7. Want to post what you fixed so far? Also I am guessing you arn't actually putting "Item1" and instead the items id correct?

     

    Yes of course haha, just changed the items/npc to obscure it for now. I'm not home so can't post it, but the only thing I tried was creating separate cases for Buy and Talk(trade) so for one he'll trade with the npc, and then buy. It's just not going smoothly though. I must be messing something up when trying to buy multiple of different items.

  8. I think he is talking about your onLoop() because unless I am blind your getState() wasn't even provided.

     

    Here is an example of what I used in one of my scripts:

    NPC gerrant = getNpcs().closest("Gerrant");
        		if(gerrant == null){
        			log("[Error] Gerrant not found!");
        			return 1000;
        		}
        		if(gerrant.interact("Trade")){
        			new ConditionalSleep(6000){
        				@Override
        				public boolean condition() throws InterruptedException {
        					return getWidgets().isVisible(300);
        				}
        			}.sleep();
        		}
    

    I was using Widgets and not the store class.

     

    Ohh well if that's the case, I just didn't copy down the getState() part onto here lol, I definitely have it in the script though. Hmm I'm gonna try to stick to using the store class. I was able to open the store, just not efficiently buy items :P

  9.  

    1. Don't use "wait()" when you want the script to sleep. Use ConditionalSleep for dynamic sleeping

      open store
      new ConditionalSleep(5000
         public boolean condition() {
             return store is open;
         }
      }.sleep();
      
      //it will sleep maximum 5000 ms or until the store is open
    2. Your getState() or w/e it's called is flawed

     

     

    Why do you say my getState() is flawed? I'm not sure what you mean by this.

     

  10. You're welcome smile.png If you run into any issues let me know biggrin.png

     

    Hey, Solution. Could you help me with this?

     

    So in this case, I have it trade the NPC nearby and buy all of the supply of 4 different items. I want it to buy them all, and once out, to hop worlds and continue. I can't seem to make it work because the way I currently have it, it opens the Store but doesn't buy. If I put the buying code outside the trade if then it does it but once its out, it doesn't hop but rather keeps spam trading the NPC.

     

    Sorry if that's a bit unclear, I can explain more if need be.

    case BUY:
    
                    if ((getNpcs().closest("NPC") !=null) && (!getStore().isOpen())) {
                        getNpcs().closest("NPC").interact("Trade");
                        wait(100,200);
    
                        if ((getStore().isOpen()) /*&& (getStore().contains("Item1" , "Item2" , "Item3" , "Item4"))*/) {
                            if (getStore().getAmount("Item1") > 0) {
                                getStore().buy("Item1", 10);
                                wait(100, 200);
                            } else if (getStore().getAmount("Item2") > 0) {
                                getStore().buy("Item2", 10);
                                wait(100, 200);
                            } else if (getStore().getAmount("Item3") > 0) {
                                getStore().buy("Item3", 10);
                                wait(100, 200);
                            } else if (getStore().getAmount("Item4") > 0) {
                                getStore().buy("Item4" , 10);
                                wait(100,200);
                            }
                            else {
                                getStore().close();
                                wait(100,200);
                                worlds.hopToP2PWorld();
                            }
                        }
                    }
               
                    break;
    
×
×
  • Create New...