示例#1
0
 private void Start()
 {
     this.animControl = base.transform.GetComponentInChildren <creepyAnimatorControl>();
     this.setup       = base.transform.GetComponentInChildren <mutantScriptSetup>();
     this.animator    = base.transform.GetComponentInChildren <Animator>();
     this.events      = base.transform.GetComponentInChildren <enemyAnimEvents>();
 }
示例#2
0
 private void Start()
 {
     this.animControl = base.transform.GetComponentInChildren<creepyAnimatorControl>();
     this.setup = base.transform.GetComponentInChildren<mutantScriptSetup>();
     this.animator = base.transform.GetComponentInChildren<Animator>();
     this.events = base.transform.GetComponentInChildren<enemyAnimEvents>();
 }
示例#3
0
 private void doAwake()
 {
     this.enemyHitMask = 36841472;
     this.rootTr       = base.transform.root;
     if (!this.netPrefab)
     {
         this.setup = base.transform.root.GetComponentInChildren <mutantScriptSetup>();
         this.ai    = base.transform.root.GetComponentInChildren <mutantAI>();
     }
     if (this.netPrefab)
     {
         this.ai_net = base.transform.root.GetComponentInChildren <mutantAI_net>();
     }
     this.animator  = base.transform.root.GetComponentInChildren <Animator>();
     this.events    = base.transform.root.GetComponentInChildren <enemyAnimEvents>();
     this.blockHash = Animator.StringToHash("block");
     FMODCommon.PreloadEvents(new string[]
     {
         this.weaponHitEvent,
         this.parryEvent,
         this.blockEvent,
         this.shellBlockEvent
     });
     this.hasPreloaded = true;
 }
示例#4
0
 private void doAwake()
 {
     this.enemyHitMask = 36841472;
     this.rootTr = base.transform.root;
     if (!this.netPrefab)
     {
         this.setup = base.transform.root.GetComponentInChildren<mutantScriptSetup>();
         this.ai = base.transform.root.GetComponentInChildren<mutantAI>();
     }
     if (this.netPrefab)
     {
         this.ai_net = base.transform.root.GetComponentInChildren<mutantAI_net>();
     }
     this.animator = base.transform.root.GetComponentInChildren<Animator>();
     this.events = base.transform.root.GetComponentInChildren<enemyAnimEvents>();
     this.blockHash = Animator.StringToHash("block");
     FMODCommon.PreloadEvents(new string[]
     {
         this.weaponHitEvent,
         this.parryEvent,
         this.blockEvent,
         this.shellBlockEvent
     });
     this.hasPreloaded = true;
 }
示例#5
0
 private void Start()
 {
     this.animator         = base.GetComponent <Animator>();
     this.controller       = base.transform.parent.GetComponent <CharacterController>();
     this.events           = base.GetComponent <enemyAnimEvents>();
     this.thisTr           = base.transform;
     this.rootTr           = base.transform.parent;
     this.ai               = base.gameObject.GetComponent <mutantAI>();
     this.setup            = base.GetComponent <mutantScriptSetup>();
     this.hashId           = base.GetComponent <mutantMaleHashId>();
     this.target           = LocalPlayer.Transform;
     this.jumpingHash      = Animator.StringToHash("jumping");
     this.jumpFallHash     = Animator.StringToHash("jumpFall");
     this.inTrapHash       = Animator.StringToHash("inTrap");
     this.runTrapHash      = Animator.StringToHash("runTrap");
     this.controllerRadius = this.controller.radius;
     if (this.setup.pmBrain)
     {
         this.fsmPlayerDist       = this.setup.pmBrain.FsmVariables.GetFsmFloat("playerDist");
         this.fsmDoControllerBool = this.setup.pmBrain.FsmVariables.GetFsmBool("enableControllerBool");
         this.fsmEnableGravity    = this.setup.pmBrain.FsmVariables.GetFsmBool("enableGravityBool");
         this.fsmTargetSeen       = this.setup.pmBrain.FsmVariables.GetFsmBool("targetSeenBool");
     }
     if (this.setup.pmSleep)
     {
         this.fsmInCaveBool = this.setup.pmSleep.FsmVariables.GetFsmBool("inCaveBool");
         this.fsmNoMoveBool = this.setup.pmSleep.FsmVariables.GetFsmBool("noMoveBool");
     }
     if (this.setup.pmCombat)
     {
         this.fsmDeathBool = this.setup.pmCombat.FsmVariables.GetFsmBool("deathBool");
     }
     this.layerMask = 101851136;
     base.Invoke("initAnimator", 0.5f);
     if (BoltNetwork.isRunning)
     {
         this.setup.pmCombat.FsmVariables.GetFsmBool("boltIsActive").Value = true;
     }
     else
     {
         this.setup.pmCombat.FsmVariables.GetFsmBool("boltIsActive").Value = false;
     }
 }
