Esempio n. 1
0
 void CheckYomiAbilityActivated(float SpecialMultiplier)
 {
     if (SpecialMultiplier == -1)
     {
         SpecEffect         = Instantiate(SpecEffectPf) as SpecAbil;
         SpecEffect.Special = SpecAbil.SpecAbils.Yomi;
     }
 }
Esempio n. 2
0
    void OnMouseDown()
    {
        if (Var.OnTutorial == false || Var.Mng.Tutorial.Page == 36)
        {
            GoNextPeriod();
            Var.Mng.AudioSources[2].Play();

            foreach (Character Mem in Var.Mems)
            {
                if (Mem.Name == "쎈타")
                {
                    int LOL = UnityEngine.Random.Range(0, 3);

                    if (LOL == 2)
                    {
                        SpecEffect         = Instantiate(SpecEffectPf) as SpecAbil;
                        SpecEffect.Special = SpecAbil.SpecAbils.Center;

                        Mem.CurrentAct      = Character.ActionIndex.None;
                        Mem.Balloon.enabled = false;
                    }
                }
            }

            if (Var.OnTutorial == true)
            {
                Var.Mng.Tutorial.Page            += 1;
                Var.Mng.Tutorial.Collider.enabled = true;
            }
            else
            {
                foreach (Character PlanMember in Var.PlanMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(PlanMember);
                    AbilityUp(PlanMember, Character.Talents.Plan, 0, SpecialMultiplier, Var.Mng.Sb.Level * 5);

                    PlanMember.Loyalty -= Var.DecLoyalHard;
                    CheckSpecialAbilityForLoyalty(Var.PlanMems, true);
                }
                foreach (Character ProgrammingMember in Var.ProgramMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(ProgrammingMember);
                    AbilityUp(ProgrammingMember, Character.Talents.Programming, 1, SpecialMultiplier, Var.Mng.Cpu.Level * 5);

                    ProgrammingMember.Loyalty -= Var.DecLoyalHard;
                    CheckSpecialAbilityForLoyalty(Var.ProgramMems, true);
                }
                foreach (Character DrawMember in Var.DrawMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(DrawMember);
                    AbilityUp(DrawMember, Character.Talents.Art, 2, SpecialMultiplier, Var.Mng.Sb.Level * 5);

                    DrawMember.Loyalty -= Var.DecLoyalHard;
                    CheckSpecialAbilityForLoyalty(Var.DrawMems, true);
                }
                foreach (Character ComposeMember in Var.ComposeMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(ComposeMember);
                    AbilityUp(ComposeMember, Character.Talents.Sound, 3, SpecialMultiplier, Var.Mng.Cps.Level * 5);

                    ComposeMember.Loyalty -= Var.DecLoyalHard;
                    CheckSpecialAbilityForLoyalty(Var.ComposeMems, true);
                }
                foreach (Character BdGmMem in Var.BdGmMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(BdGmMem);
                    AbilityUp(BdGmMem, Character.Talents.Plan, 0, SpecialMultiplier, Var.Mng.Bg.Level * 4 - 1);
                    AbilityUp(BdGmMem, Character.Talents.Art, 2, SpecialMultiplier, Var.Mng.Bg.Level * 4 - 1);

                    BdGmMem.Loyalty -= Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.BdGmMems, false);
                }
                foreach (Character WatchMem in Var.WatchMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(WatchMem);
                    AbilityUp(WatchMem, Character.Talents.Sound, 3, SpecialMultiplier, Var.Mng.Tv.Level * 4 - 1);
                    AbilityUp(WatchMem, Character.Talents.Art, 2, SpecialMultiplier, Var.Mng.Tv.Level * 4 - 1);

                    WatchMem.Loyalty -= Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.WatchMems, false);
                }
                foreach (Character GameMem in Var.GameMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(GameMem);
                    AbilityUp(GameMem, Character.Talents.Sound, 3, SpecialMultiplier, Var.Mng.Gm.Level * 4 - 2);
                    AbilityUp(GameMem, Character.Talents.Plan, 0, SpecialMultiplier, Var.Mng.Gm.Level * 4 - 2);
                    AbilityUp(GameMem, Character.Talents.Art, 2, SpecialMultiplier, Var.Mng.Gm.Level * 4 - 2);

                    GameMem.Loyalty -= Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.GameMems, false);
                }
                foreach (Character BookMem in Var.BookMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(BookMem);
                    AbilityUp(BookMem, Character.Talents.Plan, 0, SpecialMultiplier, Var.Mng.Bk.Level * 4 - 2);
                    AbilityUp(BookMem, Character.Talents.Programming, 1, SpecialMultiplier, Var.Mng.Bk.Level * 4 - 2);

                    BookMem.Loyalty -= Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.GameMems, false);
                }
                foreach (Character CookMem in Var.CookMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(CookMem);
                    AbilityUp(CookMem, Character.Talents.Art, 2, SpecialMultiplier, Var.Mng.Ck.Level * 4);

                    CookMem.Loyalty -= Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.CookMems, false);
                }
                foreach (Character PiaMem in Var.PiaMems)
                {
                    float SpecialMultiplier = ReturnSpecialMultiplier(PiaMem);
                    AbilityUp(PiaMem, Character.Talents.Sound, 3, SpecialMultiplier, Var.Mng.Pia.Level * 4);

                    PiaMem.Loyalty += Var.DecLoyalEasy;
                    CheckSpecialAbilityForLoyalty(Var.PiaMems, false);
                }

                Notice = Instantiate(NoticePrefab) as NoticeMessage;
                if (Var.PlanMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.PlanResult;
                }
                else if (Var.ProgramMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.ProgrammingResult;
                }
                else if (Var.DrawMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.DrawResult;
                }
                else if (Var.ComposeMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.ComposeResult;
                }
                else if (Var.BdGmMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.BdGmResult;
                }
                else if (Var.WatchMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.TvResult;
                }
                else if (Var.GameMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.GameResult;
                }
                else if (Var.BookMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.BookResult;
                }
                else if (Var.CookMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.CookResult;
                }
                else if (Var.PiaMems.Count != 0)
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.PiaResult;
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NothingResult;
                }
                Var.MenuActivated = true;
            }
        }

        foreach (Character Mem in Var.Mems)
        {
            if (Mem.PrevAct2 == Mem.PrevAct1 && Mem.PrevAct1 == Mem.CurrentAct && Mem.CurrentAct != Character.ActionIndex.None)
            {
                Mem.Loyalty -= 2;
            }

            Mem.PrevAct2 = Mem.PrevAct1;
            Mem.PrevAct1 = Mem.CurrentAct;

            if (Mem.Name == "이유진")
            {
                if (Var.Day == "초")
                {
                    if (Var.Month == 1 || Var.Month == 7)
                    {
                        SpecEffect         = Instantiate(SpecEffectPf) as SpecAbil;
                        SpecEffect.Special = SpecAbil.SpecAbils.Eugene;

                        Mem.Collider.enabled = false;
                        Mem.Renderer.enabled = false;
                        Mem.Balloon.enabled  = false;
                        Mem.CurrentAct       = Character.ActionIndex.None;
                    }
                    else if (Var.Month == 3 || Var.Month == 9)
                    {
                        Mem.Collider.enabled = true;
                        Mem.Renderer.enabled = true;
                        Mem.Balloon.enabled  = true;
                    }
                }
            }
            if (Mem.Controllable == false)
            {
                Mem.UnControllableDuration -= 1;
                if (Mem.UnControllableDuration == 0)
                {
                    Mem.Controllable = true;
                }
            }
            if (Mem.DoubleBuff == true)
            {
                Mem.BuffDuration -= 1;
                if (Mem.BuffDuration == 0)
                {
                    Mem.DoubleBuff = false;
                }
            }
        }
    }
