~~ { ~~ 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) ~~ } STATE: {Default} ~~ { IF: Death DO: SetState {death} IF: Always DO: DoAll Chat {/ub opt set VTank.PatchExpressionEngine true} SetOpt {enablecombat} {false} SetOpt {enablenav} {true} SetOpt {enablelooting} {false} SetOpt {enablebuffing} {true} SetOpt {attackdistance} {0.0125} Chat {/vt nav load nav_nalicana} SetState {talk_nalicana} ~~ } STATE: {talk_nalicana} ~~ { IF: Death DO: SetState {death} IF: All Expr {testvar[navLoaded]} NavEmpty DO: DoAll ClearWatchdog Chat {/ub use Nalicana} SetState {wait_nalicana_dialog} IF: Always DO: DoAll DoExpr {touchvar[navLoaded]} SetWatchdog 10 300 {stuck} ~~ } STATE: {wait_nalicana_dialog} ~~ { IF: Death DO: SetState {death} IF: ChatMatch {Gurog have emerged} DO: DoAll DoExpr {echo[`Got quest from Nalicana!`,1]} SetState {nav_to_cave} IF: ChatMatch {You have solved this quest too recently} DO: DoAll DoExpr {echo[`Quest on cooldown!`,1]} SetState {done} IF: SecsInStateGE 10 DO: SetState {nav_to_cave} ~~ } STATE: {nav_to_cave} ~~ { IF: Death DO: SetState {death} IF: All Expr {testvar[navLoaded2]} NavEmpty DO: DoAll ClearWatchdog SetOpt {enablecombat} {true} SetOpt {enablelooting} {true} SetState {wait_key} IF: Always DO: DoAll DoExpr {touchvar[navLoaded2]} Chat {/vt nav load nal_to_cave} SetWatchdog 10 600 {stuck} ~~ } STATE: {wait_key} ~~ { IF: Death DO: SetState {death} IF: ItemCountGE 1 {Entryway Key} DO: DoAll DoExpr {echo[`Got Entryway Key!`,1]} Chat {/ub use Entryway Key on Door} SetState {wait_door} IF: SecsInStateGE 120 DO: DoAll DoExpr {echo[`Key taking too long...`,1]} SetState {wait_key} ~~ } STATE: {wait_door} ~~ { IF: Death DO: SetState {death} IF: ChatMatch {Door has been unlocked} DO: DoAll DoExpr {echo[`Door opened!`,1]} SetOpt {enablecombat} {false} SetOpt {enablelooting} {false} SetState {nav_to_tomb_portal} IF: SecsInStateGE 5 DO: DoAll Chat {/ub use Entryway Key on Door} SetState {wait_door} ~~ } STATE: {nav_to_tomb_portal} ~~ { IF: Death DO: SetState {death} IF: All Expr {testvar[navLoaded3]} NavEmpty DO: DoAll ClearWatchdog SetState {enter_frozen_tomb} IF: Always DO: DoAll DoExpr {touchvar[navLoaded3]} Chat {/vt nav load nal_to_tomb_portal} SetWatchdog 10 300 {stuck} ~~ } STATE: {enter_frozen_tomb} ~~ { IF: Death DO: SetState {death} IF: ExitPortal DO: DoAll DoExpr {echo[`Inside Frozen Tomb!`,1]} SetOpt {enablecombat} {true} SetState {dungeon_run} IF: SecsInStateGE 10 DO: DoAll SetOpt {enablecombat} {true} SetState {dungeon_run} ~~ } STATE: {dungeon_run} ~~ { IF: Death DO: SetState {death} IF: All Expr {testvar[navLoaded4]} NavEmpty DO: DoAll ClearWatchdog SetOpt {enablelooting} {true} SetState {kill_gregor} IF: Always DO: DoAll DoExpr {touchvar[navLoaded4]} Chat {/vt nav load nal_dungeon_run} SetOpt {enablelooting} {false} SetWatchdog 10 600 {stuck} ~~ } STATE: {kill_gregor} ~~ { IF: Death DO: SetState {death} IF: ChatMatch {Killing me will not change anything} DO: DoAll DoExpr {echo[`Battle Lord Gregor defeated!`,1]} SetOpt {enablecombat} {false} SetState {wait_loot} IF: ItemCountGE 1 {Battle Lord Gregor's Mnemosyne} DO: DoAll DoExpr {echo[`Got the Mnemosyne!`,1]} SetOpt {enablecombat} {false} SetOpt {enablelooting} {false} SetState {return_nalicana} IF: SecsInStateGE 600 DO: DoAll DoExpr {echo[`Gregor fight timeout!`,1]} SetState {stuck} ~~ } STATE: {wait_loot} ~~ { IF: Death DO: SetState {death} IF: ItemCountGE 1 {Battle Lord Gregor's Mnemosyne} DO: DoAll DoExpr {echo[`Got the Mnemosyne! Returning to Nalicana.`,1]} SetOpt {enablelooting} {false} SetState {return_nalicana} IF: SecsInStateGE 30 DO: DoAll DoExpr {echo[`Mnemosyne not looted, check loot profile!`,1]} SetOpt {enablelooting} {false} SetState {return_nalicana} ~~ } STATE: {return_nalicana} ~~ { IF: Death DO: SetState {death} IF: All Expr {testvar[navLoaded5]} NavEmpty DO: DoAll ClearWatchdog SetState {turn_in} IF: Always DO: DoAll DoExpr {touchvar[navLoaded5]} Chat {/vt nav load nav_nalicana} SetWatchdog 10 600 {stuck} ~~ } STATE: {turn_in} ~~ { IF: Death DO: SetState {death} IF: Always DO: DoAll Chat {/ub givep Battle Lord Gregor's Mnemosyne to Nalicana} Chat {/ub prepclick yes 3} SetState {wait_turn_in} ~~ } STATE: {wait_turn_in} ~~ { IF: Death DO: SetState {death} IF: ChatMatch {Lord Asheron should be able to learn much} DO: DoAll DoExpr {echo[`Nalicana's Test COMPLETE!`,1]} SetState {done} IF: SecsInStateGE 10 DO: SetState {turn_in} ~~ } STATE: {done} ~~ { IF: Always DO: DoAll DoExpr {echo[`Nalicana's Test quest finished.`,1]} Chat {/mp} ~~ } STATE: {stuck} ~~ { IF: Death DO: SetState {death} IF: Always DO: DoAll Chat {/ub face} DoExpr {echo[`Stuck! Check nav...`,1]} ~~ } STATE: {death} ~~ { IF: ExitPortal DO: DoAll DoExpr {echo[`Died! Restarting...`,1]} SetState {Default} ~~ }