示例#6
0
 private void Awake()
 {
     this.controller = base.transform.parent.GetComponent <CapsuleCollider>();
     this.animator   = base.GetComponent <Animator>();
     this.events     = base.GetComponent <enemyAnimEvents>();
 }
 private void Start()
 {
     this.animator = base.GetComponent<Animator>();
     this.controller = base.transform.parent.GetComponent<CharacterController>();
     this.events = base.GetComponent<enemyAnimEvents>();
     this.thisTr = base.transform;
     this.rootTr = base.transform.parent;
     this.ai = base.gameObject.GetComponent<mutantAI>();
     this.setup = base.GetComponent<mutantScriptSetup>();
     this.hashId = base.GetComponent<mutantMaleHashId>();
     this.target = LocalPlayer.Transform;
     this.jumpingHash = Animator.StringToHash("jumping");
     this.jumpFallHash = Animator.StringToHash("jumpFall");
     this.inTrapHash = Animator.StringToHash("inTrap");
     this.runTrapHash = Animator.StringToHash("runTrap");
     this.controllerRadius = this.controller.radius;
     if (this.setup.pmBrain)
     {
         this.fsmPlayerDist = this.setup.pmBrain.FsmVariables.GetFsmFloat("playerDist");
         this.fsmDoControllerBool = this.setup.pmBrain.FsmVariables.GetFsmBool("enableControllerBool");
         this.fsmEnableGravity = this.setup.pmBrain.FsmVariables.GetFsmBool("enableGravityBool");
         this.fsmTargetSeen = this.setup.pmBrain.FsmVariables.GetFsmBool("targetSeenBool");
     }
     if (this.setup.pmSleep)
     {
         this.fsmInCaveBool = this.setup.pmSleep.FsmVariables.GetFsmBool("inCaveBool");
         this.fsmNoMoveBool = this.setup.pmSleep.FsmVariables.GetFsmBool("noMoveBool");
     }
     if (this.setup.pmCombat)
     {
         this.fsmDeathBool = this.setup.pmCombat.FsmVariables.GetFsmBool("deathBool");
     }
     this.layerMask = 101851136;
     base.Invoke("initAnimator", 0.5f);
     if (BoltNetwork.isRunning)
     {
         this.setup.pmCombat.FsmVariables.GetFsmBool("boltIsActive").Value = true;
     }
     else
     {
         this.setup.pmCombat.FsmVariables.GetFsmBool("boltIsActive").Value = false;
     }
 }
