Если много переделывать, может есть уже похожий скрипт на форуме, подскажите.
Code: Select all
#©]daRk[::c00pEr::
VAR eda = '0x097B' #Тип еды.
VAR Sunduk = '0x4006149F' #ID Сундука с регами.
VAR obj = '0x000140BC' #ID чара куклы.
VAR Kushaem = 1 #Если кушаем, то 1.
VAR cnt = 0
sub strelka()
VAR NS='0x0F88' ; Тип Nighshade.
VAR BP='0x0F7A' ; Тип Black Pearls.
VAR LastTimer
UO.Exec('terminate Reconnector')
wait(1000)
UO.Exec('exec Reconnector')
wait(1000)
UO.UseObject(Sunduk)
wait(1000)
If Kushaem == 1 then
Eda()
endif
while not uo.dead()
If Kushaem == 1 then
If cnt == 100 then
Eda()
cnt = 0
end if
endif
cnt = cnt + 1
If UO.NS < 10 Then
wait(1000)
UO.FindType(NS, '-1', Sunduk)
wait(100)
UO.MoveItem('finditem', '200', 'backpack')
wait(1000)
Endif
If UO.BP < 10 Then
wait(1000)
UO.FindType(BP, '-1', Sunduk)
wait(100)
UO.MoveItem('finditem', '200', 'backpack')
wait(1000)
Endif
if uo.mana > 15 then
cheklag()
UO.Cast('Magic Arrow', obj)
wait(2000)
else
UO.Say('no mana')
While UO.Mana < UO.Int
UO.DeleteJournal()
UO.WarMode(0)
wait(1000)
UO.Useskill('Meditation')
Repeat
wait(100)
until UO.InJournal("You are") OR UO.InJournal("You lose")
Wend
endif
wend
end sub
Sub cheklag()
uo.deletejournal()
uo.click('backpack')
repeat
wait(10)
until uo.InJournal("backpack")
end sub
Sub Eda()
if uo.count(eda,'0x0000') < 20 then ## Жрачка, кушаем до изнеможения
uo.findtype(eda, '0x0000', sunduk)
Cheklag()
uo.moveitem('finditem',STR(20-uo.count(eda,'0x0000')),'backpack')
wait(1000)
end if
uo.deletejournal()
repeat
uo.usetype(eda,'0x0000')
wait(1000)
until uo.injournal("You are stuffed!") or uo.injournal("You can't think of a way to use that item.")
end sub
Sub Reconnector()
var ReconnectTime, RFlag
ReconnectTime = '0'
RFlag = 1
Repeat
While (UO.ObjAtLayer('Bpack') == '')
if RFlag Then
ReconnectTime = MakeTime()
RFlag = 0
endif
Wait(40000) # WorldSave Protection
UO.Say('')
Wait(13000)
UO.Say('')
Wait(13000)
UO.Say('')
Wait(13000)
UO.LDblClick(357,164)
UO.LClick(616,459)
Wait(13000)
WEnd
Wait(13000)
if (RFlag == 0) and (ReconnectTime <> '0') Then
UO.Exec('terminate strelka')
UO.Exec('exec strelka')
UO.TextOpen()
UO.TextPrint('Disconnected & Reconnected @ '+ReconnectTime)
RFlag = 1
ReconnectTime = '0'
endif
Until false
end sub
Sub MakeTime()
VAR D, T, Ret, i
Ret = STR(UO.Time())
T = ""
For i = 0 To Len(Ret)
T = Ret[Len(Ret)-i] + T
If (I == 2) OR (I == 4) Then
T = ":" + T
EndIf
Next
Ret = STR(UO.Date())
D = ""
For i = 0 To Len(Ret)
D = Ret[Len(Ret)-i] + D
If (I == 2) OR (I == 4) Then
D = "." + D
EndIf
Next
Ret = T + " @ " + D
RETURN Ret
end sub