![:blush:](https://forum.oldp.net/public/style_emoticons/default/blush.png)
Toggle shoutbox
Chat
|
![Photo](https://forum.oldp.net/public/style_images/master/profile/default_large.png)
Nada Begging Skript!
#1
Posted 12 May 2008 - 20:47
![:blush:](https://forum.oldp.net/public/style_emoticons/default/blush.png)
#2
Posted 12 May 2008 - 20:48
#3
Posted 12 May 2008 - 20:52
iedod plz!Ja tev ir injects tad ru foruma ir uz injecta begging skripts ... Ja vajag varu iedot adresi.
#4
Posted 12 May 2008 - 21:03
#####################################################
#####################################################
############# Scripted by Occult ####################
#####################################################
############# OldParadise XL Begging ################
#####################################################
######### Version 1.4 ###############################
#####################################################
#####################################################
#------------------------------
#Change Log
# *If npc hase no money, he will go to next respawn.
# *Added second runebook recall.
# *Fixed message bug.
# *Fixed reconnector bug.
var book1='0x40022CE6' #runebook 1
var book2='0x40022BC9' #runebook 2
sub begging()
var k,j,b
var second=0 # 0 - two runebooks, 1 - one runebook.
#----------------------------------------
# NPC ID [,info]
#----------------------------------------
DIM ven[16]
ven[1]='0x00110057' #Britain tinker
ven[2]='0x00117859' #Moonglow provisioner
ven[3]='0x0011E2BB' #Moonglow carpenter
ven[4]='0x001177FE' #Minoc butcher
ven[5]='0x00118CFB' #Minoc banker
ven[6]='0x001193EF' #Britain blue boar
ven[7]='0x0011985A' #Moonglow provisioner
ven[8]='0x0011865F' #Britain bowyer2
ven[9]='0x0011D547' #Britain armorer
ven[10]='0x0011AB30' #Moonglow tinker
ven[11]='0x0011C7C4' #Britain farmer
ven[12]='0x0011CBEF' #Britain hides
ven[13]='0x0011AF97' #Britain tailor2
ven[14]='0x001171ED' #Moonglow cook
ven[15]='0x00117A7F' #Moonglow bs
ven[16]='0x0011607B' #Moonglow cook2
DIM vem[16]
vem[1]='0x00117B51' #Britain scribe
vem[2]='0x00114560' #Minoc bs
vem[3]='0x00117976' #Minoc tailor
vem[4]='0x0011C5A7' #Minoc carpenter
vem[5]='0x00119683' #Minoc provisioner
vem[6]='0x0011889F' #Minoc cook
vem[7]='0x0011BE17' #Minoc tamer
vem[8]='0x0011C475' #Minoc butcher
vem[9]='0x0011641A' #Moonglow alchemic
vem[10]='0x00118886' #Moonglow alchemic 2
vem[11]='0x001116FA' #Britain bs
vem[12]='0x00111085' #Britain bs2
vem[13]='0x00118751' #Britain architect
vem[14]='0x00116981' #Britain armor2
vem[15]='0x0011619A' #Britain provisioner
vem[16]='0x0011AC4A' #Britain jeweler
while not uo.dead()
for k=1 to 16
recall(book1,k)
UO.DeleteJournal()
repeat
wait(2000)
SuperWalk(0,0,ven[k])
UO.WaitTargetObject(ven[k])
UO.Useskill('Begging')
#wait(2000)
until UO.InJournal("You put the gold") or UO.InJournal("You receive") or (uo.JournalSerial(uo.InJournal("no money")-1))==ven[k]
next
if second==0 then
for j=1 to 16
recall(book2,j)
UO.DeleteJournal()
repeat
wait(2000)
SuperWalk(0,0,vem[j])
UO.WaitTargetObject(vem[j])
UO.Useskill('Begging')
#wait(2000)
until UO.InJournal("You put the gold") or UO.InJournal("You receive") or (uo.JournalSerial(uo.InJournal("no money")-1))==vem[j]
next
end if
wend
endsub
#==========================================================
# Recall System
# idrb - runebook id
# nrune - rune number
#----------------------------------------------------------
#---------------------------
# Runebook recall
# reagent use
#---------------------------
sub Recall(idrb,nrune)
Dim gumpreturn[16]
gumpreturn[1]="0x0002"
gumpreturn[2]="0x0003"
gumpreturn[3]="0x0004"
gumpreturn[4]="0x0005"
gumpreturn[5]="0x0006"
gumpreturn[6]="0x0007"
gumpreturn[7]="0x0008"
gumpreturn[8]="0x0009"
gumpreturn[9]="0x002A"
gumpreturn[10]="0x003B"
gumpreturn[11]="0x004C"
gumpreturn[12]="0x005D"
gumpreturn[13]="0x006E"
gumpreturn[14]="0x007F"
gumpreturn[15]="0x008G"
gumpreturn[16]="0x009H"
UO.Recall(idrb,gumpreturn[nrune])
UO.Exec('terminate Reconnector')
wait(5000)
UO.Exec('exec Reconnector')
wait(5000)
Uo.DeleteJournal()
endsub
#==============================================================
# SuperWalk(X,Y,Serial) - char is walking by dX and dY step
# sub using Home, End, PgUp, PgDown keys
# d'not rebind this key from default action!
# walkwait - delay after keypress
#--------------------------------------------------------------
sub SuperWalk(x,y,Target)
VAR i
VAR dir,ldir,rdir,key,olddir
VAR dx,dy,Exit=0
VAR CacheLimit=9,CacheIndex="Text"
DIM CacheX[10], CacheY[10]
CacheX[0]="Test"
While Exit<>1
If Target<>"" Then
dx=UO.GetX(Target)-UO.GetX()
dy=UO.GetY(Target)-UO.GetY()
; UO.Print("Target locked!")
If UO.GetDistance(Target)<2 Then
return
Endif
Else
dx=x-UO.GetX()
dy=y-UO.GetY()
If dx==0 AND dy==0 Then
Exit=1
Endif
Endif
If dx<>0 AND dy<>0 Then
If dx>0 AND dy>0 Then; GoSE
dir=3
ldir=2
rdir=4
key=40; DownArrow
olddir=UO.GetDir()
If StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key) Then
If olddir==2 Then; GoNE
dir=1
ldir=0
rdir=1
key=39; RightArrow
While UO.GetDir()<>1
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSW
dir=5
ldir=5
rdir=6
key=37; LeftArrow
While UO.GetDir()<>5
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
If dx>0 AND dy<0 Then; GoNE
dir=1
ldir=0
rdir=2
key=39; RightArrow
olddir=UO.GetDir()
If StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key) Then
If olddir==0 Then; GoWN
dir=7
ldir=6
rdir=7
key=38; UpArrow
While UO.GetDir()<>7
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSE
dir=3
ldir=3
rdir=4
key=40; DownArrow
While UO.GetDir()<>3
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
If dx<0 AND dy>0 Then; GoSW
dir=5
ldir=4
rdir=6
key=37; LeftArrow
olddir=UO.GetDir()
If StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key) Then
If olddir==6 Then; GoWN
dir=7
ldir=7
rdir=0
key=38; UpArrow
While UO.GetDir()<>7
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSE
dir=3
ldir=2
rdir=3
key=40; DownArrow
While UO.GetDir()<>3
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
If dx<0 AND dy<0 Then; GoWN
dir=7
ldir=6
rdir=0
key=38; UpArrow
olddir=UO.GetDir()
If StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key) Then
If olddir==0 Then; GoNE
dir=1
ldir=1
rdir=2
key=39; RightArrow
While UO.GetDir()<>1
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSW
dir=5
ldir=4
rdir=5
key=37; LeftArrow
While UO.GetDir()<>5
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
Endif
If dx<>0 AND dy==0 Then
If dx>0 Then; GoE
dir=2
key=34; PgDown
olddir=UO.GetDir()
If StepEdit(UO.GetX(),UO.GetY(),dir,key) Then
If olddir==2 Then; GoSE
dir=3
ldir=3
rdir=4
key=40; DownArrow
While UO.GetDir()<>3
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoNE
dir=1
ldir=1
rdir=0
key=39; RightArrow
While UO.GetDir()<>1
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
If dx<0 Then; GoW
dir=6
key=36; Home key
olddir=UO.GetDir()
If StepEdit(UO.GetX(),UO.GetY(),dir,key) Then
If olddir==0 Then; GoWN
dir=7
ldir=7
rdir=0
key=38; UpArrow
While UO.GetDir()<>7
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSW
dir=5
ldir=4
rdir=5
key=37; LeftArrow
While UO.GetDir()<>5
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
Endif
If dx==0 AND dy<>0 Then
If dy>0 Then; GoS
dir=4
key=35; End
If StepEdit(UO.GetX(),UO.GetY(),dir,key) Then
If olddir==2 Then; GoSE
dir=3
ldir=2
rdir=3
key=40; DownArrow
While UO.GetDir()<>3
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoSW
dir=5
ldir=6
rdir=5
key=37; LeftArrow
While UO.GetDir()<>5
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
If dy<0 Then;GoN
dir=0
key=33; PgUp
olddir=UO.GetDir()
If StepEdit(UO.GetX(),UO.GetY(),dir,key) Then
If olddir==2 Then; GoNE
dir=1
ldir=1
rdir=2
key=39; RightArrow
While UO.GetDir()<>1
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Else; GoWN
dir=7
ldir=7
rdir=6
key=38; UpArrow
While UO.GetDir()<>7
StepArrow(UO.GetX(),UO.GetY(),dir,ldir,rdir,key)
Wend
Endif
Endif
Endif
Endif
Wend
end sub
sub StepEdit(x,y,dir,key)
VAR walkwait=300
VAR ErrLevel=0
If UO.GetDir()<>dir Then
checkstam()
UO.Press(key)
wait(walkwait)
If UO.GetDir()<>dir Then
CheckLag()
Endif
Endif
checkstam()
UO.Press(key)
wait(walkwait)
If x==UO.GetX() AND y==UO.GetY() Then
CheckLag()
If x==UO.GetX() AND y==UO.GetY() Then
;zatik
ErrLevel=1
Endif
Endif
Return ErrLevel
end sub
sub StepArrow(x,y,dir,ldir,rdir,key)
VAR walkwait=300
VAR ErrLevel=0
If UO.GetDir()<>dir Then
checkstam()
UO.Press(key)
wait(walkwait)
If UO.GetDir()<>dir AND UO.GetDir()<>ldir AND UO.GetDir()<>rdir Then
CheckLag()
Endif
Endif
If UO.GetX()==x AND UO.GetY()==y Then
checkstam()
UO.Press(key)
wait(walkwait)
If UO.GetDir()==dir AND UO.GetX()==x AND UO.GetY()==y Then
CheckLag()
If UO.GetDir()==dir AND UO.GetX()==x AND UO.GetY()==y Then
; zatik
ErrLevel=1
Endif
Endif
Endif
Return ErrLevel
end sub
#========================================
# Functions
# chechstam()
# checklag()
# reconnector()
#----------------------------------------
sub checkstam()
var refresh = '0x0F0B'
if uo.stamina < 10 then
uo.findtype(refresh,-1,'backpack')
if uo.findcount() then
uo.usetype(refresh)
wait(2000)
else
uo.print("Nety Refreshey! Stoim...")
repeat
wait(2000)
until uo.stamina >= 10
endif
else
endif
endsub
sub CheckLag()
uo.DeleteJournal()
uo.Click('backpack')
repeat
wait(2000)
until UO.InJournal('backpack')
endsub
sub Reconnector()
var ReconnectTime, RFlag
ReconnectTime = '0'
RFlag = 1
Repeat
While (UO.ObjAtLayer('Bpack') == '')
if RFlag Then
ReconnectTime = MakeTime()
RFlag = 0
endif
Wait(20000) # WorldSave Protection
UO.Say('')
Wait(3000)
UO.Say('')
Wait(3000)
UO.Say('')
Wait(3000)
UO.LDblClick(357,164)
UO.LClick(616,459)
Wait(3000)
WEnd
Wait(3000)
if (RFlag == 0) and (ReconnectTime <> '0') Then
UO.Exec('terminate Begging')
wait(2000)
UO.Exec('exec Begging')
wait(2000)
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
#5
Posted 12 May 2008 - 21:06
#7
Posted 12 May 2008 - 21:23
strādā labi...
vari bisku apskaidrot ka laj dabunu sava runebuka id? tads tur vispar jaraksta? man kaut kadu line 160 error met ara
![:excl:](https://forum.oldp.net/public/style_emoticons/default/excl.png)
#8
Posted 12 May 2008 - 21:39
#9
Posted 13 May 2008 - 16:29
![:)](https://forum.oldp.net/public/style_emoticons/default/smile.png)
#10
Posted 13 May 2008 - 16:40
#11
Posted 13 May 2008 - 17:29
![;)](https://forum.oldp.net/public/style_emoticons/default/wink.png)
#12
Posted 15 March 2009 - 12:03
man kaut kadu line 160 error met ara
man ar tas pats ko man darit?
#13
Posted 15 March 2009 - 12:41
cik noprotu viss tas scp ir sagljuchits domaju vabut jauzliek ta If dx>0 AND dy>0 Then ; GoSE (atstarpe) vins izmet tadus pashus talak, nu lidzigus, tiem ari salieku, a pashapedeja rinda atkal gluks
#14
Posted 30 March 2009 - 15:03
![:D](https://forum.oldp.net/public/style_emoticons/default/biggrin.png)
#15
Posted 30 March 2009 - 16:02
Shis tak ir uz injecta!
Ei nu es vislaik meginaju uz pilota VISI TO ZIN
1 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users
-
Facebook (1)