public Choice(EMOTION _emotion, string _text, CallbackEvent _callback, Vector3 _position) { this.emotion = _emotion; this.text = _text; this.callback = _callback; this.position = _position; }
public void Init(EMOTION _emotion, Vector3 _targetPosition) { this.image.sprite = this.sprites[(int)_emotion]; this.targetPosition = Camera.main.WorldToScreenPoint(_targetPosition); this.transform.localScale = Vector3.zero; this.transform.DOScaleY(1f, 0.2f).SetEase(Ease.OutBack); this.transform.DOScaleX(1f, 0.2f).SetDelay(0.05f).SetEase(Ease.OutBack); }
private void ChangeEmotion() { if (currentHappiness > 66) { emotion = EMOTION.Happy; happinessSubstract = 0f; } else if (currentHappiness > 33 && currentHappiness <= 66) { emotion = EMOTION.Irritated; happinessSubstract = 0.5f; } else if (currentHappiness < 33) { emotion = EMOTION.Angry; happinessSubstract = 1.25f; } emotionImage.sprite = emotionSprites[(int)emotion]; }
void SetDefault(EMOTION e) { targetEmotion[(int)e] = (byte)Default; }
void SetAtoB(EMOTION a, EMOTION b) { targetEmotion[(int)a] = (byte)b; }
void SetDefaultEmotion(EMOTION e) { Default = e; }