Пример #1
0
        protected override void Awake()
        {
            base.Awake();

            stateManager  = GetComponent <MonsterStateManager>();
            informationUI = GetComponentInChildren <UIFloatingInformation>();
            informationUI.gameObject.SetActive(false);
        }
Пример #2
0
        private void setTargetToMonster(MonsterStateManager target)
        {
            this.targetStateManager = target;
            targetName.text         = target.info.name;
            bool result = hpBar.updateBar((float)target.info.currentHp / (float)target.info.maxHp);

            if (result)
            {
                displayTimer = 0f;
            }
        }
Пример #3
0
 public MonsterScripts(MonsterController controller, MonsterStateManager stateManager)
 {
     this.controller   = controller;
     this.stateManager = stateManager;
 }
Пример #4
0
 protected void Start()
 {
     stateManager = GetComponentInParent <MonsterStateManager>();
     this.initialize((float)stateManager.info.currentHp / (float)stateManager.info.maxHp);
 }