Esempio n. 3
0
    void CheckSpecMemAbility(Project Pj)
    {
        List <Character> PjMems = new List <Character> ();

        if (Pj.PjMems[0] != null && Pj.PjMems[0].Name == "오키드")
        {
            if (Pj.PjMems[1] != null)
            {
                PjMems.Add(Pj.PjMems[1]);
            }
            if (Pj.PjMems[2] != null)
            {
                PjMems.Add(Pj.PjMems[2]);
            }
            if (Pj.PjMems[3] != null)
            {
                PjMems.Add(Pj.PjMems[3]);
            }
        }
        else if (Pj.PjMems[1] != null && Pj.PjMems[1].Name == "오키드")
        {
            if (Pj.PjMems[0] != null)
            {
                PjMems.Add(Pj.PjMems[0]);
            }
            if (Pj.PjMems[2] != null)
            {
                PjMems.Add(Pj.PjMems[2]);
            }
            if (Pj.PjMems[3] != null)
            {
                PjMems.Add(Pj.PjMems[3]);
            }
        }
        else if (Pj.PjMems[2] != null && Pj.PjMems[2].Name == "오키드")
        {
            if (Pj.PjMems[0] != null)
            {
                PjMems.Add(Pj.PjMems[0]);
            }
            if (Pj.PjMems[1] != null)
            {
                PjMems.Add(Pj.PjMems[1]);
            }
            if (Pj.PjMems[3] != null)
            {
                PjMems.Add(Pj.PjMems[3]);
            }
        }
        else if (Pj.PjMems[3] != null && Pj.PjMems[3].Name == "오키드")
        {
            if (Pj.PjMems[0] != null)
            {
                PjMems.Add(Pj.PjMems[0]);
            }
            if (Pj.PjMems[1] != null)
            {
                PjMems.Add(Pj.PjMems[1]);
            }
            if (Pj.PjMems[2] != null)
            {
                PjMems.Add(Pj.PjMems[2]);
            }
        }

        if (PjMems.Count > 1)
        {
            SpecEffect         = Instantiate(SpecEffectPf) as SpecAbil;
            SpecEffect.Special = SpecAbil.SpecAbils.Orchid;

            PjMems[0].Relationship[PjMems[1].MemberNumber] += 20;
            PjMems[1].Relationship[PjMems[0].MemberNumber] += 20;
            if (PjMems[0].Relationship[PjMems[1].MemberNumber] >= 20 && PjMems[0].Relationship[PjMems[1].MemberNumber] <= 35)
            {
                Var.NewFriends.Add(PjMems[0]);
                Var.NewFriends.Add(PjMems[1]);
            }
        }
        if (PjMems.Count > 2)
        {
            PjMems[0].Relationship[PjMems[2].MemberNumber] += 20;
            PjMems[2].Relationship[PjMems[0].MemberNumber] += 20;
            if (PjMems[0].Relationship[PjMems[2].MemberNumber] >= 20 && PjMems[0].Relationship[PjMems[2].MemberNumber] <= 35)
            {
                Var.NewFriends.Add(PjMems[0]);
                Var.NewFriends.Add(PjMems[2]);
            }

            PjMems[2].Relationship[PjMems[1].MemberNumber] += 20;
            PjMems[1].Relationship[PjMems[2].MemberNumber] += 20;
            if (PjMems[2].Relationship[PjMems[1].MemberNumber] >= 20 && PjMems[2].Relationship[PjMems[1].MemberNumber] <= 35)
            {
                Var.NewFriends.Add(PjMems[2]);
                Var.NewFriends.Add(PjMems[1]);
            }
        }
    }
