1
Script development tools / Re: Gaderian's Gump script helper
« on: April 30, 2020, 11:11:10 PM »
oh wow, this is really nice glad i stumbled upon this, good work it looks sharp
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
set %monstertype ZC_WE_IJB_ID_Q_V_UD_ED_RI_SI_EJ_QD_BE_WE_R_S_VI_FD_
set %petid WZXQ
set %scanpk
for %searchDistance 1 10
{
finditem %monstertype G_ , %searchdistance
if #findcnt > 0
{
set %targetkill #ltargetid
event sysmessage monster set
finditem %petid G_ , %searchdistance
if #findcnt > 0
{
event sysmessage pet distance is at #finddist
set %petdist1 #finddist
killloop:
set #ltargetid %targetkill
msg all kill$
wait 10
target
event macro 22 0
wait 10
{
finditem %petid G_ , %searchdistance
if #finddist <> %petdist1
{
event sysmessage MOVED
halt
if #finddist = %petdist1
{
event sysmessage STAYED
goto killloop
}
}
}
}
}
if #findcnt = 0
event sysmessage NO MOB
wait 30
return
Up to you but I would build the loop around enemy hits VS pet x y. I haven't had much luck getting a x y to compare its self to a set x y on my scripts. I'm sure it can be done.. But it it does work and your monster runs off at 5% as they do... Your going to loop as your pet chases. Just an idea.
set %monstertype ZC_WE_IJB_
set %petid PDZR
set %scanpk
for %searchDistance 1 10
{
finditem %monstertype G_ , %searchdistance
if #findcnt > 0
{
finditem %petid
wait 5
set %petdist #finddist
}
killloop:
finditem %monstertype G_ , %searchdistance
if #findcnt > 0
{
set #ltargetid #findid
msg all kill$
wait 5
target
event macro 22 0
wait 10
}
finditem %petid
if %petid = %petdist
{
event sysmessage attack again
goto killloop
if %petid <> %petdist
{
event sysmessage pet moving
halt
}
}
set %monstertype ZC_WE_IJB_
set %petid PDZR
set %scanpk
for %searchDistance 1 10
{
finditem %monstertype G_ , %searchdistance
if #findcnt > 0
{
finditem %petid
wait 5
set %petidx #findx
set %petidy #findy
}
killloop:
finditem %monstertype G_ , %searchdistance
if #findcnt > 0
{
set #ltargetid #findid
msg all kill$
wait 5
target
event macro 22 0
}
finditem %petid
if %petid = %petidx || %petid = %petidy
{
event sysmessage attack again
goto killloop
if %petid <> %petidx || %petid <> %petidy
{
event sysmessage pet moving
halt
}
}
I might point out a few things that look weird to me.
if #findkind
{
goto bankbookstock
}
Finditem %recallget C_ , %BankboxID
no condition on if statement for this and the next.
Also this statement and others like it does nothing
bankbookstock_exit
Also need waits after dropc commands
Hope this helps.
(I rarely use goto statements, I use gosub)
SET %weight 200
set %regamount 50
SET %bandageamount 200
SET %bankbook APNOHPD
SET %farmbook LPOELOD
SET %restockbag FTQDSPD
SET %lootbag ZRBNPMD
SET %dropbag RPYCWND
SET %dropoff POF_MYM
set %garlic KZF_
set %ginseng JZF_
set %mandrake RZF_
set %spider MZF_
set %bandage ZLF_
set %recallget WTL_
set %recallgetamount 100
set %bankboxID JYDQBND
GOSUB RESTOK
halt
SUB RESTOK
Finditem %recallget C_ , %BankboxID
if #findkind
{
goto bankbookstock
}
Finditem %recallget C_ , %BankboxID
if #findkind
{
goto farmbookstock
}
findItem %bandage C_ , %lootbag
if #findkind = -1
{
set %rg %bandage
goto bandagesnag
}
findItem %garlic C_ , %lootbag
if #findkind = -1
{
set %rg %garlic
goto regsnag
}
findItem %ginseng C_ , %lootbag
if #findkind = -1
{
set %rg %ginseng
goto regsnag
}
findItem %mandrake C_ , %lootbag
if #findkind = -1
{
set %rg %mandrake
goto regsnag
}
findItem %spider C_ , %lootbag
if #findkind = -1
{
set %rg %spider
goto regsnag
}
return
bankbookstock:
finditem %recallget C_ , %restockbag
exevent drag #findid #findstack
wait 10
exevent dropc %bankbook
bankbookstock_exit
farmbook:
finditem %recallget C_ , %restockbag
exevent drag #findid #findstack
wait 10
exevent dropc %bankbook
farmbook_exit
bandagesnag:
finditem %rg C_ , %restockbag
exevent drag #findid %bandageamount
wait 10
exevent dropc %lootbag
bandagesnag_exit
regsnag:
finditem %rg C_ , %restockbag
exevent drag #findid %regamount
wait 10
exevent dropc %lootbag
regsnag_exit
SET %weight 200
SET %restockbag FTQDSPD
SET %lootbag ZRBNPMD
SET %dropbag RPYCWND
SET %dropoff pof_ZLF_
loop:
if #weight > %weight
gosub opencontainers
gosub bankdrop
GoTo loop
;;;;;;;;;;;;;;;;;;;;;
sub bankdrop
loop1:
findItem %dropoff C_ , %lootbag
wait 8
if #findkind = -1
halt
if #findkind = 1
{
wait 10
exevent drag #findid #findstack
wait 10
exevent dropc %dropbag
goto loop1
return
;;;;;;;;;;;;;;;;;;;;;;
sub opencontainers
event macro 8 1 ; paperdoll
wait 10
Contpos 1450 40
wait 10
event macro 8 7 ;backpack
wait 10
contpos 1050 200
wait 10
msg bank $ ;open bank
wait 10
contpos 850 200
wait 10
set #LObjectID %lootbag ;lootbag
event macro 17 0
wait 10
Contpos 1450 400
wait 10
set #LObjectID %restockbag ;regs,aids
event macro 17 0
wait 10
Contpos 1050 400
return
SET %weight 200
SET %restockbag FTQDSPD
SET %lootbag ZRBNPMD
SET %dropbag RPYCWND
SET %dropoff pof_ZLF_
loop:
if #weight > %weight
gosub opencontainers
gosub bankdrop
GoTo loop
;;;;;;;;;;;;;;;;;;;;;
sub bankdrop
findItem %dropoff C_ , %lootbag
wait 8
if #findkind = -1
halt
if #findkind = 1
{
wait 10
exevent drag #findid #findstack
wait 10
exevent dropc %dropbag
}
return
;;;;;;;;;;;;;;;;;;;;;;
sub opencontainers
event macro 8 1 ; paperdoll
wait 10
Contpos 1450 40
wait 10
event macro 8 7 ;backpack
wait 10
contpos 1050 200
wait 10
msg bank $ ;open bank
wait 10
contpos 850 200
wait 10
set #LObjectID %lootbag ;lootbag
event macro 17 0
wait 10
Contpos 1450 400
wait 10
set #LObjectID %restockbag ;lootbag
event macro 17 0
wait 10
Contpos 1050 400
return
It just to kill the Boss. I see now. Was wondering if that was during regular hunting.
Will be nice to see the final product of this build. Seen like a little help for mage.
Glad it work for you, It is a nice little build to learn. did you see what you were missing.
here an idea for you
Here some little stuff that might help you. Have u think of those thing
find how long Corpse skin last
set %spellTimer #scnt2 + ( insert delay)
if ( %spellTimer < #scnt2 )
gosub CS
SET %target OE_XF_IE_LD_VE_BI_UB_HE_OE_CI_NG
SET !_lowHits 55
SET !_maxRange 10
; =====================================
IGNOREITEM reset
Ignoreitem #Charid
enemyloop:
FOR !_range 1 !_maxrange
{
FINDITEM %target G_ , !_range
IF #FINDKIND <> -1
{
SET #LTARGETID #FINDID
SET !_enemy #FINDID
if #findCnt > 0 && #mana > 41
GOSUB FS
if #findCnt > 0 && #mana < 40
GOSUB FB
}
WAIT 10
}
SET !_range 0
goto enemyLoop
;================
; ================
SUB FS
finditem !_enemy G_
if #findcnt > 0
{
event macro 15 50
set #ltargetkind 1
set #ltargetid #findid
target 3s
event macro 22 0
wait 5
}
FINDITEM !_enemy G_
IF #FINDKIND = 1
{
RETURN
;==================
SUB FB
finditem !_enemy G_
if #findcnt > 0
{
event macro 15 17
set #ltargetkind 1
set #ltargetid #findid
target 3s
event macro 22 0
wait 5
}
FINDITEM !_enemy G_
IF #FINDKIND = 1
{
RETURN