metas/bore.af
2025-04-11 21:36:28 +02:00

258 lines
No EOL
12 KiB
Text

~~ {
~~ FOR AUTO-COMPLETION ASSISTANCE: testvar getvar setvar touchvar clearallvars clearvar getcharintprop getchardoubleprop getcharquadprop getcharboolprop getcharstringprop getisspellknown getcancastspell_hunt getcancastspell_buff getcharvital_base getcharvital_current getcharvital_buffedmax getcharskill_traininglevel getcharskill_base getcharskill_buffed getplayerlandcell getplayercoordinates coordinategetns coordinategetwe coordinategetz coordinatetostring coordinateparse coordinatedistancewithz coordinatedistanceflat wobjectgetphysicscoordinates wobjectgetname wobjectgetobjectclass wobjectgettemplatetype wobjectgetisdooropen wobjectfindnearestmonster wobjectfindnearestdoor wobjectfindnearestbyobjectclass wobjectfindininventorybytemplatetype wobjectfindininventorybyname wobjectfindininventorybynamerx wobjectgetselection wobjectgetplayer wobjectfindnearestbynameandobjectclass actiontryselect actiontryuseitem actiontryapplyitem actiontrygiveitem actiontryequipanywand actiontrycastbyid actiontrycastbyidontarget chatbox chatboxpaste statushud statushudcolored uigetcontrol uisetlabel isfalse istrue iif randint cstr strlen getobjectinternaltype cstrf stopwatchcreate stopwatchstart stopwatchstop stopwatchelapsedseconds cnumber floor ceiling round abs getworldname getitemcountininventorybyname getheading getitemcountininventorybynamerx getheadingto actiontrygiveprofile vitae getfellowshipstatus getfellowshipname getfellowshipisopen getfellowshipisleader getfellowshipleaderid getfellowshipcanrecruit getfellowid getfellowshipcount getfellowshiplocked getfellowname getfellowshipisfull sin cos tan sqrt asin acos atan atan2 sinh cosh tanh vtsetmetastate getregexmatch echo chr ord wobjectgetid wobjectgethealth wobjectfindbyid wobjectgetintprop wobjectfindnearestbytemplatetype wobjectgetopencontainer testquestflag getquestktprogress isrefreshingquests getquestktrequired getqueststatus getisday getgamehour getgamehourname getisnight getgameday getgameticks getminutesuntilday getgamemonth getgamemonthname getminutesuntilnight getgameyear uisetvisible uiviewvisible uiviewexists getgvar touchgvar getpvar touchpvar setgvar cleargvar setpvar clearpvar testgvar clearallgvars testpvar clearallpvars dictgetitem dictcreate dicthaskey dictadditem dictkeys dictremovekey dictvalues dictclear dictsize dictcopy listgetitem listpop listcreate listcontains listremove listadd listindexof listremoveat listinsert listlastindexof listclear listcopy listcount listreverse
~~
~~ File auto-generated by metaf, a program created by Eskarina of Morningthaw/Coldeve.
~~ Get metaf here: https://github.com/JJEII/metaf/
~~
~~ All recognized structural designators:
~~ STATE: DO:
~~ IF: NAV:
~~
~~ All recognized CONDITION (IF:) operation keywords:
~~ Never NavEmpty MobsInDist_Priority Not
~~ Always Death NeedToBuff PSecsInStateGE
~~ All VendorOpen NoMobsInDist SecsOnSpellGE
~~ Any VendorClosed BlockE BuPercentGE
~~ ChatMatch ItemCountLE CellE DistToRteGE
~~ MainSlotsLE ItemCountGE IntoPortal Expr
~~ SecsInStateGE MobsInDist_Name ExitPortal ChatCapture
~~
~~ All recognized ACTION (DO:) operation keywords:
~~ None EmbedNav ChatExpr SetOpt
~~ SetState CallState SetWatchdog CreateView
~~ Chat Return ClearWatchdog DestroyView
~~ DoAll DoExpr GetOpt DestroyAllViews
~~
~~ All recognized NAV types:
~~ circular follow
~~ linear once
~~
~~ All recognized NAV NODE types:
~~ flw vnd
~~ pnt ptl
~~ rcl tlk
~~ pau chk
~~ cht jmp
~~ prt (deprecated in VTank)
~~ }
~~ /ub mexec setvar[navNumber,VILKETNUMMER]
STATE: {combat} ~~ {
IF: Always
DO: Chat {/vt opt set enablecombat true}
IF: SecsInStateGE 60
DO: SetState {ring_fail}
IF: NoMobsInDist 5
DO: SetState {hunt}
~~ }
STATE: {death} ~~ {
IF: Always
DO: Chat {/vt nav load death_pause}
IF: Always
DO: Chat {/vt opt set enablenav true}
IF: NavEmpty
DO: SetState {navbore}
~~ }
STATE: {hunt} ~~ {
IF: Always
DO: Chat {/vt opt set enablecombat false}
IF: Expr {getvar[lootTime] == 0}
DO: DoExpr {setvar[lootTime, 21600]}
IF: Death
DO: DoAll
Chat {/a I died! But I will comeback!}
SetState {death}
IF: All
ItemCountLE 100 {Prismatic Taper}
NoMobsInDist 5
DO: DoAll
Chat {/fellowship Out of tapers! Recomping.}
SetState {recomp}
IF: Always
DO: SetWatchdog 3 120 {stuck}
IF: Always
DO: SetWatchdog 3 600 {really_stuck}
IF: DistToRteGE 1000
DO: SetState {really_stuck}
IF: All
Expr {coordinatedistancewithz[getplayercoordinates[], wobjectgetphysicscoordinates[wobjectfindnearestbyobjectclass[14]]]<=4}
Not Expr {wobjectgetname[wobjectfindnearestbyobjectclass[14]]==Singularity Caul}
DO: DoAll
ChatExpr {\/me is to close to +wobjectgetname[wobjectfindnearestbyobjectclass[14]]}
ChatExpr {\/me at +coordinatetostring[getplayercoordinates[]]}
IF: All
Any
Expr {getvar[mobsClose] == 0}
Expr {getvar[mobsClose] == 1}
MobsInDist_Name 1 6 {}
DO: SetState {combat}
IF: All
Expr {getvar[mobsClose] == 2}
MobsInDist_Name 2 6 {}
DO: SetState {combat}
IF: All
Expr {stopwatchelapsedseconds[getvar[lootclock]]>getvar[lootTime]}
DO: DoAll
Chat {/vt opt set enablecombat true}
SetState {loot}
IF: All
Expr {setvar[portal, wobjectfindnearestbyobjectclass[14]]}
Expr {coordinatedistancewithz[getplayercoordinates[], wobjectgetphysicscoordinates[getvar[portal]]] <= 8}
Not Expr {wobjectgetname[wobjectfindnearestbyobjectclass[14]]==Singularity Caul}
Not Expr {wobjectgetname[wobjectfindnearestbyobjectclass[14]]#Destroyed.*}
Expr {wobjectisvalid[getvar[portal]]}
Expr {setvar[portalHeading, getheadingto[getvar[portal]]]}
Expr {setvar[playerHeading, getheading[wobjectgetplayer[]]]}
Expr {setvar[relativeAngle, abs[getvar[portalHeading] - getvar[playerHeading]]]}
Expr {setvar[relativeAngle, iif[getvar[relativeAngle] > 180, 360 - getvar[relativeAngle], getvar[relativeAngle]]]}
Expr {setvar[turnDirection, iif[randint[0,2] == 0, -90, 90]]}
Expr {getvar[relativeAngle] <= 11.25}
Expr {setvar[newHeading, abs[getvar[playerHeading] + getvar[turnDirection]]]}
DO: DoAll
Chat {/vt opt set enablenav false}
Chat {/vt opt set enablecombat false}
SetState {avoid_portal}
~~ }
STATE: {loot_rare} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablelooting true}
Chat {/vt opt set enablenav false}
IF: SecsInStateGE 30
DO: DoAll
Chat {/vt opt set enablelooting false}
Chat {/vt opt set enablenav true}
SetState {hunt}
~~ }
STATE: {Default} ~~ {
IF: Always
DO: DoAll
Chat {/ub opt set VTank.PatchExpressionEngine true}
ChatExpr {\/vt nav load bore_circuit+getvar[navNumber]}
Chat {/vt opt set enablenav true}
Chat {/vt opt set buffprofile_prots 2}
Chat {/vt opt set buffprofile_banes 5}
Chat {/vt opt set enablelooting false}
Chat {/vt opt set navpriorityboost false}
Chat {/vt opt set lootpriorityboost true}
Chat {/vt opt set lootonlyrarecorpses true}
DoExpr {setvar[lootclock,stopwatchcreate[]]}
DoExpr {stopwatchstart[getvar[lootclock]]}
SetState {hunt}
~~ }
STATE: {avoid_portal} ~~ {
IF: SecsInStateGE 1
DO: ChatExpr {\/me portalHeading \= +getvar[portalHeading]}
IF: SecsInStateGE 2
DO: ChatExpr {\/me playerHeading \= +getvar[playerHeading]}
IF: SecsInStateGE 3
DO: ChatExpr {\/me relativeAngle \= +getvar[relativeAngle]}
IF: SecsInStateGE 4
DO: ChatExpr {\/me Portal detected ahead\! Avoiding now\!}
IF: SecsInStateGE 5
DO: ChatExpr {\/me is too close to +wobjectgetname[wobjectfindnearestbyobjectclass[14]]}
IF: SecsInStateGE 6
DO: ChatExpr {\/me at +coordinatetostring[getplayercoordinates[]]}
IF: SecsInStateGE 7
DO: ChatExpr {\/ub face +getvar[newHeading]}
IF: SecsInStateGE 9
DO: ChatExpr {\/ub setmotion forward 1}
IF: SecsInStateGE 11
DO: ChatExpr {\/ub setmotion forward 0}
IF: SecsInStateGE 12
DO: ChatExpr {\/ub face +getvar[playerHeading]}
IF: SecsInStateGE 14
DO: ChatExpr {\/ub setmotion forward 1}
IF: SecsInStateGE 16
DO: ChatExpr {\/ub setmotion forward 0}
IF: SecsInStateGE 17
DO: ChatExpr {\/vt opt set enablenav true}
IF: SecsInStateGE 18
DO: ChatExpr {\/vt setmetastate hunt}
~~ }
STATE: {navbore} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablecombat false}
IF: Always
DO: ChatExpr {\/vt nav load bore_route+getvar[navNumber]}
IF: Always
DO: Chat {/vt opt set enablebuffing true}
IF: Always
DO: SetWatchdog 3 300 {navbore}
IF: NavEmpty
DO: DoAll
ChatExpr {\/vt nav load bore_circuit+getvar[navNumber]}
SetState {hunt}
~~ }
STATE: {really_stuck} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablecombat false}
SetState {navbore}
Chat {/a Help me Jeebus, i'm in whirlwind of vortexes}
~~ }
STATE: {recomp} ~~ {
IF: NavEmpty
DO: SetState {navbore}
IF: Always
DO: SetWatchdog 3 300 {navbore}
IF: Always
DO: DoAll
Chat {/vt opt set enablecombat false}
Chat {/vt opt set enablebuffing false}
Chat {/vt nav load ah_recomp}
~~ }
STATE: {ring_fail} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablecombat false}
SetWatchdog 100 3 {hunt}
~~ }
STATE: {stuck} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablenav false}
Chat {/vt reverseroute}
ChatExpr {\/vt nav load bore_circuit+getvar[navNumber]}
Chat {/vt opt set enablenav true}
SetState {hunt}
~~ }
STATE: {loot} ~~ {
IF: Always
DO: DoAll
Chat {/vt opt set enablelooting true}
Chat {/vt opt set lootonlyrarecorpses false}
Chat {/vt opt set lootpriorityboost false}
IF: SecsInStateGE 300
DO: DoAll
Chat {/vt opt set lootonlyrarecorpses true}
Chat {/vt opt set lootpriorityboost true}
Chat {/vt opt set enablelooting false}
DoExpr {setvar[lootclock,stopwatchcreate[]]}
DoExpr {stopwatchstart[getvar[lootclock]]}
SetState {hunt}
IF: All
Expr {setvar[portal, wobjectfindnearestbyobjectclass[14]]}
Expr {coordinatedistancewithz[getplayercoordinates[], wobjectgetphysicscoordinates[getvar[portal]]] <= 8}
Not Expr {wobjectgetname[wobjectfindnearestbyobjectclass[14]]==Singularity Caul}
Not Expr {wobjectgetname[wobjectfindnearestbyobjectclass[14]]#Destroyed.*}
Expr {wobjectisvalid[getvar[portal]]}
Expr {setvar[portalHeading, getheadingto[getvar[portal]]]}
Expr {setvar[playerHeading, getheading[wobjectgetplayer[]]]}
Expr {setvar[relativeAngle, abs[getvar[portalHeading] - getvar[playerHeading]]]}
Expr {setvar[relativeAngle, iif[getvar[relativeAngle] > 180, 360 - getvar[relativeAngle], getvar[relativeAngle]]]}
Expr {setvar[turnDirection, iif[randint[0,2] == 0, -90, 90]]}
Expr {getvar[relativeAngle] <= 11.25}
Expr {setvar[newHeading, abs[getvar[playerHeading] + getvar[turnDirection]]]}
DO: DoAll
Chat {/vt opt set enablenav false}
Chat {/vt opt set lootonlyrarecorpses true}
Chat {/vt opt set lootpriorityboost true}
Chat {/vt opt set enablelooting false}
DoExpr {setvar[lootclock,stopwatchcreate[]]}
DoExpr {stopwatchstart[getvar[lootclock]]}
SetState {avoid_portal}
~~ }