Esempio n. 4
0
    void OnMouseDown()
    {
        float OreoMultiplier = 1;

        foreach (Character Mem in Var.Mems)
        {
            if (Mem.Name == "오레오")
            {
                OreoMultiplier = 0.8f;
            }
        }

        Var.Mng.AudioSources [2].Play();
        if (Parent.QuestionType == Question.QuestionTypes.ClbIntro)
        {
            if (OX == true)
            {
                if (Var.Money >= 5)
                {
                    SceneIS           = Instantiate(ScenePF) as CutScene;
                    SceneIS.SceneType = CutScene.SceneTypes.ClubIntroduce;

                    Var.Money -= 5;
                    Var.Mng.RecordMoneyChange(-5, "동아리소개제");

                    if (Var.OnTutorial == true && Var.Mng.Tutorial.Page == 46)
                    {
                        Var.Mng.Tutorial.SendMessage("DeActivateRenderer");
                    }
                }
                else
                {
                    Notice            = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                }

                Destroy(Parent.gameObject);
            }
            else
            {
                if (Var.OnTutorial == false)
                {
                    int NewMemberCount;
                    NewMemberCount = (1 + (Var.Fame / 300)) / 2;
                    if (NewMemberCount > 4)
                    {
                        NewMemberCount = 4;
                    }
                    Var.Mng.CreateNormMem(NewMemberCount);
                    Notice            = Instantiate(NoticePrefab) as NoticeMessage;
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NewMember;
                    Destroy(Parent.gameObject);
                }
            }
        }
        else if (Parent.QuestionType == Question.QuestionTypes.RoomUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.RoomObject.Level == 1)
            {
                if (Var.Fame >= 120)
                {
                    if (Var.Money >= 25 * OreoMultiplier)
                    {
                        Var.Money -= 25 * OreoMultiplier;
                        UsedMoney  = 25 * OreoMultiplier;
                        Var.Mng.RoomObject.Level           = 2;
                        Var.Mng.RoomObject.Renderer.sprite = Var.Mng.RoomObject.Room2;

                        if (Var.AchBoolList[18] == false)
                        {
                            Var.AchBoolList[18] = true;
                            Var.NewAchs.Add(25);
                            PlayerPrefs.SetInt("Ach25", 1);
                            Var.Fame += 50;

                            Var.Mng.NewMember             = Instantiate(Var.Mng.NewMemPf) as Character;
                            Var.Mng.NewMember.Special     = true;
                            Var.Mng.NewMember.Gender      = false;
                            Var.Mng.NewMember.SpecialName = Character.SpecialNameIndex.이유진;
                            Var.NewSpecMems.Add("이유진");
                        }

                        Notice.NoticeType = NoticeMessage.NoticeTypes.RoomUpgrade;
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                }
            }
            else if (Var.Mng.RoomObject.Level == 2)
            {
                if (Var.Fame >= 420)
                {
                    if (Var.Money >= 40 * OreoMultiplier)
                    {
                        Var.Money -= 40 * OreoMultiplier;
                        UsedMoney  = 40 * OreoMultiplier;
                        Var.Mng.RoomObject.Level           = 3;
                        Var.Mng.RoomObject.Renderer.sprite = Var.Mng.RoomObject.Room3;

                        Var.AchBoolList[19] = true;
                        Var.NewAchs.Add(26);
                        PlayerPrefs.SetInt("Ach26", 1);
                        Var.Fame += 100;

                        Notice.NoticeType = NoticeMessage.NoticeTypes.RoomUpgrade;
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                }
            }
            else if (Var.Mng.RoomObject.Level == 3)
            {
                if (Var.Fame >= 830)
                {
                    if (Var.Money >= 55 * OreoMultiplier)
                    {
                        Var.Money -= 55 * OreoMultiplier;
                        UsedMoney  = 55 * OreoMultiplier;
                        Var.Mng.RoomObject.Level           = 4;
                        Var.Mng.RoomObject.Renderer.sprite = Var.Mng.RoomObject.Room4;

                        Var.AchBoolList[20] = true;
                        Var.NewAchs.Add(27);
                        PlayerPrefs.SetInt("Ach27", 1);

                        Var.Fame += 200;

                        Notice.NoticeType = NoticeMessage.NoticeTypes.RoomUpgrade;
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.WbUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Wb.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 100)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money -= 5 * OreoMultiplier;
                            UsedMoney  = 5 * OreoMultiplier;
                            Var.Mng.Wb.Renderer.sprite = Var.Mng.Wb.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Wb.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Wb.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 350)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Wb.Renderer.sprite = Var.Mng.Wb.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Wb.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Wb.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.CpuUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Cpu.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 100)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money -= 5 * OreoMultiplier;
                            UsedMoney  = 5 * OreoMultiplier;
                            Var.Mng.Cpu.Renderer.sprite = Var.Mng.Cpu.Level2;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Cpu.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Cpu.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 350)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Cpu.Renderer.sprite = Var.Mng.Cpu.Level3;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Cpu.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Cpu.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.SbUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Sb.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 100)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money -= 5 * OreoMultiplier;
                            UsedMoney  = 5 * OreoMultiplier;
                            Var.Mng.Sb.Renderer.sprite = Var.Mng.Sb.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Sb.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Sb.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 350)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Sb.Renderer.sprite = Var.Mng.Sb.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Sb.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Sb.SendMessage("SetPosition");
            Var.Mng.Table.SendMessage("SetPosition");
            Var.Mng.Cps.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.CpsUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Cps.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 100)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money -= 5 * OreoMultiplier;
                            UsedMoney  = 5 * OreoMultiplier;
                            Var.Mng.Cps.Renderer.sprite = Var.Mng.Cps.Level2;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Cps.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Cps.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 350)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Cps.Renderer.sprite = Var.Mng.Cps.Level3;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Cps.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Sb.SendMessage("SetPosition");
            Var.Mng.Table.SendMessage("SetPosition");
            Var.Mng.Cps.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.BgUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Bg.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 150)
                    {
                        if (Var.Money >= 2 * OreoMultiplier)
                        {
                            Var.Money                 -= 2 * OreoMultiplier;
                            UsedMoney                  = 2 * OreoMultiplier;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bg.Level           = 1;
                            Var.Mng.Bg.Renderer.sprite = Var.Mng.Bg.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Bg.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 400)
                    {
                        if (Var.Money >= 2 * OreoMultiplier)
                        {
                            Var.Money -= 2 * OreoMultiplier;
                            UsedMoney  = 2 * OreoMultiplier;
                            Var.Mng.Bg.Renderer.sprite = Var.Mng.Bg.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bg.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Bg.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 650)
                    {
                        if (Var.Money >= 2 * OreoMultiplier)
                        {
                            Var.Money -= 2 * OreoMultiplier;
                            UsedMoney  = 2 * OreoMultiplier;
                            Var.Mng.Bg.Renderer.sprite = Var.Mng.Bg.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bg.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Bg.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.TvUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Tv.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 2)
                {
                    if (Var.Fame >= 150)
                    {
                        if (Var.Money >= 8 * OreoMultiplier)
                        {
                            Var.Money                 -= 8 * OreoMultiplier;
                            UsedMoney                  = 8 * OreoMultiplier;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Tv.Level           = 1;
                            Var.Mng.Tv.Renderer.sprite = Var.Mng.Tv.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Tv.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 450)
                    {
                        if (Var.Money >= 1 * OreoMultiplier)
                        {
                            Var.Money -= 1 * OreoMultiplier;
                            UsedMoney  = 1 * OreoMultiplier;
                            Var.Mng.Tv.Renderer.sprite = Var.Mng.Tv.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Tv.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Tv.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 550)
                    {
                        if (Var.Money >= 10 * OreoMultiplier)
                        {
                            Var.Money -= 10 * OreoMultiplier;
                            UsedMoney  = 10 * OreoMultiplier;
                            Var.Mng.Tv.Renderer.sprite = Var.Mng.Tv.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Tv.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Tv.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.GmUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Gm.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 500)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money                 -= 7 * OreoMultiplier;
                            UsedMoney                  = 7 * OreoMultiplier;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Gm.Level           = 1;
                            Var.Mng.Gm.Renderer.sprite = Var.Mng.Gm.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Gm.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 600)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Gm.Renderer.sprite = Var.Mng.Gm.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Gm.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Gm.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 700)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Gm.Renderer.sprite = Var.Mng.Gm.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Gm.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Gm.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.BkUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Bk.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 400)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money                 -= 7 * OreoMultiplier;
                            UsedMoney                  = 7 * OreoMultiplier;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bk.Level           = 1;
                            Var.Mng.Bk.Renderer.sprite = Var.Mng.Bk.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Bk.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 500)
                    {
                        if (Var.Money >= 3.5f * OreoMultiplier)
                        {
                            Var.Money -= 3.5f * OreoMultiplier;
                            UsedMoney  = 3.5f * OreoMultiplier;
                            Var.Mng.Bk.Renderer.sprite = Var.Mng.Bk.Level2;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bk.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Bk.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 600)
                    {
                        if (Var.Money >= 3.5f * OreoMultiplier)
                        {
                            Var.Money -= 3.5f * OreoMultiplier;
                            UsedMoney  = 3.5f * OreoMultiplier;
                            Var.Mng.Bk.Renderer.sprite = Var.Mng.Bk.Level3;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Bk.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Bk.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.PiaUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Pia.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 500)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money                  -= 5 * OreoMultiplier;
                            UsedMoney                   = 5 * OreoMultiplier;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Pia.Level           = 1;
                            Var.Mng.Pia.Renderer.sprite = Var.Mng.Pia.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Pia.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 600)
                    {
                        if (Var.Money >= 7 * OreoMultiplier)
                        {
                            Var.Money -= 7 * OreoMultiplier;
                            UsedMoney  = 7 * OreoMultiplier;
                            Var.Mng.Pia.Renderer.sprite = Var.Mng.Pia.Level2;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Pia.Level           = 2;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Pia.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 700)
                    {
                        if (Var.Money >= 10 * OreoMultiplier)
                        {
                            Var.Money -= 10 * OreoMultiplier;
                            UsedMoney  = 10 * OreoMultiplier;
                            Var.Mng.Pia.Renderer.sprite = Var.Mng.Pia.Level3;
                            Notice.NoticeType           = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Pia.Level           = 3;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Pia.SendMessage("SetPosition");
        }
        else if (Parent.QuestionType == Question.QuestionTypes.CkUpg && OX == true)
        {
            Notice = Instantiate(NoticePrefab, new Vector3(NoticePrefab.transform.position.x, NoticePrefab.transform.position.y, -4), Quaternion.identity) as NoticeMessage;

            if (Var.Mng.Ck.Level == 0)
            {
                if (Var.Mng.RoomObject.Level >= 3)
                {
                    if (Var.Fame >= 500)
                    {
                        if (Var.Money >= 5 * OreoMultiplier)
                        {
                            Var.Money                 -= 5 * OreoMultiplier;
                            UsedMoney                  = 5 * OreoMultiplier;
                            Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                            Var.Mng.Ck.Level           = 1;
                            Var.Mng.Ck.Renderer.sprite = Var.Mng.Ck.Level1;
                        }
                        else
                        {
                            Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughMoney;
                        }
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Ck.Level == 1)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 700)
                    {
                        UsedMoney = 0;
                        Var.Mng.Ck.Renderer.sprite = Var.Mng.Ck.Level2;
                        Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                        Var.Mng.Ck.Level           = 2;
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }
            else if (Var.Mng.Ck.Level == 2)
            {
                if (Var.Mng.RoomObject.Level >= 4)
                {
                    if (Var.Fame >= 800)
                    {
                        UsedMoney = 0;
                        Var.Mng.Ck.Renderer.sprite = Var.Mng.Ck.Level3;
                        Notice.NoticeType          = NoticeMessage.NoticeTypes.RoomUpgrade;
                        Var.Mng.Ck.Level           = 3;
                    }
                    else
                    {
                        Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughFame;
                    }
                }
                else
                {
                    Notice.NoticeType = NoticeMessage.NoticeTypes.NotEnoughRoom;
                }
            }

            Var.Mng.UpgPupCloser.SendMessage("OnMouseDown");
            Var.Mng.Ck.SendMessage("SetPosition");
        }
        if (UsedMoney != 0)
        {
            if (OreoMultiplier == 0.8f)
            {
                SpecEffect         = Instantiate(SpecEffectPf) as SpecAbil;
                SpecEffect.Special = SpecAbil.SpecAbils.Oreo;
            }
            Var.Mng.RecordMoneyChange(UsedMoney * (-1), "업그레이드");
        }

        if (Var.OnTutorial == false || OX == true)
        {
            if (Parent.QuestionType == Question.QuestionTypes.RoomUpg)
            {
                Var.Mng.SetPositionAll();
                Var.Mng.Reset.SendMessage("OnMouseDown");
            }

            Destroy(Parent.WallIs.gameObject);
            Destroy(Parent.gameObject);
        }
    }
Esempio n. 5
0
    void OnMouseDown()
    {
        if (Var.OnTutorial == false)
        {
            Var.Stan1st = Var.PjStan * 100;
            Var.Stan2nd = Var.PjStan * 75;
            Var.Stan3rd = Var.PjStan * 50;
            Var.Stan4th = Var.PjStan * 30;
            Var.Stan5th = Var.PjStan * 20;
            Var.Stan6th = Var.PjStan * 10;

            Result = Instantiate(ResultPrefab) as ProjectResult;

            float MoneyChange = 0;
            int   FameChange  = 0;

            foreach (Character Mem in Var.Mems)
            {
                if (Mem.Name == "트롤러")
                {
                    int BreakProject = UnityEngine.Random.Range(0, Maker.Projects.Count);
                    Maker.Projects.RemoveAt(BreakProject);

                    SpecEffect             = Instantiate(SpecEffectPf) as SpecAbil;
                    SpecEffect.Special     = SpecAbil.SpecAbils.Troll;
                    SpecEffect.BrokenPjNum = BreakProject + 1;
                }
            }

            foreach (Project PJ in Maker.Projects)
            {
                List <int> PjScores = new List <int>();

                CheckSpecMemAbility(PJ);

                PjScores.Add(ComputeScore(PJ.PjMems[0], 0, PJ.Type) * 2 + ComputeScore(PJ.PjMems[1], 0, PJ.Type) + ComputeScore(PJ.PjMems[2], 0, PJ.Type) + ComputeScore(PJ.PjMems[3], 0, PJ.Type));
                PjScores.Add(ComputeScore(PJ.PjMems[0], 1, PJ.Type) + ComputeScore(PJ.PjMems[1], 1, PJ.Type) * 2 + ComputeScore(PJ.PjMems[2], 1, PJ.Type) + ComputeScore(PJ.PjMems[3], 1, PJ.Type));
                PjScores.Add(ComputeScore(PJ.PjMems[0], 2, PJ.Type) + ComputeScore(PJ.PjMems[1], 2, PJ.Type) + ComputeScore(PJ.PjMems[2], 2, PJ.Type) * 2 + ComputeScore(PJ.PjMems[3], 2, PJ.Type));
                PjScores.Add(ComputeScore(PJ.PjMems[0], 3, PJ.Type) + ComputeScore(PJ.PjMems[1], 3, PJ.Type) + ComputeScore(PJ.PjMems[2], 3, PJ.Type) + ComputeScore(PJ.PjMems[3], 3, PJ.Type) * 2);

                int TotalScore = PjScores[0] + PjScores[1] + PjScores[2] + PjScores[3];

                if (TotalScore >= Var.Stan1st)
                {
                    PJ.Rank   = 1;
                    HighScore = 1;
                    Var.ProjectRanks.Add(1);
                    MoneyChange += 100.0f;

                    Var.Mng.GetAch(0, 100);

                    if (Var.AchBoolList[7] == false)
                    {
                        Var.Mng.GetAch(14, 50);
                        Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.오키드, "오키드");
                    }
                    if (Var.AchTimesList[0] == 4)
                    {
                        Var.Mng.GetAch(15, 250);
                        Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.트롤러, "트롤러");
                    }
                }
                else if (TotalScore >= Var.Stan2nd)
                {
                    PJ.Rank = 2;
                    if (HighScore > 2)
                    {
                        HighScore = 2;
                    }
                    Var.ProjectRanks.Add(2);
                    MoneyChange += 50.0f;

                    Var.Mng.GetAch(1, 60);

                    if (Var.AchTimesList[1] == 4 && Var.AchTimesList[0] == 0)
                    {
                        Var.Mng.GetAch(16, 100);
                    }
                }
                else if (TotalScore >= Var.Stan3rd)
                {
                    PJ.Rank = 3;
                    if (HighScore > 3)
                    {
                        HighScore = 3;
                    }
                    Var.ProjectRanks.Add(3);
                    MoneyChange += 20.0f;

                    Var.Mng.GetAch(2, 30);
                }
                else if (TotalScore >= Var.Stan4th)
                {
                    PJ.Rank = 4;
                    Var.ProjectRanks.Add(4);
                }
                else if (TotalScore >= Var.Stan5th)
                {
                    PJ.Rank = 5;
                    Var.ProjectRanks.Add(5);
                }
                else if (TotalScore >= Var.Stan6th)
                {
                    PJ.Rank = 6;
                    Var.ProjectRanks.Add(6);
                }
                else
                {
                    PJ.Rank = 7;
                    Var.ProjectRanks.Add(7);
                }

                int PjMemNum = 0;
                foreach (Character PjMem in PJ.PjMems)
                {
                    if (PjMem != null)
                    {
                        PjMemNum += 1;
                    }
                }

                if (PjMemNum == 4)
                {
                    if (PjScores[0] * 2 > TotalScore)
                    {
                        Var.Mng.GetAch(3, 40);
                        CheckPalbangAch();

                        if (Var.AchTimesList[3] == 3)
                        {
                            Var.Mng.GetAch(9, 100);
                            Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.강참치, "강참치");
                            CheckSuperAch();
                        }
                    }
                    else if (PjScores[1] * 2 > TotalScore)
                    {
                        Var.Mng.GetAch(4, 40);
                        CheckPalbangAch();

                        if (Var.AchTimesList[4] == 3)
                        {
                            Var.Mng.GetAch(10, 100);
                            Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.코딩형근로자, "코딩형근로자");
                            CheckSuperAch();
                        }
                    }
                    else if (PjScores[2] * 2 > TotalScore)
                    {
                        Var.Mng.GetAch(5, 40);
                        CheckPalbangAch();

                        if (Var.AchTimesList[5] == 3)
                        {
                            Var.Mng.GetAch(11, 100);
                            Var.Mng.MakeNewSpecMem(false, Character.SpecialNameIndex.부렁봇, "부렁봇");
                            CheckSuperAch();
                        }
                    }
                    else if (PjScores[3] * 2 > TotalScore)
                    {
                        Var.Mng.GetAch(6, 40);
                        CheckPalbangAch();

                        if (Var.AchTimesList[6] == 3)
                        {
                            Var.Mng.GetAch(12, 100);
                            Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.쎈타, "쎈타");
                            CheckSuperAch();
                        }
                    }
                }
                else if (PjMemNum == 1)
                {
                    if (PJ.Rank <= 3)
                    {
                        Var.Mng.GetAch(7, 50);
                        Var.Mng.MakeNewSpecMem(true, Character.SpecialNameIndex.네모누리, "네모누리");
                    }
                }

                Destroy(PJ.gameObject);
            }

            if (HighScore < 4)
            {
                Var.Fame += FameChange;

                Var.MoneyReasonLog.Add("게임 공모전");
                Var.MoneyMonthLog.Add(Var.Month);
                Var.MoneyDayLog.Add(Var.Day);
                Var.Money += MoneyChange;
                Var.MoneyChangeLog.Add(MoneyChange);
                Var.MoneyRemainLog.Add(Var.Money);

                Var.PjStan += 10 - HighScore;
            }
            else
            {
                Var.PjStan += 6;
            }

            Var.ProjectHighScore = HighScore;

            Notice            = Instantiate(NoticePrefab, new Vector3(0, -2.2f, NoticePrefab.transform.position.z), Quaternion.identity) as NoticeMessage;
            Notice.NoticeType = NoticeMessage.NoticeTypes.ProjectResult;
            Destroy(Var.Mng.WallInstance.gameObject);

            Destroy(Parent.gameObject);
        }
    }