Альтернативные варианты:
Ожидание 250 мс, пока не откроетсяCode:
sub CheckBankOpened()
var idLastContainer
uo.UseObject('backpack')
wait(250)
idLastContainer = uo.GetSerial('lastcontainer')
uo.Msg('bank')
wait(250)
if uo.GetSerial('lastcontainer') <> idLastContainer then
uo.Print('opened')
else
uo.Print('not oppened. lag or another container opened.')
endif
end sub
Ожидание, пока не откроетсяCode:
sub CheckBankOpened()
var idLastContainer
uo.UseObject('backpack')
wait(250)
idLastContainer = uo.GetSerial('lastcontainer')
uo.Msg('bank')
repeat
wait(100)
until uo.GetSerial('lastcontainer') <> idLastContainer
uo.Print('opened')
end sub