Exemple #1
0
 public NPCAttacker(SceneNPC awholeNPC)
 {
     _wholeNPC    = awholeNPC;
     IsAttacking  = false;
     _firstUpdate = true;
     _weapon      = _wholeNPC.GetComponentInChildren <SceneWeapon>();
 }
Exemple #2
0
 public NPCMover(SceneNPC awholeNPC, UnitPathfinder aPathFinder, CorvoPathFinder aCorvoPathFinder)
 {
     _distanceCalcTimer = 0;
     _walkTarget        = Vector3.zero;
     _isWalkTargetSet   = false;
     _lookDirection     = Quaternion.identity;
     pathFinder         = aPathFinder;
     corvoPathFinder    = aCorvoPathFinder;
     _firstUpdate       = true;
     _wholeNPC          = awholeNPC;
 }
Exemple #3
0
 public NPCAI(string aType, LivingCharacter aCharacter, SceneNPC aSceneNPC, NPCMover aMover, NPCAttacker anAttacker)
 {
     Config         = FPPGame.FPPGameModuleManager.Instance.FindEnemyData(aType);
     _character     = aCharacter;
     _thinkingTimer = 0;
     _bodyStayTimer = 0;
     _firstUpdate   = true;
     _sceneNPC      = aSceneNPC;
     _attacker      = anAttacker;
     _mover         = aMover;
     try
     {
         CurrentAttidude = (Attidude)Enum.Parse(typeof(Attidude), (string)Config["baseAttidude"]);
     } catch (Exception)
     {
         CurrentAttidude = Attidude.Neutral;
     }
 }