ScriptUO

Official ScriptUO EasyUO Scripts => Script Debug => Topic started by: declo on May 27, 2016, 11:26:49 AM

Title: Playing with event property but not sending.....
Post by: declo on May 27, 2016, 11:26:49 AM
My attempt at a script to find all Minax arties items in backpack and sent them to the bank...

Code: [Select]
start:
finditem * c_ , #backpackid
if #FINDKIND <> -1
  {
   event Property #findID
   if minax in #property
   {
    set %minaxitem #findid
    gosub dropGoods
    }
  ignoreitem #findid
  }
goto start



 ;=====================================
;          Drop Goods
;=====================================
sub dropGoods
   finditem CKF  c_ , #backpackid
   topBag:
     event property #findid
     if #spc , 0 IN #property
       {
        SET #ltargetid #findid
        SET #ltargetkind 1
        finditem EUO c_ , #backpackid
        if #findid = X
           halt
        SET #lobjectid #findid
        event macro 17 0
        target 3s
        event macro 22 0
        wait 1s
        goto topBag
       }
   SET %bag #findid
   finditem %minaxitem , #backpackid
   SET #ltargetid #findid
   SET #lobjectid %bag
   SET %sendThis #findid
   SET #ltargetkind 1
   event macro 17 0
   target 3s
   event macro 22 0
   wait 1s
return


Any help on what I am missing?
Title: Re: Playing with event property but not sending.....
Post by: The Ghost on May 27, 2016, 11:51:28 AM
Did Ketchup ask the same question 10 month ago?     I'm sure we have a few answer on this question. Lydann also help.



Any how  give this a try
Code: [Select]
finditem * c_ , #backpackid
For #Findindex 1 #Findcnt
  {
  ;  wait 20 ;   <--- this is so #property updates, may need to raise it, I wouldn't go lower than 10
   event Property #findID
   if minax in #property
   {
    set %minaxitem #findid
    gosub dropGoods
    }
  ignoreitem #findid
  }
goto start
Title: Re: Playing with event property but not sending.....
Post by: manwinc on May 29, 2016, 02:19:31 PM
I would just go by #Findcol instead of the property. Much quicker.
Title: Re: Playing with event property but not sending.....
Post by: declo on May 30, 2016, 07:33:08 AM
Thank you!!!!

The timing tweak worked but for some reason it is not sending via the bag of sending.

The findcol is an option that I am starting to explore and learn about.

If I find an item with a specific color, is there a way to the value of the items #lobjecttype into a value like %iditem?
Title: Re: Playing with event property but not sending.....
Post by: The Ghost on May 30, 2016, 01:59:17 PM
In your dropgood

 finditem %minaxitem , #backpackid  need to be  finditem %minaxitem C_  ,#backpackid



PS
Look at TM Sub BOS if this not working.