コード例 #1
0
ファイル: GameSave.cs プロジェクト: denisov94dd/SampleCode
    public static GameSave GetEmpty()
    {
        GameSave save = new GameSave()
        {
            bestLevel                         = 1,
            day                               = 0,
            bestDayLevel                      = 1,
            deathLevel                        = 1,
            starCount                         = 0,
            metaStarsCount                    = 0,
            ticketsCount                      = 0,
            deleteBoosterFreeCount            = 1,
            doubleBoosterFreeCount            = 1,
            turnCount                         = 1,
            ballCount                         = 1,
            campaignLevelsCompleted           = 0,
            additionalCampaignLevelsCompleted = 0,
            boostersUsed                      = false,
            tutorialCompleted                 = false,
            completedMetaTutorials            = new List <MetaTutorialType>(),
            achievements                      = new Achievements(),
            caveProgress                      = new MagicalCaveProgress(),
            openedDragons                     = new List <DragonSaveView>(),
            completedQuests                   = new List <MetaBuilderQuestSave>(),
            savedEffects                      = new List <MetaBuilderFxSave>(),
            savedCollections                  = new List <MetaBuilderCollectionSave>(),
            avaliableEffects                  = new List <int>(),
            avaliableCollections              = new List <int>(),
            colletedMetaQuestPrizes           = new List <MetaBuilderQuestsPrizeProgressSave>(),
            shownItems                        = new List <ItemType>(),
            littleTutorialsPassed             = new List <LittleTutorialType>(),
            AppliedModifiers                  = new List <Modifier>(),
            musicIsOn                         = true,
            soundIsOn                         = true,
            currentEffectPrizeNumber          = 0,
            currentCollectionPrizeNumber      = 0,
            notifications                     = new List <NotificationInformation>(),
            firstLaunchTime                   = DateTime.Now.ToFileTime(),
            playerBannerAdsCohort             = 2,
            usedDragons                       = new List <DragonBonusType>()
        };

        save.gameLanguage = Localizator.GetSystemLanguage();

        if (MetaGameController.instance != null)
        {
            MetaGameController.instance.achievementController.ResetData();
        }
        save.openedDragons.Add(new DragonSaveView(DragonType.DragonOne));
        return(save);
    }