public override void ActionResult(int index, MonsterInteraction m) { switch (index) { case (0): Debug.Log("Idle"); break; case (1): HarvestHere(m); break; case (2): WaterHere(m); break; case (3): EatHere(m); break; case (4): SleepHere(m); break; default: Debug.Log("Index ERROR"); break; } float hungerAmount = behaviorBook.behaviorDictionary[index].hungerAmount; float tirenessAmount = behaviorBook.behaviorDictionary[index].tirenessAmount; float emotionAmount = behaviorBook.behaviorDictionary[index].emotionAmount; m.SetStatus(hungerAmount, tirenessAmount, emotionAmount); }
private void UpdateStatus(int index, MonsterInteraction m) { float hungerAmount = behaviorBook.behaviorDictionary[index].hungerAmount; float tirenessAmount = behaviorBook.behaviorDictionary[index].tirenessAmount; float emotionAmount = behaviorBook.behaviorDictionary[index].emotionAmount; m.SetStatus(hungerAmount, tirenessAmount, emotionAmount); }