/*%FSM*/ /*%FSM*/ /* item0[] = {"hover",0,250,50.000000,-225.000000,150.000000,-175.000000,0.000000,"hover"}; item1[] = {"check",2,250,50.000000,-25.000000,150.000000,25.000000,0.000000,"check"}; item2[] = {"teleport",2,250,200.000000,75.000000,300.000000,125.000000,0.000000,"teleport"}; item3[] = {"done",4,218,200.000000,-125.000000,300.000000,-75.000000,0.000000,"done"}; item4[] = {"arrived",4,218,50.000000,75.000000,150.000000,125.000000,20.000000,"arrived"}; item5[] = {"end",1,250,200.000000,-225.000000,300.000000,-175.000000,0.000000,"end"}; item6[] = {"fly",4,4314,200.000000,-25.000000,300.000000,25.000000,10.000000,"fly"}; item7[] = {"wait",4,218,50.000000,-125.000000,150.000000,-75.000000,0.000000,"wait"}; link0[] = {0,7}; link1[] = {1,4}; link2[] = {1,6}; link3[] = {2,3}; link4[] = {3,5}; link5[] = {4,2}; link6[] = {6,1}; link7[] = {7,1}; globals[] = {25.000000,1,0,0,16777215,640,480,1,269,6316128,1,-183.182861,521.735474,304.026001,-397.056030,735,895,1}; window[] = {2,-1,-1,-1,-1,700,1775,2800,175,3,753}; *//*%FSM*/ class FSM { fsmName = "cloak hover"; class States { /*%FSM*/ class hover { name = "hover"; init = /*%FSM*/"_unit = _this select 0;" \n "_trgt = _this select 1;" \n "_t = diag_tickTime;" \n "_unit setUnitPos ""UP""; " \n "" \n "" \n "_cloakDirTo = [_unit, _trgt] call BIS_fnc_dirTo;" \n "_unit setDir _cloakDirTo;" \n "" \n "_unit say3D ""cultist_laugh"";" \n "EPOCH_say3D_PVS = [player, _unit, 8,Epoch_personalToken];" \n "publicVariableServer ""EPOCH_say3D_PVS"";" \n "" \n "" \n "" \n ""/*%FSM*/; precondition = /*%FSM*/""/*%FSM*/; class Links { /*%FSM*/ class wait { priority = 0.000000; to="check"; precondition = /*%FSM*/""/*%FSM*/; condition=/*%FSM*/"diag_tickTime - _t > 0.75"/*%FSM*/; action=/*%FSM*/"_t = diag_tickTime;"/*%FSM*/; }; /*%FSM*/ }; }; /*%FSM*/ /*%FSM*/ class check { name = "check"; init = /*%FSM*/"_dist = _trgt distance _unit;" \n "_height = (getPosATL _trgt) select 2;"/*%FSM*/; precondition = /*%FSM*/""/*%FSM*/; class Links { /*%FSM*/ class arrived { priority = 20.000000; to="teleport"; precondition = /*%FSM*/""/*%FSM*/; condition=/*%FSM*/"(getPosATL _unit select 2) > _height || _dist < 1.5;" \n ""/*%FSM*/; action=/*%FSM*/""/*%FSM*/; }; /*%FSM*/ /*%FSM*/ class fly { priority = 10.000000; to="check"; precondition = /*%FSM*/""/*%FSM*/; condition=/*%FSM*/""/*%FSM*/; action=/*%FSM*/"" \n "_arr = [getPosASL _unit, getPosASL _trgt, velocity _unit, velocity _trgt, vectorDir _unit, vectorDir _unit, vectorUp _unit, vectorUp _trgt, 0.1];" \n "_unit setVelocityTransformation _arr;" \n "" \n "" \n "_t = diag_tickTime;" \n "" \n "//systemchat format [""fly: %1"",getPosATL _unit];"/*%FSM*/; }; /*%FSM*/ }; }; /*%FSM*/ /*%FSM*/ class teleport { name = "teleport"; init = /*%FSM*/"[_unit, _trgt] execFSM ""\x\addons\a3_epoch_code\System\cloakTeleport.fsm"";"/*%FSM*/; precondition = /*%FSM*/""/*%FSM*/; class Links { /*%FSM*/ class done { priority = 0.000000; to="end"; precondition = /*%FSM*/""/*%FSM*/; condition=/*%FSM*/""/*%FSM*/; action=/*%FSM*/""/*%FSM*/; }; /*%FSM*/ }; }; /*%FSM*/ /*%FSM*/ class end { name = "end"; init = /*%FSM*/""/*%FSM*/; precondition = /*%FSM*/""/*%FSM*/; class Links { }; }; /*%FSM*/ }; initState="hover"; finalStates[] = { "end", }; }; /*%FSM*/