Make zombie_agent.fsm customizable for admins #1877

Also fixed HandleDamage EH was added twice. We moved it to the configs
and forgot to take it out of the FSM in 6853263.
This commit is contained in:
ebaydayz
2017-02-01 20:36:00 -05:00
parent 6aa5c9b64f
commit 097a02b19a
8 changed files with 19 additions and 18 deletions

View File

@@ -140,9 +140,6 @@ class FSM
"_bodyStay = 60;" \n
"" \n
"_timeN = time;" \n
"" \n
" _id = _agent addeventhandler [""HandleDamage"",{_this call local_zombieDamage}];" \n
"" \n
"//hint ""run local zombie"";" \n
"_isSomeone = true;" \n
"" \n

View File

@@ -211,11 +211,11 @@ class FSM
class init
{
name = "init";
init = /*%FSM<STATEINIT""">*/"_agent = _this select 0;" \n
init = /*%FSM<STATEINIT""">*/"_agent = _this select 1; //Compatible with old configs like Namalsk's custom zombies" \n
"_position = _agent modelToWorld [0,0,0];" \n
"_secondHand = false;" \n
"" \n
"if (count _this > 1) then {" \n
"if (count _this > 2) then {" \n
" _secondHand = true;" \n
" diag_log (""Second Hand Zombie Initialized: "" + str(_this));" \n
"};"/*%FSM</STATEINIT""">*/;
@@ -475,9 +475,6 @@ class FSM
"_timeN = diag_tickTime;" \n
"" \n
"_agent setBehaviour ""CARELESS"";" \n
"" \n
" _id = _agent addeventhandler [""HandleDamage"",{_this call local_zombieDamage}];" \n
"" \n
"//hint ""run local zombie"";" \n
"_isSomeone = true;" \n
"" \n

View File

@@ -282,9 +282,6 @@ class FSM
"_agent disableAI ""FSM"";" \n
"_newDest = getPosATL _agent;" \n
"_timeN = time;" \n
"" \n
" _id = _agent addeventhandler [""HandleDamage"",{_this call local_zombieDamage}];" \n
"" \n
"_target = objNull;" \n
"_targetPos = [];" \n
"_countr = 0;" \n