Page 1 of 1

autoloot

Posted: 2008-04-26 21:26:05
by lizardking

Code: Select all

sub Autoheal()
   While UO.Life > 0
      If UO.Life < UO.str Then
         UO.BandageSelf()
         wait (4200)
      else
         wait (50)
      Endif
   wend
endsub

sub LootLastCorpse()
   VAR Gold  = '0x0EED'   ; gold
    UO.UseObject( 'lastcorpse' )
    wait(300)
                UO.FindType( Gold, '-1', 'lastcorpse' )
            While UO.FindCount() > 0
                 UO.MoveItem( 'finditem','0' )
                 wait(1000)
            Wend
       UO.Print( 'The loot was finished' )
endsub
             


nazhimaju exec lootlastcorpse. vrode rabotaet, no deneg tipo kakto prigaet po beckpeck i action nekonachatesja, ona ostaetsja v List of running funct. help.

Code: Select all

sub Autohealing() 
   While UO.Life > 0
      If UO.Life < UO.Str Then
         UO.Bandageself()
         wait(20)
          repeat
           UO.DeleteJournal()
             repeat
              wait(100)
             until UO.InJournal("You put") or UO.InJournal("fail")
       Else
         wait(50)
          until UO.Dead()
      Endif       
   Wend
endsub


i chto tut netak ? problema takaja chto on hilitsja normaljno, no kogda zahilitsja do full hp, i potom ktoto atakavaet eshjo raz, togda bolshje nehilitsja. pomagite.

Posted: 2008-04-30 06:01:36
by Infectous

Code: Select all

sub Autohealing()
   While NOT uo.dead() ; uo.life > 0 is the same as not uo.dead()
      If UO.Life < UO.Str Then
         UO.Bandageself()
         wait(20) ; ???
UO.DeleteJournal() ; no need repeat to give Injection time to read below wait(100) goes too fast & will miss if constantly deleting the periodical
;          repeat ; no need to repeat here
       
             repeat
              wait(100)
             until UO.InJournal("You put") or UO.InJournal("fail")
       Else
         wait(50)
;          until UO.Dead() ; move to the while function above
      Endif       
   Wend
endsub

Posted: 2008-04-30 06:16:53
by Infectous

Code: Select all

sub LootLastCorpse()
   VAR Gold  = '0x0EED'   ; gold
    UO.UseObject( 'lastcorpse' )
    wait(300)
                UO.FindType( Gold, '-1', 'lastcorpse' )
            While UO.FindCount() > 0
                 UO.Grab(0, "finditem") ; UO.MoveItem( 'finditem','0' )**
                 wait(1000)
                UO.FindType( Gold, '-1', 'lastcorpse' )
            Wend
       UO.Print( 'The loot was finished' )
endsub


,moveitem what, howmany, to where
ex: UO.MoveItem( 'finditem','0',"backpack" )

Posted: 2009-03-08 11:49:15
by Macks
Infectous wrote:,moveitem what, howmany, to where
ex: UO.MoveItem( 'finditem','0',"backpack" )


uo.moveitem("lastcorpse.POF")