mirror of
https://github.com/EpochModTeam/Epoch.git
synced 2024-08-30 18:22:13 +00:00
290 lines
12 KiB
Plaintext
290 lines
12 KiB
Plaintext
|
/*%FSM<COMPILE "X:\ArmA\Tools\FSM Editor Personal Edition\scriptedFSM.cfg, Gender Selection">*/
|
||
|
/*%FSM<HEAD>*/
|
||
|
/*
|
||
|
item0[] = {"INIT",0,250,-250.000000,-150.000000,-150.000000,-100.000000,0.000000,"INIT"};
|
||
|
item1[] = {"Respone",4,218,-500.000000,300.000000,-400.000000,350.000000,0.000000,"Respone"};
|
||
|
item2[] = {"true",8,218,-250.000000,-75.000000,-150.000000,-25.000000,0.000000,"true"};
|
||
|
item3[] = {"Open_Gender_Selection",2,250,-400.000000,-75.000000,-300.000000,-25.000000,0.000000,"Open Gender" \n "Selection Dialog"};
|
||
|
item4[] = {"Reopen_when_client",4,218,-400.000000,-150.000000,-300.000000,-100.000000,0.000000,"Reopen" \n "when client hit" \n "escape"};
|
||
|
item5[] = {"Gender_Selected",4,218,-450.000000,0.000000,-350.000000,50.000000,10.000000,"Gender" \n "Selected"};
|
||
|
item6[] = {"Timeout",4,218,-350.000000,0.000000,-250.000000,50.000000,0.000000,"Timeout"};
|
||
|
item7[] = {"Process",2,250,-400.000000,75.000000,-300.000000,125.000000,0.000000,"Process"};
|
||
|
item8[] = {"same_gender",4,218,-250.000000,75.000000,-150.000000,125.000000,10.000000,"same" \n "gender"};
|
||
|
item9[] = {"other_gender",4,218,-400.000000,150.000000,-300.000000,200.000000,0.000000,"other" \n "gender"};
|
||
|
item10[] = {"Send_To_Server",3,250,-125.000000,75.000000,-25.000000,125.000000,0.000000,"Send To Server"};
|
||
|
item11[] = {"TODO__ADD_TIMEOUT",4,4314,-275.000000,250.000000,-175.000000,300.000000,0.000000,"TODO:" \n "ADD TIMEOUT" \n "AND LOBBY KICK"};
|
||
|
item12[] = {"END",1,250,0.000000,450.000000,100.000000,500.000000,0.000000,"END"};
|
||
|
item13[] = {"Send_new_selection",2,250,-400.000000,250.000000,-300.000000,300.000000,0.000000,"Send new" \n "selection to" \n "server"};
|
||
|
item14[] = {"Select_Model",2,250,-400.000000,350.000000,-300.000000,400.000000,0.000000,"Select Model"};
|
||
|
item15[] = {"new_model____pla",4,218,-525.000000,400.000000,-425.000000,450.000000,0.000000,"new model" \n "==" \n "player"};
|
||
|
item16[] = {"Setup_EH",2,250,-400.000000,450.000000,-300.000000,500.000000,0.000000,"Setup EH"};
|
||
|
item17[] = {"true",8,218,-125.000000,450.000000,-25.000000,500.000000,0.000000,"true"};
|
||
|
item18[] = {"____FAKE____",9,720,0.000000,0.000000,0.000000,0.000000,0.000000,"____FAKE____"};
|
||
|
link0[] = {0,2};
|
||
|
link1[] = {1,14};
|
||
|
link2[] = {2,3};
|
||
|
link3[] = {3,4};
|
||
|
link4[] = {3,5};
|
||
|
link5[] = {3,6};
|
||
|
link6[] = {4,3};
|
||
|
link7[] = {5,7};
|
||
|
link8[] = {6,7};
|
||
|
link9[] = {7,8};
|
||
|
link10[] = {7,9};
|
||
|
link11[] = {8,10};
|
||
|
link12[] = {9,13};
|
||
|
link13[] = {10,17};
|
||
|
link14[] = {13,1};
|
||
|
link15[] = {13,11};
|
||
|
link16[] = {14,15};
|
||
|
link17[] = {15,16};
|
||
|
link18[] = {16,17};
|
||
|
link19[] = {17,12};
|
||
|
link20[] = {11,18};
|
||
|
globals[] = {25.000000,1,0,0,0,640,480,1,250,6316128,1,-786.968628,194.189285,571.765747,-266.728790,1066,911,1};
|
||
|
window[] = {2,-1,-1,-1,-1,753,25,1063,25,3,1084};
|
||
|
*//*%FSM</HEAD>*/
|
||
|
class FSM
|
||
|
{
|
||
|
fsmName = "Gender Selection";
|
||
|
class States
|
||
|
{
|
||
|
/*%FSM<STATE "INIT">*/
|
||
|
class INIT
|
||
|
{
|
||
|
name = "INIT";
|
||
|
init = /*%FSM<STATEINIT""">*/"titleCut ["""", ""BLACK FADED"", 1337];" \n
|
||
|
"0 fadeSound 0;" \n
|
||
|
"EPOCH_PlayerIsMale = nil;" \n
|
||
|
"" \n
|
||
|
"_myGenderTime = diag_tickTime;"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "true">*/
|
||
|
class true
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Open_Gender_Selection";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Open_Gender_Selection">*/
|
||
|
class Open_Gender_Selection
|
||
|
{
|
||
|
name = "Open_Gender_Selection";
|
||
|
init = /*%FSM<STATEINIT""">*/"createdialog ""SelectGender"";"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "Gender_Selected">*/
|
||
|
class Gender_Selected
|
||
|
{
|
||
|
priority = 10.000000;
|
||
|
to="Process";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"!isNil ""EPOCH_PlayerIsMale"""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
/*%FSM<LINK "Timeout">*/
|
||
|
class Timeout
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Process";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _myGenderTime) > 30)"/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/"EPOCH_PlayerIsMale = true;" \n
|
||
|
"closeDialog 0;"/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
/*%FSM<LINK "Reopen_when_client">*/
|
||
|
class Reopen_when_client
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Open_Gender_Selection";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"!dialog && isNil ""EPOCH_PlayerIsMale"""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Process">*/
|
||
|
class Process
|
||
|
{
|
||
|
name = "Process";
|
||
|
init = /*%FSM<STATEINIT""">*/"_model = ""Epoch_Female_F"";" \n
|
||
|
"if (EPOCH_PlayerIsMale) then {" \n
|
||
|
" _model = ""Epoch_Male_F"";" \n
|
||
|
"};" \n
|
||
|
"" \n
|
||
|
"_currModel = typeOf player;"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "same_gender">*/
|
||
|
class same_gender
|
||
|
{
|
||
|
priority = 10.000000;
|
||
|
to="Send_To_Server";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"_currModel == _model"/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
/*%FSM<LINK "other_gender">*/
|
||
|
class other_gender
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Send_new_selection";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"_currModel != _model"/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Send_To_Server">*/
|
||
|
class Send_To_Server
|
||
|
{
|
||
|
name = "Send_To_Server";
|
||
|
init = /*%FSM<STATEINIT""">*/"EPOCH_respawnPlayer_PVS = [player, Epoch_personalToken];" \n
|
||
|
"publicVariableServer ""EPOCH_respawnPlayer_PVS"";"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "true">*/
|
||
|
class true
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="END";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "END">*/
|
||
|
class END
|
||
|
{
|
||
|
name = "END";
|
||
|
init = /*%FSM<STATEINIT""">*/"titleCut ["""", ""BLACK IN"", 1];" \n
|
||
|
""/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Send_new_selection">*/
|
||
|
class Send_new_selection
|
||
|
{
|
||
|
name = "Send_new_selection";
|
||
|
init = /*%FSM<STATEINIT""">*/"EPOCH_respawnPlayer_PVS = [player, Epoch_personalToken,EPOCH_PlayerIsMale];" \n
|
||
|
"publicVariableServer ""EPOCH_respawnPlayer_PVS"";"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "TODO__ADD_TIMEOUT">*/
|
||
|
class TODO__ADD_TIMEOUT
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="____FAKE____";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"false"/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
/*%FSM<LINK "Respone">*/
|
||
|
class Respone
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Select_Model";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"!isNil ""EPOCH_switchPlayer_PVC"""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/"_playerObject = EPOCH_switchPlayer_PVC;" \n
|
||
|
"EPOCH_switchPlayer_PVC = nil;"/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Select_Model">*/
|
||
|
class Select_Model
|
||
|
{
|
||
|
name = "Select_Model";
|
||
|
init = /*%FSM<STATEINIT""">*/"_oldModel = player;" \n
|
||
|
"selectPlayer _playerObject;" \n
|
||
|
"deleteVehicle _oldModel;"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "new_model____pla">*/
|
||
|
class new_model____pla
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="Setup_EH";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/"_playerObject == player"/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "Setup_EH">*/
|
||
|
class Setup_EH
|
||
|
{
|
||
|
name = "Setup_EH";
|
||
|
init = /*%FSM<STATEINIT""">*/"player addEventHandler [""Respawn"", {(_this select 0) call EPOCH_clientRespawn}];" \n
|
||
|
"player addEventHandler [""Put"", {(_this select 1) call EPOCH_interact;_this call EPOCH_PutHandler}];" \n
|
||
|
"player addEventHandler [""Take"", {(_this select 1) call EPOCH_interact;_this call EPOCH_UnisexCheck}];" \n
|
||
|
"player addEventHandler [""InventoryClosed"", {if !(EPOCH_arr_interactedObjs isEqualTo[]) then {EPOCH_arr_interactedObjs remoteExec[""EPOCH_server_save_vehicles"", 2]; EPOCH_arr_interactedObjs = [];};}];" \n
|
||
|
"player addEventHandler [""InventoryOpened"", {_this spawn EPOCH_initUI; (locked (_this select 1) in [2, 3])}];" \n
|
||
|
"player addEventHandler [""Fired"", {_this call EPOCH_fnc_playerFired}];" \n
|
||
|
"player addEventHandler [""Killed"", {_this call EPOCH_fnc_playerDeath}];"/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
/*%FSM<LINK "true">*/
|
||
|
class true
|
||
|
{
|
||
|
priority = 0.000000;
|
||
|
to="END";
|
||
|
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||
|
condition=/*%FSM<CONDITION""">*/""/*%FSM</CONDITION""">*/;
|
||
|
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||
|
};
|
||
|
/*%FSM</LINK>*/
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
/*%FSM<STATE "____FAKE____">*/
|
||
|
class ____FAKE____
|
||
|
{
|
||
|
name = "____FAKE____";
|
||
|
init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/;
|
||
|
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||
|
class Links
|
||
|
{
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</STATE>*/
|
||
|
};
|
||
|
initState="INIT";
|
||
|
finalStates[] =
|
||
|
{
|
||
|
"END"
|
||
|
};
|
||
|
};
|
||
|
/*%FSM</COMPILE>*/
|