Repair (script): Difference between revisions
Jump to navigation
Jump to search
(Created page with '{{Script |cat=utility |fe=Genie |auth=Isharon }} ==Description== This script submits all of the equipment that I am carrying for repair, waits until the repair…') |
No edit summary |
||
Line 17: | Line 17: | ||
==Script== |
==Script== |
||
<pre> |
<pre>if $zoneid = 1 then |
||
setvar havetrousers 0 |
|||
setvar haveironwood_greaves 0 |
|||
setvar haveivory_greaves 0 |
|||
setvar havegold-edged_greaves 0 |
|||
setvar havepolished_greaves 0 |
|||
setvar havesilver-edged_greaves 0 |
|||
setvar havenightstick 0 |
|||
setvar havebola 0 |
|||
setvar havethrowing_club 0 |
|||
setvar havethrowing_hammer 0 |
|||
setvar havebludgeon 0 |
|||
setvar havemace 0 |
|||
setvar havewarhammer 0 |
|||
setvar havechain 0 |
|||
setvar havemorning-star 0 |
|||
setvar havemaul 0 |
|||
setvar havemattock 0 |
|||
setvar havebaldric 0 |
|||
setvar havehalberd 0 |
|||
setvar haveskinning_knife 0 |
|||
setvar havestiletto 0 |
|||
setvar havedao 0 |
|||
setvar haveflat-black_sword 0 |
|||
setvar havejambiya 0 |
|||
setvar havescimitar 0 |
|||
setvar haveiltesh 0 |
|||
setvar havebroadsword 0 |
|||
setvar haveblade 0 |
|||
setvar havebrushed_sword 0 |
|||
setvar havegleaming_sword 0 |
|||
setvar havegreatsword 0 |
|||
ACTION setvar havelegwraps 1 WHEN ^In the .+ pack you see .+ legwraps |
|||
ACTION setvar havetrousers 1 WHEN ^In the .+ pack you see .+ trousers |
|||
ACTION setvar haveironwood_greaves 1 WHEN ^In the .+ pack you see .+ ironwood greaves |
|||
ACTION setvar haveivory_greaves 1 WHEN ^In the .+ pack you see .+ ivory greaves |
|||
ACTION setvar havegold-edged_greaves 1 WHEN ^In the .+ pack you see .+ gold-edged greaves |
|||
ACTION setvar havepolished_greaves 1 WHEN ^In the .+ pack you see .+ polished gold greaves |
|||
ACTION setvar havesilver-edged_greaves 1 WHEN ^In the .+ pack you see .+ silver-edged greaves |
|||
ACTION setvar havenightstick 1 WHEN ^In the .+ pack you see .+ nightstick |
|||
ACTION setvar havebola 1 WHEN ^In the .+ pack you see .+ bola |
|||
ACTION setvar havethrowing_club 1 WHEN ^In the .+ pack you see .+ throwing club |
|||
ACTION setvar havethrowing_hammer 1 WHEN ^In the .+ pack you see .+ throwing hammer |
|||
ACTION setvar havebludgeon 1 WHEN ^In the .+ pack you see .+ bludgeon |
|||
ACTION setvar havemace 1 WHEN ^In the .+ pack you see .+ \bmace\b |
|||
ACTION setvar havewarhammer 1 WHEN ^In the .+ pack you see .+ warhammer |
|||
ACTION setvar havechain 1 WHEN ^In the .+ pack you see .+ ball and chain |
|||
ACTION setvar havemorning-star 1 WHEN ^In the .+ pack you see .+ morning-star |
|||
ACTION setvar havemaul 1 WHEN ^In the .+ pack you see .+ \bmaul\b |
|||
ACTION setvar havemattock 1 WHEN ^In the .+ pack you see .+ mattock |
|||
ACTION setvar havebaldric 1 WHEN ^In the .+ pack you see .+ baldric |
|||
ACTION setvar havehalberd 1 WHEN ^In the .+ pack you see .+ halberd |
|||
ACTION setvar haveskinning_knife 1 WHEN ^In the .+ you see .+ skinning knife |
|||
ACTION setvar havestiletto 1 WHEN ^In the .+ you see .+ stiletto |
|||
ACTION setvar havedao 1 WHEN ^In the .+ you see .+ dao |
|||
ACTION setvar haveflat-black_sword 1 WHEN ^In the .+ you see .+ flat-black sword |
|||
ACTION setvar havejambiya 1 WHEN ^In the .+ you see .+ jambiya |
|||
ACTION setvar havescimitar 1 WHEN ^In the .+ you see .+ scimitar |
|||
ACTION setvar haveiltesh 1 WHEN ^In the .+ you see .+ iltesh |
|||
ACTION setvar havebroadsword 1 WHEN ^In the .+ you see .+ broadsword |
|||
ACTION setvar haveblade 1 WHEN ^In the .+ you see .+ blade |
|||
ACTION setvar havebrushed_sword 1 WHEN ^In the .+ you see .+ copper sword |
|||
ACTION setvar havegleaming_sword 1 WHEN ^In the .+ you see .+ silver sword |
|||
ACTION setvar havegreatsword 1 WHEN ^In the .+ you see .+ greatsword |
|||
put look in my $pack |
|||
waitforre ^In the .+ pack you see |
|||
put look in my $sheath |
|||
waitforre ^In the.+$sheath you see|^I could not find |
|||
if %havelegwraps = 1 then |
|||
{ |
{ |
||
var |
put #var mrep Catrox |
||
put #var lrep Randal |
|||
gosub repair1 |
|||
} |
} |
||
if %havetrousers = 1 then |
|||
if $zoneid = 4 then |
|||
{ |
{ |
||
var |
put #var mrep Catrox |
||
put #var lrep Randal |
|||
gosub repair1 |
|||
} |
} |
||
if %haveironwood_greaves = 1 then |
|||
if $zoneid = 40 then |
|||
{ |
{ |
||
put #var mrep Dagul |
|||
var repair ironwood greaves |
|||
put #var lrep Kamze |
|||
gosub repair1 |
|||
} |
} |
||
if %haveivory_greaves = 1 then |
|||
if $zoneid = 42 then |
|||
{ |
{ |
||
put #var mrep Dagul |
|||
var repair ivory greaves |
|||
put #var lrep Kamze |
|||
gosub repair1 |
|||
} |
} |
||
if %havegold-edged_greaves = 1 then |
|||
if $zoneid = 47 then |
|||
{ |
{ |
||
put #var mrep Fekoeti |
|||
var repair gold-edged greaves |
|||
put #var lrep Bonze |
|||
gosub repair1 |
|||
} |
} |
||
if %havepolished_greaves = 1 then |
|||
if $zoneid = 48 then |
|||
{ |
{ |
||
put #var mrep Fekoeti |
|||
var repair polished greaves |
|||
put #var lrep Bonze |
|||
gosub repair1 |
|||
} |
} |
||
if %havesilver-edged_greaves = 1 then |
|||
if $zoneid = 66 then |
|||
{ |
{ |
||
put #var mrep Granzer |
|||
var repair silver-edged greaves |
|||
put #var lrep Ylono |
|||
gosub repair1 |
|||
} |
|||
if %havenightstick = 1 then |
|||
{ |
|||
var repair nightstick |
|||
gosub repair1 |
|||
} |
|||
if %havebola = 1 then |
|||
{ |
|||
var repair bola |
|||
gosub repair1 |
|||
} |
|||
if %havethrowing_club = 1 then |
|||
{ |
|||
var repair throwing club |
|||
gosub repair1 |
|||
} |
|||
if %havethrowing_hammer = 1 then |
|||
{ |
|||
var repair throwing hammer |
|||
gosub repair1 |
|||
} |
|||
if %havebludgeon = 1 then |
|||
{ |
|||
var repair bludgeon |
|||
gosub repair1 |
|||
} |
|||
if %havemace = 1 then |
|||
{ |
|||
var repair mace |
|||
gosub repair1 |
|||
} |
|||
if %havewarhammer = 1 then |
|||
{ |
|||
var repair warhammer |
|||
gosub repair1 |
|||
} |
|||
if %havechain = 1 then |
|||
{ |
|||
var repair chain |
|||
gosub repair1 |
|||
} |
|||
if %havemorning-star = 1 then |
|||
{ |
|||
var repair morning-star |
|||
gosub repair1 |
|||
} |
|||
if %havemaul = 1 then |
|||
{ |
|||
var repair maul |
|||
gosub repair1 |
|||
} |
|||
if %havemattock = 1 then |
|||
{ |
|||
var repair mattock |
|||
gosub repair1 |
|||
} |
|||
if %havebaldric = 1 then |
|||
{ |
|||
var repair baldric |
|||
gosub repair1 |
|||
} |
|||
if %havehalberd = 1 then |
|||
{ |
|||
var repair halberd |
|||
gosub repair1 |
|||
} |
|||
if %haveskinning_knife = 1 then |
|||
{ |
|||
var repair skinning knife |
|||
gosub repair2 |
|||
} |
|||
if %havestiletto = 1 then |
|||
{ |
|||
var repair stiletto |
|||
gosub repair2 |
|||
} |
|||
if %havedao = 1 then |
|||
{ |
|||
var repair dao |
|||
gosub repair2 |
|||
} |
|||
if %haveflat-black_sword = 1 then |
|||
{ |
|||
var repair flat-black sword |
|||
gosub repair2 |
|||
} |
|||
if %havejambiya = 1 then |
|||
{ |
|||
var repair jambiya |
|||
gosub repair2 |
|||
} |
|||
if %havescimitar = 1 then |
|||
{ |
|||
var repair scimitar |
|||
gosub repair2 |
|||
} |
|||
if %haveiltesh = 1 then |
|||
{ |
|||
var repair iltesh |
|||
gosub repair2 |
|||
} |
|||
if %havebroadsword = 1 then |
|||
{ |
|||
var repair broadsword |
|||
gosub repair2 |
|||
} |
|||
if %haveblade = 1 then |
|||
{ |
|||
var repair blade |
|||
gosub repair2 |
|||
} |
|||
if %havebrushed_sword = 1 then |
|||
{ |
|||
var repair brushed sword |
|||
gosub repair2 |
|||
} |
|||
if %havegleaming_sword = 1 then |
|||
{ |
|||
var repair gleaming sword |
|||
gosub repair2 |
|||
} |
|||
if %havegreatsword = 1 then |
|||
{ |
|||
var repair greatsword |
|||
gosub repair2 |
|||
} |
} |
||
put #class racial on |
|||
put #class rp on |
|||
put #class combat off |
|||
put #class joust off |
|||
setvar check_sheath_item1 0 |
|||
setvar check_sheath_item2 0 |
|||
setvar check_sheath_item3 0 |
|||
setvar check_pack_item1 0 |
|||
setvar check_pack_item2 0 |
|||
setvar check_pack_item3 0 |
|||
ACTION setvar check_sheath_item1 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item1 |
|||
ACTION setvar check_sheath_item2 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item2 |
|||
ACTION setvar check_sheath_item3 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item3 |
|||
ACTION setvar check_pack_item1 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item1 |
|||
ACTION setvar check_pack_item2 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item2 |
|||
ACTION setvar check_pack_item3 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item3 |
|||
send rummage in my $sheath |
|||
waitforre ^You rummage through.+and see|^I could not find|^I don't know what you are referring to |
|||
send rummage in my $pack |
|||
waitforre ^You rummage through.+and see|^I could not find|^I don't know what you are referring to |
|||
if %check_sheath_item1 = 1 then gosub gives item1 |
|||
if %check_sheath_item2 = 1 then gosub gives item2 |
|||
if %check_sheath_item3 = 1 then gosub gives item3 |
|||
if %check_pack_item1 = 1 then gosub gives item1 |
|||
if %check_pack_item2 = 1 then gosub gives item2 |
|||
if %check_pack_item3 = 1 then gosub gives item3 |
|||
echo ***** Now waiting for repairs to be ready. ***** |
|||
goto waitrep |
goto waitrep |
||
gives: |
|||
repair1: |
|||
var repair $0 |
|||
send get my %repair |
|||
send get my %repair from my $sheath |
|||
waitforre ^You get|^You are already |
|||
waitforre ^You get|^What |
|||
send ask %1 about repairing all |
send ask %1 about repairing all |
||
waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" |
|||
send ask %1 about repairing all |
send ask %1 about repairing all |
||
waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" |
|||
send stow my %1 ticket |
send stow my %1 ticket |
||
waitforre ^You|^Perhaps|^Stow|^What |
waitforre ^You|^Perhaps|^Stow|^What |
||
send put my %repair in my $ |
send put my %repair in my $sheath |
||
waitforre ^You|^Perhaps|^Stow|^What |
waitforre ^You|^Perhaps|^Stow|^What |
||
pause .5 |
pause .5 |
||
return |
return |
||
givep: |
|||
repair2: |
|||
var repair $0 |
|||
send get my %repair |
|||
send get my %repair from my $pack |
|||
waitforre ^You get|^You are already |
|||
waitforre ^You get|^What |
|||
send ask %1 about repairing all |
send ask %1 about repairing all |
||
waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" |
|||
send ask %1 about repairing all |
send ask %1 about repairing all |
||
waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" |
|||
send stow my %1 ticket |
send stow my %1 ticket |
||
waitforre ^You|^Perhaps|^Stow|^What |
waitforre ^You|^Perhaps|^Stow|^What |
||
send put my %repair in my $ |
send put my %repair in my $pack |
||
waitforre ^You|^Perhaps|^Stow|^What |
waitforre ^You|^Perhaps|^Stow|^What |
||
pause .5 |
pause .5 |
||
Line 276: | Line 125: | ||
pause 20 |
pause 20 |
||
send read my %1 ticket |
send read my %1 ticket |
||
matchre |
matchre getstart repairs should be ready by now |
||
matchre exit ^What were you referring to|^I could not find what you were referring to |
|||
matchwait 1 |
matchwait 1 |
||
goto waitrep |
goto waitrep |
||
getstart: |
|||
get: |
|||
setvar |
setvar get_item1 0 |
||
setvar |
setvar get_item2 0 |
||
setvar |
setvar get_item3 0 |
||
setvar elbow_spikes 0 |
|||
setvar stick 0 |
|||
setvar greaves 0 |
|||
setvar gloves 0 |
|||
setvar gauntlets 0 |
|||
setvar vambraces 0 |
|||
setvar coat 0 |
|||
setvar leathers 0 |
|||
setvar shirt 0 |
|||
setvar robe 0 |
|||
setvar hauberk 0 |
|||
setvar breastplate 0 |
|||
setvar plate 0 |
|||
setvar armor 0 |
|||
setvar cowl 0 |
|||
setvar balaclava 0 |
|||
setvar helm 0 |
|||
setvar buckler 0 |
|||
setvar shield 0 |
|||
setvar longbow 0 |
|||
setvar ironwood_staff 0 |
|||
setvar spear 0 |
|||
setvar legwraps 0 |
|||
setvar trousers 0 |
|||
setvar ironwood_greaves 0 |
|||
setvar ivory_greaves 0 |
|||
setvar gold-edged_greaves 0 |
|||
setvar polished_greaves 0 |
|||
setvar silver-edged_greaves 0 |
|||
setvar nightstick 0 |
|||
setvar bola 0 |
|||
setvar throwing_club 0 |
|||
setvar throwing_hammer 0 |
|||
setvar bludgeon 0 |
|||
setvar mace 0 |
|||
setvar warhammer 0 |
|||
setvar chain 0 |
|||
setvar morning-star 0 |
|||
setvar maul 0 |
|||
setvar mattock 0 |
|||
setvar baldric 0 |
|||
setvar halberd 0 |
|||
setvar skinning_knife 0 |
|||
setvar stiletto 0 |
|||
setvar dao 0 |
|||
setvar flat-black_sword 0 |
|||
setvar jambiya 0 |
|||
setvar scimitar 0 |
|||
setvar iltesh 0 |
|||
setvar broadsword 0 |
|||
setvar blade 0 |
|||
setvar brushed_sword 0 |
|||
setvar gleaming_sword 0 |
|||
setvar greatsword 0 |
|||
ACTION setvar |
ACTION setvar get_item1 1 WHEN ^You rummage through a large sack and see.+item1 |
||
ACTION setvar |
ACTION setvar get_item2 1 WHEN ^You rummage through a large sack and see.+item2 |
||
ACTION setvar |
ACTION setvar get_item3 1 WHEN ^You rummage through a large sack and see.+item3 |
||
ACTION setvar elbow_spikes 1 WHEN ^In the large sack you see .+ elbow spikes |
|||
ACTION setvar stick 1 WHEN ^In the large sack you see .+ parry stick |
|||
ACTION setvar greaves 1 WHEN ^In the large sack you see .+ greaves |
|||
ACTION setvar gloves 1 WHEN ^In the large sack you see .+ gloves |
|||
ACTION setvar gauntlets 1 WHEN ^In the large sack you see .+ gauntlets |
|||
ACTION setvar vambraces 1 WHEN ^In the large sack you see .+ vambraces |
|||
ACTION setvar coat 1 WHEN ^In the large sack you see .+ \bcoat\b |
|||
ACTION setvar leathers 1 WHEN ^In the large sack you see .+ leathers |
|||
ACTION setvar shirt 1 WHEN ^In the large sack you see .+ shirt |
|||
ACTION setvar robe 1 WHEN ^In the large sack you see .+ robe |
|||
ACTION setvar hauberk 1 WHEN ^In the large sack you see .+ hauberk |
|||
ACTION setvar breastplate 1 WHEN ^In the large sack you see .+ breastplate |
|||
ACTION setvar plate 1 WHEN ^In the large sack you see .+ gleaming silver plate |
|||
ACTION setvar armor 1 WHEN ^In the large sack you see .+ (gleaming silver armor|field armor) |
|||
ACTION setvar cowl 1 WHEN ^In the large sack you see .+ cowl |
|||
ACTION setvar balaclava 1 WHEN ^In the large sack you see .+ balaclava |
|||
ACTION setvar helm 1 WHEN ^In the large sack you see .+ \bhelm\b |
|||
ACTION setvar buckler 1 WHEN ^In the large sack you see .+ buckler |
|||
ACTION setvar shield 1 WHEN ^In the large sack you see .+ shield |
|||
ACTION setvar longbow 1 WHEN ^In the large sack you see .+ longbow |
|||
ACTION setvar ironwood_staff 1 WHEN ^In the large sack you see .+ quarter staff |
|||
ACTION setvar spear 1 WHEN ^In the large sack you see .+ spear |
|||
ACTION setvar legwraps 1 WHEN ^In the large sack you see .+ legwraps |
|||
ACTION setvar trousers 1 WHEN ^In the large sack you see .+ trousers |
|||
ACTION setvar ironwood_greaves 1 WHEN ^In the large sack you see .+ ironwood greaves |
|||
ACTION setvar ivory_greaves 1 WHEN ^In the large sack you see .+ ivory greaves |
|||
ACTION setvar polished_greaves 1 WHEN ^In the large sack you see .+ polished gold greaves |
|||
ACTION setvar silver-edged_greaves 1 WHEN ^In the large sack you see .+ silver-edged greaves |
|||
ACTION setvar nightstick 1 WHEN ^In the large sack you see .+ nightstick |
|||
ACTION setvar bola 1 WHEN ^In the large sack you see .+ bola |
|||
ACTION setvar throwing_club 1 WHEN ^In the large sack you see .+ throwing club |
|||
ACTION setvar throwing_hammer 1 WHEN ^In the large sack you see .+ throwing hammer |
|||
ACTION setvar bludgeon 1 WHEN ^In the large sack you see .+ bludgeon |
|||
ACTION setvar mace 1 WHEN ^In the large sack you see .+ \bmace\b |
|||
ACTION setvar warhammer 1 WHEN ^In the large sack you see .+ warhammer |
|||
ACTION setvar chain 1 WHEN ^In the large sack you see .+ ball and chain |
|||
ACTION setvar morning-star 1 WHEN ^In the large sack you see .+ morning-star |
|||
ACTION setvar maul 1 WHEN ^In the large sack you see .+ \bmaul\b |
|||
ACTION setvar mattock 1 WHEN ^In the large sack you see .+ mattock |
|||
ACTION setvar baldric 1 WHEN ^In the large sack you see .+ baldric |
|||
ACTION setvar halberd 1 WHEN ^In the large sack you see .+ halberd |
|||
ACTION setvar skinning_knife 1 WHEN ^In the large sack you see .+ skinning knife |
|||
ACTION setvar stiletto 1 WHEN ^In the large sack you see .+ stiletto |
|||
ACTION setvar dao 1 WHEN ^In the large sack you see .+ dao |
|||
ACTION setvar flat-black_sword 1 WHEN ^In the large sack you see .+ flat-black sword |
|||
ACTION setvar jambiya 1 WHEN ^In the large sack you see .+ jambiya |
|||
ACTION setvar scimitar 1 WHEN ^In the large sack you see .+ scimitar |
|||
ACTION setvar iltesh 1 WHEN ^In the large sack you see .+ iltesh |
|||
ACTION setvar broadsword 1 WHEN ^In the large sack you see .+ broadsword |
|||
ACTION setvar blade 1 WHEN ^In the large sack you see .+ blade |
|||
ACTION setvar brushed_sword 1 WHEN ^In the large sack you see .+ copper sword |
|||
ACTION setvar gleaming_sword 1 WHEN ^In the large sack you see .+ silver sword |
|||
ACTION setvar greatsword 1 WHEN ^In the large sack you see .+ greatsword |
|||
send get my %1 ticket |
send get my %1 ticket |
||
Line 401: | Line 144: | ||
send give %1 |
send give %1 |
||
waitforre ^You hand |
waitforre ^You hand |
||
send swap |
|||
send look in my large sack |
|||
waitforre ^ |
waitforre ^You move |
||
send rummage in my large sack |
|||
waitforre ^You rummage through a large sack and see.+ |
|||
if % |
if %get_item1 = 1 then gosub wear item1 |
||
if %get_item2 = 1 then gosub sheath item2 |
|||
{ |
|||
if %get_item3 = 1 then gosub pack item3 |
|||
var item footwraps |
|||
gosub wear |
|||
} |
|||
if %knee_spikes = 1 then |
|||
{ |
|||
var item knee spikes |
|||
gosub wear |
|||
} |
|||
if %knuckles = 1 then |
|||
{ |
|||
var item knuckles |
|||
gosub wear |
|||
} |
|||
if %elbow_spikes = 1 then |
|||
{ |
|||
var item elbow spikes |
|||
gosub wear |
|||
} |
|||
if %stick = 1 then |
|||
{ |
|||
var item stick |
|||
gosub wear |
|||
} |
|||
if %greaves = 1 then |
|||
{ |
|||
var item greaves |
|||
gosub wear |
|||
} |
|||
if %gloves = 1 then |
|||
{ |
|||
var item gloves |
|||
gosub wear |
|||
} |
|||
if %gauntlets = 1 then |
|||
{ |
|||
var item gauntlets |
|||
gosub wear |
|||
} |
|||
if %vambraces = 1 then |
|||
{ |
|||
var item vambraces |
|||
gosub wear |
|||
} |
|||
if %coat = 1 then |
|||
{ |
|||
var item coat |
|||
gosub wear |
|||
} |
|||
if %leathers = 1 then |
|||
{ |
|||
var item leathers |
|||
gosub wear |
|||
} |
|||
if %shirt = 1 then |
|||
{ |
|||
var item shirt |
|||
gosub wear |
|||
} |
|||
if %robe = 1 then |
|||
{ |
|||
var item chain robe |
|||
gosub wear |
|||
} |
|||
if %hauberk = 1 then |
|||
{ |
|||
var item hauberk |
|||
gosub wear |
|||
} |
|||
if %breastplate = 1 then |
|||
{ |
|||
var item breastplate |
|||
gosub wear |
|||
} |
|||
if %plate = 1 then |
|||
{ |
|||
var item plate |
|||
gosub wear |
|||
} |
|||
if %armor = 1 then |
|||
{ |
|||
var item armor |
|||
gosub wear |
|||
} |
|||
if %cowl = 1 then |
|||
{ |
|||
var item cowl |
|||
gosub wear |
|||
} |
|||
if %balaclava = 1 then |
|||
{ |
|||
var item balaclava |
|||
gosub wear |
|||
} |
|||
if %helm = 1 then |
|||
{ |
|||
var item helm |
|||
gosub wear |
|||
} |
|||
if %buckler = 1 then |
|||
{ |
|||
var item buckler |
|||
gosub wear |
|||
} |
|||
if %shield = 1 then |
|||
{ |
|||
var item shield |
|||
gosub wear |
|||
} |
|||
if %longbow = 1 then |
|||
{ |
|||
var item longbow |
|||
gosub wear |
|||
} |
|||
if %ironwood_staff = 1 then |
|||
{ |
|||
var item ironwood staff |
|||
gosub wear |
|||
} |
|||
if %spear = 1 then |
|||
{ |
|||
var item spear |
|||
gosub wear |
|||
} |
|||
if %legwraps = 1 then |
|||
{ |
|||
var item legwraps |
|||
gosub pack |
|||
} |
|||
if %trousers = 1 then |
|||
{ |
|||
var item trousers |
|||
gosub wear |
|||
} |
|||
if %ironwood_greaves = 1 then |
|||
{ |
|||
var item ironwood greaves |
|||
gosub pack |
|||
} |
|||
if %ivory_greaves = 1 then |
|||
{ |
|||
var item ivory greaves |
|||
gosub pack |
|||
} |
|||
if %gold-edged_greaves = 1 then |
|||
{ |
|||
var item gold-edged greaves |
|||
gosub pack |
|||
} |
|||
if %polished_greaves = 1 then |
|||
{ |
|||
var item polished greaves |
|||
gosub pack |
|||
} |
|||
if %silver-edged_greaves = 1 then |
|||
{ |
|||
var item silver-edged greaves |
|||
gosub pack |
|||
} |
|||
if %nightstick = 1 then |
|||
{ |
|||
var item nightstick |
|||
gosub pack |
|||
} |
|||
if %bola = 1 then |
|||
{ |
|||
var item bola |
|||
gosub pack |
|||
} |
|||
if %throwing_club = 1 then |
|||
{ |
|||
var item throwing club |
|||
gosub pack |
|||
} |
|||
if %throwing_hammer = 1 then |
|||
{ |
|||
var item throwing hammer |
|||
gosub pack |
|||
} |
|||
if %bludgeon = 1 then |
|||
{ |
|||
var item bludgeon |
|||
gosub pack |
|||
} |
|||
if %chain = 1 then |
|||
{ |
|||
var item chain |
|||
gosub pack |
|||
} |
|||
if %warhammer = 1 then |
|||
{ |
|||
var item warhammer |
|||
gosub pack |
|||
} |
|||
if %morning-star = 1 then |
|||
{ |
|||
var item morning-star |
|||
gosub pack |
|||
} |
|||
if %maul = 1 then |
|||
{ |
|||
var item maul |
|||
gosub pack |
|||
} |
|||
if %mattock = 1 then |
|||
{ |
|||
var item mattock |
|||
gosub pack |
|||
} |
|||
if %baldric = 1 then |
|||
{ |
|||
var item baldric |
|||
gosub pack |
|||
} |
|||
if %halberd = 1 then |
|||
{ |
|||
var item halberd |
|||
gosub pack |
|||
} |
|||
if %skinning_knife = 1 then |
|||
{ |
|||
var item skinning knife |
|||
gosub sheath |
|||
} |
|||
if %stiletto = 1 then |
|||
{ |
|||
var item stiletto |
|||
gosub sheath |
|||
} |
|||
if %dao = 1 then |
|||
{ |
|||
var item dao |
|||
gosub sheath |
|||
} |
|||
if %flat-black_sword = 1 then |
|||
{ |
|||
var item flat-black sword |
|||
gosub sheath |
|||
} |
|||
if %jambiya = 1 then |
|||
{ |
|||
var item jambiya |
|||
gosub sheath |
|||
} |
|||
if %scimitar = 1 then |
|||
{ |
|||
var item scimitar |
|||
gosub sheath |
|||
} |
|||
if %iltesh = 1 then |
|||
{ |
|||
var item iltesh |
|||
gosub sheath |
|||
} |
|||
if %broadsword = 1 then |
|||
{ |
|||
var item broadsword |
|||
gosub sheath |
|||
} |
|||
if %blade = 1 then |
|||
{ |
|||
var item blade |
|||
gosub sheath |
|||
} |
|||
if %brushed_sword = 1 then |
|||
{ |
|||
var item brushed sword |
|||
gosub sheath |
|||
} |
|||
if %gleaming_sword = 1 then |
|||
{ |
|||
var item gleaming sword |
|||
gosub sheath |
|||
} |
|||
if %greatsword = 1 then |
|||
{ |
|||
var item greatsword |
|||
gosub sheath |
|||
} |
|||
goto empty |
goto empty |
||
wear: |
wear: |
||
var item $0 |
|||
send get %item from my large sack |
send get %item from my large sack |
||
waitforre ^You get|^What |
waitforre ^You get|^What |
||
send wear my %item |
send wear my %item |
||
matchre pack2 ^This .+ can't fit over the .+ you are already wearing|^You can't wear any more items like that |
|||
waitforre ^You|^Perhaps|^Wear|^What |
|||
matchwait 2 |
|||
return |
return |
||
sheath: |
|||
pack: |
|||
var item $0 |
|||
send get %item from my large sack |
send get %item from my large sack |
||
waitforre ^You get|^What |
waitforre ^You get|^What |
||
send put my %item in my |
send put my %item in my $sheath |
||
matchre pack2 ^There isn't any more room|^What were you referring to |
|||
waitforre ^You|^Perhaps|^Wear|^What |
|||
matchwait 2 |
|||
return |
return |
||
pack: |
|||
sheath: |
|||
var item $0 |
|||
send get %item from my large sack |
send get %item from my large sack |
||
waitforre ^You get|^What |
waitforre ^You get|^What |
||
if $charactername = Sarkranis && %item = recade then |
|||
{ |
|||
send put my %item in my $sheath |
send put my %item in my $sheath |
||
matchre pack2 ^There isn't any more room|^What were you referring to |
|||
matchwait 2 |
|||
return |
|||
} |
|||
send put my %item in my $pack |
|||
waitforre ^You|^Perhaps|^Wear|^What |
|||
return |
|||
pack2: |
|||
send put my %item in my $pack |
|||
waitforre ^You|^Perhaps|^Wear|^What |
waitforre ^You|^Perhaps|^Wear|^What |
||
return |
return |
||
empty: |
empty: |
||
send |
send rummage in my large sack |
||
waitforre ^ |
waitforre ^You rummage through a large sack but there is nothing in there |
||
send put my large sack in bucket |
send put my large sack in bucket |
||
matchre getstart ^You drop a large sack |
|||
goto get</pre> |
|||
matchwait 1 |
|||
send drop my large sack |
|||
matchre getstart ^You drop a large sack |
|||
goto getstart |
|||
return: |
|||
return |
|||
exit: |
|||
exit</pre> |
Revision as of 17:07, 6 December 2014
Repair (script) | |
---|---|
Category | utility |
Front-end | Genie |
Author | Isharon |
Description
This script submits all of the equipment that I am carrying for repair, waits until the repairs are ready, and then wears or stows the repaired items.
Feel free to use this as a template.
Syntax
.REP [REPAIRER]: repairer is the name of the NPC who does repairs in the shop you're in.
Script
if $zoneid = 1 then { put #var mrep Catrox put #var lrep Randal } if $zoneid = 4 then { put #var mrep Catrox put #var lrep Randal } if $zoneid = 40 then { put #var mrep Dagul put #var lrep Kamze } if $zoneid = 42 then { put #var mrep Dagul put #var lrep Kamze } if $zoneid = 47 then { put #var mrep Fekoeti put #var lrep Bonze } if $zoneid = 48 then { put #var mrep Fekoeti put #var lrep Bonze } if $zoneid = 66 then { put #var mrep Granzer put #var lrep Ylono } put #class racial on put #class rp on put #class combat off put #class joust off setvar check_sheath_item1 0 setvar check_sheath_item2 0 setvar check_sheath_item3 0 setvar check_pack_item1 0 setvar check_pack_item2 0 setvar check_pack_item3 0 ACTION setvar check_sheath_item1 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item1 ACTION setvar check_sheath_item2 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item2 ACTION setvar check_sheath_item3 1 WHEN ^You rummage through.+(harness|\bsheath\b).+and see.+item3 ACTION setvar check_pack_item1 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item1 ACTION setvar check_pack_item2 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item2 ACTION setvar check_pack_item3 1 WHEN ^You rummage through.+(harness|\bpack\b).+and see.+item3 send rummage in my $sheath waitforre ^You rummage through.+and see|^I could not find|^I don't know what you are referring to send rummage in my $pack waitforre ^You rummage through.+and see|^I could not find|^I don't know what you are referring to if %check_sheath_item1 = 1 then gosub gives item1 if %check_sheath_item2 = 1 then gosub gives item2 if %check_sheath_item3 = 1 then gosub gives item3 if %check_pack_item1 = 1 then gosub gives item1 if %check_pack_item2 = 1 then gosub gives item2 if %check_pack_item3 = 1 then gosub gives item3 echo ***** Now waiting for repairs to be ready. ***** goto waitrep gives: var repair $0 send get my %repair from my $sheath waitforre ^You get|^What send ask %1 about repairing all waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" send ask %1 about repairing all waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" send stow my %1 ticket waitforre ^You|^Perhaps|^Stow|^What send put my %repair in my $sheath waitforre ^You|^Perhaps|^Stow|^What pause .5 return givep: var repair $0 send get my %repair from my $pack waitforre ^You get|^What send ask %1 about repairing all waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" send ask %1 about repairing all waitforre \"There isn't a scratch on that, and I'm not one to rob you.\"|\"I will not repair something that isn't broken\.\"|Ask once more if you find these terms agreeable\.\"|Just ask me again and I can get started|My work will be complete by then\.|Please don't lose this ticket!|There is no damage to be mended\.\" send stow my %1 ticket waitforre ^You|^Perhaps|^Stow|^What send put my %repair in my $pack waitforre ^You|^Perhaps|^Stow|^What pause .5 return waitrep: pause 20 send read my %1 ticket matchre getstart repairs should be ready by now matchre exit ^What were you referring to|^I could not find what you were referring to matchwait 1 goto waitrep getstart: setvar get_item1 0 setvar get_item2 0 setvar get_item3 0 ACTION setvar get_item1 1 WHEN ^You rummage through a large sack and see.+item1 ACTION setvar get_item2 1 WHEN ^You rummage through a large sack and see.+item2 ACTION setvar get_item3 1 WHEN ^You rummage through a large sack and see.+item3 send get my %1 ticket waitforre ^You get|^You are already pause send give %1 waitforre ^You hand send swap waitforre ^You move send rummage in my large sack waitforre ^You rummage through a large sack and see.+ if %get_item1 = 1 then gosub wear item1 if %get_item2 = 1 then gosub sheath item2 if %get_item3 = 1 then gosub pack item3 goto empty wear: var item $0 send get %item from my large sack waitforre ^You get|^What send wear my %item matchre pack2 ^This .+ can't fit over the .+ you are already wearing|^You can't wear any more items like that matchwait 2 return sheath: var item $0 send get %item from my large sack waitforre ^You get|^What send put my %item in my $sheath matchre pack2 ^There isn't any more room|^What were you referring to matchwait 2 return pack: var item $0 send get %item from my large sack waitforre ^You get|^What if $charactername = Sarkranis && %item = recade then { send put my %item in my $sheath matchre pack2 ^There isn't any more room|^What were you referring to matchwait 2 return } send put my %item in my $pack waitforre ^You|^Perhaps|^Wear|^What return pack2: send put my %item in my $pack waitforre ^You|^Perhaps|^Wear|^What return empty: send rummage in my large sack waitforre ^You rummage through a large sack but there is nothing in there send put my large sack in bucket matchre getstart ^You drop a large sack matchwait 1 send drop my large sack matchre getstart ^You drop a large sack goto getstart return: return exit: exit