Replaced almost all placeholders with final art
Some animations still need to be added and replaced, but most of the sprites are final now.
This commit is contained in:
@@ -19,7 +19,7 @@ public class PicnicBehaviour : MonoBehaviour
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void Start()
|
||||
{
|
||||
StartCoroutine(RandomFirstMethodRoutine());
|
||||
StartCoroutine(StateCycleRoutine());
|
||||
}
|
||||
|
||||
void Awake()
|
||||
@@ -34,38 +34,24 @@ public class PicnicBehaviour : MonoBehaviour
|
||||
|
||||
}
|
||||
|
||||
private IEnumerator RandomFirstMethodRoutine()
|
||||
private IEnumerator StateCycleRoutine()
|
||||
{
|
||||
while (true)
|
||||
{
|
||||
float waitTime = Random.Range(getDistractedMin, getDistractedMax);
|
||||
yield return new WaitForSeconds(waitTime);
|
||||
FirstMethod();
|
||||
// Distracted state
|
||||
float distractedWait = Random.Range(getDistractedMin, getDistractedMax);
|
||||
stateMachine.ChangeState("Picnic PPL Distracted");
|
||||
animator.SetBool("theyDistracted", true);
|
||||
yield return new WaitForSeconds(distractedWait);
|
||||
|
||||
// Chilling state
|
||||
float chillingWait = Random.Range(getFlirtyMin, getFlirtyMax);
|
||||
stateMachine.ChangeState("Picnic PPL Chilling");
|
||||
animator.SetBool("theyDistracted", false);
|
||||
yield return new WaitForSeconds(chillingWait);
|
||||
}
|
||||
}
|
||||
|
||||
private void FirstMethod()
|
||||
{
|
||||
Debug.Log("First method called!");
|
||||
stateMachine.ChangeState("Picnic PPL Distracted");
|
||||
animator.SetBool("theyDistracted", true);
|
||||
StartCoroutine(RandomSecondMethodRoutine());
|
||||
}
|
||||
|
||||
private IEnumerator RandomSecondMethodRoutine()
|
||||
{
|
||||
float waitTime = Random.Range(getFlirtyMin, getFlirtyMax);
|
||||
yield return new WaitForSeconds(waitTime);
|
||||
SecondMethod();
|
||||
}
|
||||
|
||||
private void SecondMethod()
|
||||
{
|
||||
Debug.Log("Second method called!");
|
||||
stateMachine.ChangeState("Picnic PPL Chilling");
|
||||
animator.SetBool("theyDistracted", false);
|
||||
}
|
||||
|
||||
public void triedToStealChocolate()
|
||||
{
|
||||
animator.SetTrigger("theyAngry");
|
||||
|
||||
Reference in New Issue
Block a user