Esempio n. 1
0
 void Awake()
 {
     this.movement           = GetComponent <CharMovement>();
     this.movement.WalkSpeed = 4f;
     this.Scent              = GetComponent <ObjectScent>();
     this.witchSprite        = GetComponentInChildren <WitchSprite>();
     this.animator           = GetComponentInChildren <Animator>();
     this.originalController = animator.runtimeAnimatorController;
 }
Esempio n. 2
0
    private void StepFollowing(ObjectScent scent)
    {
        var scentDirection = scent.GetDirectionToFollow(this.hunterMovement.Cell);

        if (!this.hunterMovement.CurrentDirection.HasValue || scentDirection != this.hunterMovement.CurrentDirection.Value)
        {
            this.hunterMovement.Move(scentDirection);
        }
    }
Esempio n. 3
0
 void Awake()
 {
     this.bang           = GetComponentInChildren <HunterBang>();
     this.grid           = GetComponentInParent <WalkingGrid>();
     this.witchScent     = this.grid.Witches[0].Scent;
     this.cauldronScent  = this.grid.Cauldron.Scent;
     this.hunter         = GetComponent <HunterActions>();
     this.hunterMovement = GetComponent <CharMovement>();
     this.hunterSprite   = GetComponentInChildren <HunterSprite>();
 }
Esempio n. 4
0
 void Awake()
 {
     this.Scent = GetComponent <ObjectScent>();
 }