コード例 #1
0
 void RoundSetup()
 {
     chef.Reset();
     appetite = appetites[Random.Range(0, appetites.Count)];
     GetComponent <Text>().text = appetite.description;
     timer.StartTimer();
 }
コード例 #2
0
        List <int> orderMotivesStep(List <int> running, List <Appetite> total)
        {
            if (total.Count <= 0)
            {
                return(running);
            }
            Appetite highest     = null;
            float    maxPriority = float.MinValue;

            foreach (Appetite a in total)
            {
                if (a.priority > maxPriority)
                {
                    highest     = a;
                    maxPriority = a.priority;
                }
            }
            running.Add(highest.key);
            total.Remove(highest);
            return(orderMotivesStep(running, total));
        }
コード例 #3
0
    List <Appetite> SetupAppetites()
    {
        List <Appetite> appetiteList = new List <Appetite>();

        Appetite appetite1 = new Appetite();

        appetite1.app_texture = 6;
        appetite1.app_umami   = 10;
        appetite1.app_impact  = 6;
        appetite1.app_vigor   = 25;
        appetite1.app_aroma   = 22;
        appetite1.description = "I'm in the mood for a hearty and fragrant soup. Nothing too powerful.";
        appetiteList.Add(appetite1);

        Appetite appetite2 = new Appetite();

        appetite2.app_texture = 5;
        appetite2.app_umami   = 5;
        appetite2.app_impact  = 25;
        appetite2.app_vigor   = 25;
        appetite2.app_aroma   = 7;
        appetite2.description = "I'm in the mood for something energizing. Electrifying, you could say.";
        appetiteList.Add(appetite2);

        Appetite appetite3 = new Appetite();

        appetite3.app_texture = 20;
        appetite3.app_umami   = 5;
        appetite3.app_impact  = 30;
        appetite3.app_vigor   = 10;
        appetite3.app_aroma   = 5;
        appetite3.description = "I'm in the mood for something with a lot of crunch, like chips, but in a soup.";
        appetiteList.Add(appetite3);

        Appetite appetite4 = new Appetite();

        appetite4.app_texture = 10;
        appetite4.app_umami   = 25;
        appetite4.app_impact  = 5;
        appetite4.app_vigor   = 16;
        appetite4.app_aroma   = 14;
        appetite4.description = "I'm in the mood for a savory meal.";
        appetiteList.Add(appetite4);

        Appetite appetite5 = new Appetite();

        appetite5.app_texture = 6;
        appetite5.app_umami   = 6;
        appetite5.app_impact  = 22;
        appetite5.app_vigor   = 14;
        appetite5.app_aroma   = 30;
        appetite5.description = "I'm in the mood for something that will make my nose tickle.";
        appetiteList.Add(appetite5);

        Appetite appetite6 = new Appetite();

        appetite6.app_texture = 26;
        appetite6.app_umami   = 10;
        appetite6.app_impact  = 5;
        appetite6.app_vigor   = 20;
        appetite6.app_aroma   = 15;
        appetite6.description = "I'm in the mood for something smooth. Keep the crunchy bits to a minimum!";
        appetiteList.Add(appetite6);

        return(appetiteList);
    }