示例#8
0
 private void doAwake()
 {
     if (this.disableAiForDebug)
     {
         this.disableForDebug();
     }
     this.allFSM = base.gameObject.GetComponents<PlayMakerFSM>();
     PlayMakerFSM[] array = this.allFSM;
     for (int i = 0; i < array.Length; i++)
     {
         PlayMakerFSM playMakerFSM = array[i];
         if (playMakerFSM.FsmName == "action_combatFSM")
         {
             this.pmCombat = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "action_inTreeFSM")
         {
             this.pmTree = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_visionFSM")
         {
             this.pmVision = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_searchFSM")
         {
             this.pmSearch = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "action_stalkingFSM")
         {
             this.pmStalk = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_motorFSM")
         {
             this.pmMotor = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_sleepingFSM")
         {
             this.pmSleep = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_brainFSM")
         {
             this.pmBrain = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "global_alertManagerFSM")
         {
             this.pmAlert = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_encounterFSM")
         {
             this.pmEncounter = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_targetManagerFSM")
         {
             this.pmTargetManager = playMakerFSM;
         }
     }
     this.thisGo = base.gameObject;
     this.rootTr = base.transform.root.transform;
     this.rotateTr = base.transform;
     this.familyFunctions = base.transform.parent.GetComponent<mutantFamilyFunctions>();
     this.animator = base.GetComponent<Animator>();
     this.ai = base.GetComponent<mutantAI>();
     this.aiManager = base.GetComponent<mutantAiManager>();
     this.typeSetup = base.transform.parent.GetComponent<mutantTypeSetup>();
     this.health = base.GetComponent<EnemyHealth>();
     this.dayCycle = base.GetComponentInChildren<mutantDayCycle>();
     this.enemyEvents = base.transform.GetComponent<enemyAnimEvents>();
     this.controller = base.transform.root.GetComponent<CharacterController>();
     this.hashs = base.transform.GetComponent<mutantMaleHashId>();
     this.propManager = base.transform.GetComponent<mutantPropManager>();
     this.bodyVariation = base.transform.GetComponentInChildren<setupBodyVariation>();
     this.collisionDetect = base.transform.GetComponentInChildren<mutantCollisionDetect>();
     this.hitReceiver = base.transform.GetComponentInChildren<mutantHitReceiver>();
     this.animControl = base.transform.GetComponentInChildren<mutantAnimatorControl>();
     if (!this.disableAiForDebug)
     {
         this.sceneInfo = Scene.SceneTracker;
     }
     this.search = base.GetComponent<mutantSearchFunctions>();
     this.worldSearch = base.transform.parent.GetComponent<mutantWorldSearchFunctions>();
     this.mutantStats = base.transform.parent.GetComponent<targetStats>();
     Transform[] componentsInChildren = base.transform.parent.GetComponentsInChildren<Transform>();
     Transform[] array2 = componentsInChildren;
     for (int j = 0; j < array2.Length; j++)
     {
         Transform transform = array2[j];
         if (transform.name == "char_Head")
         {
             this.headJoint = transform.gameObject;
         }
         if (transform.name == "char_LeftHandWeapon")
         {
             this.charLeftWeaponGo = transform.gameObject;
         }
         if (transform.name == "currentWaypoint")
         {
             this.currentWaypoint = transform.gameObject;
         }
         if (transform.name == "lastPlayerSighting")
         {
             this.lastSighting = transform.gameObject;
         }
         if (transform.name == "tempLookat")
         {
             this.lookatTr = transform;
         }
         if (transform.name == "char_club_mesh1")
         {
             this.weapon = transform.gameObject;
         }
         if (transform.name == "FireStick")
         {
             this.fireWeapon = transform.gameObject;
         }
         if (transform.name == "char_RightHand")
         {
             this.clawsWeapon = transform.gameObject;
         }
         if (transform.name == "weaponLeftGO")
         {
             this.leftWeapon = transform.gameObject;
         }
         if (transform.name == "weaponLeftGO1")
         {
             this.leftWeapon1 = transform.gameObject;
         }
         if (transform.name == "weaponRightGO")
         {
             this.rightWeapon = transform.gameObject;
         }
         if (transform.name == "mainHitTrigger")
         {
             this.mainWeapon = transform.gameObject;
         }
         if (transform.name == "fireBomb")
         {
             this.fireBombGo = transform.gameObject;
         }
         if (transform.name == "dragPointGo")
         {
             this.familyFunctions.dragPoint = transform.gameObject;
         }
         if (transform.name == "bodyCollision")
         {
             if (this.pmCombat)
             {
                 this.pmCombat.FsmVariables.GetFsmGameObject("bodyCollisionGo").Value = transform.gameObject;
             }
             this.bodyCollisionCollider = transform.GetComponent<CapsuleCollider>();
         }
         if (transform.name == "char_LeftFoot")
         {
             this.leftFoot = transform;
         }
         if (transform.name == "headCollision")
         {
             this.headColliderGo = transform.gameObject;
         }
     }
 }
示例#9
0
 private void Awake()
 {
     this.controller = base.transform.parent.GetComponent<CapsuleCollider>();
     this.animator = base.GetComponent<Animator>();
     this.events = base.GetComponent<enemyAnimEvents>();
 }
示例#10
0
 private void doAwake()
 {
     if (this.disableAiForDebug)
     {
         this.disableForDebug();
     }
     this.allFSM = base.gameObject.GetComponents <PlayMakerFSM>();
     PlayMakerFSM[] array = this.allFSM;
     for (int i = 0; i < array.Length; i++)
     {
         PlayMakerFSM playMakerFSM = array[i];
         if (playMakerFSM.FsmName == "action_combatFSM")
         {
             this.pmCombat = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "action_inTreeFSM")
         {
             this.pmTree = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_visionFSM")
         {
             this.pmVision = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_searchFSM")
         {
             this.pmSearch = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "action_stalkingFSM")
         {
             this.pmStalk = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_motorFSM")
         {
             this.pmMotor = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_sleepingFSM")
         {
             this.pmSleep = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_brainFSM")
         {
             this.pmBrain = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "global_alertManagerFSM")
         {
             this.pmAlert = playMakerFSM;
         }
         if (playMakerFSM.FsmName == "action_encounterFSM")
         {
             this.pmEncounter = playMakerFSM;
             this.actionFSM.Add(playMakerFSM);
         }
         if (playMakerFSM.FsmName == "global_targetManagerFSM")
         {
             this.pmTargetManager = playMakerFSM;
         }
     }
     this.thisGo          = base.gameObject;
     this.rootTr          = base.transform.root.transform;
     this.rotateTr        = base.transform;
     this.familyFunctions = base.transform.parent.GetComponent <mutantFamilyFunctions>();
     this.animator        = base.GetComponent <Animator>();
     this.ai              = base.GetComponent <mutantAI>();
     this.aiManager       = base.GetComponent <mutantAiManager>();
     this.typeSetup       = base.transform.parent.GetComponent <mutantTypeSetup>();
     this.health          = base.GetComponent <EnemyHealth>();
     this.dayCycle        = base.GetComponentInChildren <mutantDayCycle>();
     this.enemyEvents     = base.transform.GetComponent <enemyAnimEvents>();
     this.controller      = base.transform.root.GetComponent <CharacterController>();
     this.hashs           = base.transform.GetComponent <mutantMaleHashId>();
     this.propManager     = base.transform.GetComponent <mutantPropManager>();
     this.bodyVariation   = base.transform.GetComponentInChildren <setupBodyVariation>();
     this.collisionDetect = base.transform.GetComponentInChildren <mutantCollisionDetect>();
     this.hitReceiver     = base.transform.GetComponentInChildren <mutantHitReceiver>();
     this.animControl     = base.transform.GetComponentInChildren <mutantAnimatorControl>();
     if (!this.disableAiForDebug)
     {
         this.sceneInfo = Scene.SceneTracker;
     }
     this.search      = base.GetComponent <mutantSearchFunctions>();
     this.worldSearch = base.transform.parent.GetComponent <mutantWorldSearchFunctions>();
     this.mutantStats = base.transform.parent.GetComponent <targetStats>();
     Transform[] componentsInChildren = base.transform.parent.GetComponentsInChildren <Transform>();
     Transform[] array2 = componentsInChildren;
     for (int j = 0; j < array2.Length; j++)
     {
         Transform transform = array2[j];
         if (transform.name == "char_Head")
         {
             this.headJoint = transform.gameObject;
         }
         if (transform.name == "char_LeftHandWeapon")
         {
             this.charLeftWeaponGo = transform.gameObject;
         }
         if (transform.name == "currentWaypoint")
         {
             this.currentWaypoint = transform.gameObject;
         }
         if (transform.name == "lastPlayerSighting")
         {
             this.lastSighting = transform.gameObject;
         }
         if (transform.name == "tempLookat")
         {
             this.lookatTr = transform;
         }
         if (transform.name == "char_club_mesh1")
         {
             this.weapon = transform.gameObject;
         }
         if (transform.name == "FireStick")
         {
             this.fireWeapon = transform.gameObject;
         }
         if (transform.name == "char_RightHand")
         {
             this.clawsWeapon = transform.gameObject;
         }
         if (transform.name == "weaponLeftGO")
         {
             this.leftWeapon = transform.gameObject;
         }
         if (transform.name == "weaponLeftGO1")
         {
             this.leftWeapon1 = transform.gameObject;
         }
         if (transform.name == "weaponRightGO")
         {
             this.rightWeapon = transform.gameObject;
         }
         if (transform.name == "mainHitTrigger")
         {
             this.mainWeapon = transform.gameObject;
         }
         if (transform.name == "fireBomb")
         {
             this.fireBombGo = transform.gameObject;
         }
         if (transform.name == "dragPointGo")
         {
             this.familyFunctions.dragPoint = transform.gameObject;
         }
         if (transform.name == "bodyCollision")
         {
             if (this.pmCombat)
             {
                 this.pmCombat.FsmVariables.GetFsmGameObject("bodyCollisionGo").Value = transform.gameObject;
             }
             this.bodyCollisionCollider = transform.GetComponent <CapsuleCollider>();
         }
         if (transform.name == "char_LeftFoot")
         {
             this.leftFoot = transform;
         }
         if (transform.name == "headCollision")
         {
             this.headColliderGo = transform.gameObject;
         }
     }
 }