Page 1 of 1

Нужна небольшая помощь.

Posted: 2007-04-19 17:06:59
by <FaTe>
АА помогите сделать в скрипте следушую фичу:
Vortex:
end if
wait(300)
uo.cast('Energy Vortex','self')
repeat
wait(4000)
until uo.injournal("fizzles") or uo.injournal("Vortex")
if uo.injournal("fizzles") then
goto Vortex
else
end if
Пишит: GoTo Неккорректное определение цикла в скрипте?!! при физле.
Зы: Сори что отрезок без кода, просто нужно было выделить цветом.

Posted: 2007-04-19 17:10:56
by Rivory
Выложи полный код скрипта, я уверен там можно сделать без гото

Posted: 2007-04-19 18:53:04
by Sanch

Code: Select all

repeat
  uo.delejournal('fizzles')
  wait(300)
  uo.cast('Energy Vortex', 'self')
  repeat
     wait(4000)
  until uo.injournal("fizzles") or uo.injournal("Vortex")
until not uo.injournal('fizzles')

Posted: 2007-04-19 20:55:00
by <FaTe>

Code: Select all

sub KillElem() 
   UO.FindType('0x0F0E','0x0631','backpack')
    if UO.GetQuantity('finditem')>0 then
       UO.UseType('0x0F0E','0x0631')
       Vortex:
       end if
   wait(300)
   uo.cast('Energy Vortex','self')
   repeat
      wait(4000)
   until uo.injournal("fizzles") or uo.injournal("Vortex")
   if uo.injournal("fizzles") then
     goto Vortex
     else 
        end if
      wait(12000)
        uo.deletejournal()
      vasanort:
      UO.FindType('0x0F0E','0x09DF','backpack')
     if UO.GetQuantity('finditem')>0 then
         UO.UseType('0x0F0E','0x09DF')
         end if
      wait(300)
      uo.cast('Mass Dispel','self')
      wait(6000)
      if uo.injournal("fizzles") then
         goto vasanort
      endif
       uo.deletejournal()
      UO.SetReceivingContainer('backpack')
      UO.FindType('0x19B9',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
      endif
      UO.FindType('0x19B7',-1,'ground')
          if UO.GetQuantity('finditem')>0 then
          UO.Grab('0','finditem')
          wait(2000)
      endif
      UO.FindType('0x19BA',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
      endif
      UO.FindType('0x19B8',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
       endif
         UO.FindType('0x0EED',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
       UO.UnSetReceivingContainer()
       end if
       wait(1000)
        if UO.Dead() Then
       UO.Exec('terminate mine')
       end if
end sub

Posted: 2007-04-19 22:05:19
by <FaTe>
Все сенк, вот готовое:

Code: Select all

sub KillElem() 
   UO.FindType('0x0F0E','0x0631','backpack')
    if UO.GetQuantity('finditem')>0 then
       UO.UseType('0x0F0E','0x0631')
       end if
   wait(300)
   uo.cast('Energy Vortex','self')
   repeat
      wait(4000)
   until uo.injournal("fizzles") or uo.injournal("Vortex")
   if uo.injournal("fizzles") then
   repeat
  uo.deletejournal('fizzles')
  wait(300)
  uo.cast('Energy Vortex', 'self')
  repeat
     wait(4000)
  until uo.injournal("fizzles") or uo.injournal("Vortex")
until not uo.injournal('fizzles')
     else 
        end if
      wait(12000)
        uo.deletejournal()
      UO.FindType('0x0F0E','0x09DF','backpack')
     if UO.GetQuantity('finditem')>0 then
         UO.UseType('0x0F0E','0x09DF')
         end if
      wait(300)
      uo.cast('Mass Dispel','self')
      wait(6000)
      if uo.injournal("fizzles") then
   repeat
  uo.deletejournal('fizzles')
  wait(300)
  uo.cast('Mass Dispel', 'self')
  repeat
     wait(4000)
  until uo.injournal("fizzles") or not uo.injournal('fizzles')
   else
      end if
       uo.deletejournal()
      UO.SetReceivingContainer('backpack')
      UO.FindType('0x19B9',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
      endif
      UO.FindType('0x19B7',-1,'ground')
          if UO.GetQuantity('finditem')>0 then
          UO.Grab('0','finditem')
          wait(2000)
      endif
      UO.FindType('0x19BA',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
      endif
      UO.FindType('0x19B8',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
       endif
         UO.FindType('0x0EED',-1,'ground')
      if UO.GetQuantity('finditem')>0 then
         UO.Grab('0','finditem')
         wait(2000)
       UO.UnSetReceivingContainer()
       end if
       wait(1000)
        if UO.Dead() Then
       UO.Exec('terminate mine')
       end if
end sub

Кому надо - юзайте. -)