Суббота, 18.05.2024, 16:39
[nIrVaNa]
Приветствую Вас Призывник | RSS

Меню сайта
Ultima Online
  • Ultima Online DRW
  • .::Games::.
  • EVE Online
  • Russia EVE-RU
  • Ukrainian EVE-UA
  • [6OP3bIE CAHTEXHuru] EVE
  • L2Europa.com
  • Clan Viktoria L2Europa.com
  • Мини-чат
    Главная » Статьи » Мои статьи

    Скрипт на Спаринг
    ####################################################
    ### 14.06.2009 ###
    ### Спаринг 1.01. Бьет и лечит ###
    ####################################################
    ### @author divbyzero ###
    ####################################################
    sub Training()
      var bandage='0x0E21' # Тип бинтов
      var washing='0x403511D5' # Тип корыта
      var bloody='0x0E20' # Тип кровавых бинтов
      ########################
      # Настройте переменные #
      ########################
      var bX = 781 # Координата Х в бою
      var bY = 1989 # Координата Y в бою
      var hX = 781 # Координата Х для лечения (отойти на одну клетку от чара)
      var hY = 1989 # Координата Y для лечения
      ###################
      uo.AddObject('opponent')
      while uo.Targeting()
      wait(100)
      wend
      while not uo.Dead()
      if uo.GetHp('opponent') <> uo.GetMaxHp('opponent') then
      uo.WarMode(false)
      uo.print(uo.GetHp('opponent'))
      Walk(hX,hY) ; место для отхода
      while uo.GetHp('opponent') <> uo.GetMaxHp('opponent')
      uo.WaitTargetObject('opponent')
      uo.UseType(bandage)
      wait(3500)
      uo.GetHp('opponent')
      wend
      Shield()
      end if
      if uo.GetHp('self') <= uo.GetMaxHp('self') then
      uo.WarMode(false)
      Walk(hX,hY) ; место для отхода
      while uo.GetHp('self') <> uo.GetMaxHp('self')
      uo.WaitTargetObject('self')
      uo.UseType(bandage)
      wait(3500)
      wend
      uo.WaitTargetObject(washing)
      uo.UseType(bloody)
      wait(750)
      Shield()
      end if
      uo.WarMode(true)
      uo.Attack('opponent')
      wait(500)
      Walk(bX,bY) ; место в бою
      while (uo.GetHp('opponent') > uo.GetMaxHp('opponent')/3) && (uo.Life > 70)
      wait(500)
      wend
      wend
    end sub

    sub Shield()
      var shield='0x1B76'
      var cleaver='0x13B2' ; 0x0F51 - clever
      var item
      uo.FindType(cleaver,'-1','-1')
      if uo.FindCount() > 0 then
      uo.UseObject('finditem')
      while uo.Targeting()
      wait(100)
      wend
      uo.canceltarget()
      end if
      wait(500)
      uo.FindType(shield,'-1','backpack')
      if uo.FindCount() then
      uo.UseObject('finditem')
      end if
      wait(500)
    end sub

    sub Walk(x,y)
      go:
      while not uo.getX() == x || not uo.getY() == y
      if not uo.getX() == x then
      if uo.getX() > x then
      uo.press(36)
      else
      uo.press(34)
      endif
      endif
      if not uo.getY() == y && uo.getX() == x then
      if uo.getY() > y then
      uo.press(33)
      else
      uo.press(35)
      endif
      endif
      checklag()
      wend
      checklag()
      if not uo.getX() == x || not uo.getY() == y then
      goto go
      endif
    endsub

    sub DelJ(s)
      VAR MN=UO.InJournal(s)
      while MN > 0
      UO.SetJournalLine(MN-1, '')
      MN=UO.InJournal(s)
      wend
    end sub

    sub CheckLag()
      DelJ("backpack")
      UO.Click('backpack')
      repeat
      wait(500)
      until UO.InJournal('backpack')
    end sub

    sub skillup()
      var t
      var skill = 'Archery'
      t = uo.SkillVal(skill,1)
      uo.TextOpen()
      uo.textprint('Start: ' + Time())
      uo.textprint(skill + ': ' + str(t/10) + '%' )
      while not uo.dead()
      if uo.SkillVal(skill,1) <> t then
      t = uo.SkillVal(skill,1)
      uo.textprint(str(t/10)+ '% -> ' + Time())
      uo.TextOpen()
      end if
      wait(1000)
      wend
    end sub

    sub Time()
      var Date,nTime,uTime,i
      uTime=str(uo.Time())
      nTime=''
      for i=0 to Len(uTime)
      nTime=uTime[Len(uTime)-i]+nTime
      if (i==2) or (i==4) then
      nTime=':'+nTime
      end if
      next
      uTime=str(uo.Date())
      Date=''
      for i=0 to Len(uTime)
      Date=uTime[Len(uTime)-i]+Date
      if (i==2) or (i==4) then
      Date='.'+Date
      end if
      next
      uTime=nTime+' @ '+Date
      return uTime
    end sub

    sub grabbolt()
      while not uo.Dead()
      uo.findtype('0x0F3F', '-1', 'ground')
      if uo.findcount() > 0 then
      uo.grab(0,'finditem')
      wait(1500)
      end if
      wait(10000)
      CheckLag()
      wend
    end sub

    Категория: Мои статьи | Добавил: -=DavidJones=- (03.11.2009)
    Просмотров: 1610 | Комментарии: 1 | Рейтинг: 0.0/0
    Всего комментариев: 0
    Добавлять комментарии могут только зарегистрированные пользователи.
    [ Регистрация | Вход ]

    Статистика

    Онлайн всего: 1
    Гостей: 1
    Пользователей: 0
    Наш опрос
    Как Вам наш сайт
    Всего ответов: 244
    Copyright MyCorp © 2024