1
Script Debug / Re: Hey my first script in the making! Please help lol
« on: October 05, 2011, 02:48:31 PM »
Yea im a mechanic so im right there with you, this stuff can go over my head fast! What i learned help me thru this script is what i learned in one of the tutorials is think of what you want and to write it down. simple steps.. then put in what u want checked for that one step. Also if i got stuck one trying to figure out codes, i either bothered these guys lmao. or i read into some scripts that did what i wanted to do and play around.
i been writing the script from top to bottom, and testing every few lines by putting halt at the end and seeing if it did what i wanted, i also put all my wait times up high for testing so if it did mess up i can push pause and see where im at. You can always speed up your script at then end. this one here does it super fast for me. but it's also set up to my comp connection. so if u did want to use it play around with the times by adding if too fast. def cant be to slow.. lmao
i been writing the script from top to bottom, and testing every few lines by putting halt at the end and seeing if it did what i wanted, i also put all my wait times up high for testing so if it did mess up i can push pause and see where im at. You can always speed up your script at then end. this one here does it super fast for me. but it's also set up to my comp connection. so if u did want to use it play around with the times by adding if too fast. def cant be to slow.. lmao
Code: [Select]
; Created by Monoxide
; Date 10/4/2011
; Created to Help getting Mace and Shield Glasses
;
; <<< THIS ONLY WORKS FOR SERVERS THAT HAVE INSTANT SPAWN NPCS FOR FAST BUYING. IF YOU ARE LOOKING FOR SOMETHING THAT SITS >>>
; <<< THERE TO STOCKUP THE PILE GO SOMEWHERE ELSE!!! >>>
;
;
;
;
;
; Setup
; You will need 1 runebook, no more no less or things will get funny.
; 1st rune the npc vendor selling Bucklers And War Axes within a tile, unless your server allows vendor buy further.
; 2nd rune to the library donation npc (close enough to reach out and touch him)
; 3rd rune the bank somewhere you know u have access to banker and withdrawl money
; You will need razor buying agent enabled, and set to bucklers and war axes, or whatever you want. i believe it will skip over it.. not really sure guess u find out
event macro 8 2
Start
if #gold < 1100
gosub gotta_get_gold
findItem ZBN
set #lobjectID #findID
set #ltargetKind 1
event macro 17 0
wait 5
set #contPosX 10
set #contPosY 10
contpos
wait 5
click 144 80
wait 20
findItem ZBN
set #lobjectID #findID
set #ltargetKind 1
event macro 17 0
wait 20
set #contPosX 10
set #contPosY 10
contpos
wait 10
msg vendor buy$
wait 20
click 144 95
wait 50
finditem BGKH G_20
if #FINDCNT > 0
set #lobjectID #findID
event macro 17 0
wait 10
set #contPosX 10
set #contPosY 10
contpos
wait 10
click 316 352
wait 5
click 316 352
wait 5
click 48 180
wait 10
msg 20$
wait 5
set #contPosX 10
set #contPosY 10
contpos
wait 10
wait 5
click 316 352
wait 5
click 316 352
wait 5
click 50 250
wait 10
msg 20$
wait 20
loop
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
sub gotta_get_gold
findItem ZBN
set #lobjectID #findID
set #ltargetKind 1
event macro 17 0
wait 20
set #contPosX 10
set #contPosY 10
contpos
wait 20
click 142 110
wait 50
msg withdrawl 5000$
wait 50
msg withdrawl 5000$
wait 50
return