コード例 #1
0
        static DifficultySettings()
        {
            Easy   = new DifficultyParameters(true, 8, 0.0f, 8);
            Medium = new DifficultyParameters(true, 6, 0.6f, 10);
            Hard   = new DifficultyParameters(false, 4, 1.2f, 12);

            CurrentDifficulty = Easy;
        }
コード例 #2
0
        public static void SetDifficulty(DifficultyEnum difficulty)
        {
            switch (difficulty)
            {
            case DifficultyEnum.Easy:
                CurrentDifficulty = Easy;
                break;

            case DifficultyEnum.Medium:
                CurrentDifficulty = Medium;
                break;

            case DifficultyEnum.Hard:
                CurrentDifficulty = Hard;
                break;
            }
        }
コード例 #3
0
ファイル: PuzzleDifficulty.cs プロジェクト: NaterTots/Pikkit
    private static DifficultyParameters GetVeryHard()
    {
        var hardParams = new DifficultyParameters()
        {
            Difficulty           = PuzzleDifficulty.VeryHard,
            MirrorsRatioMin      = 0.22f,
            MirrorsRatioMax      = 0.52f,
            UniqueSolutionPaths  = 0.55f,
            RandomFillComplexity = 0.8f
        };

        hardParams.SetMaxPath(BoardSize.Four, 9);
        hardParams.SetMaxPath(BoardSize.Five, 11);
        hardParams.SetMaxPath(BoardSize.Six, 13);
        hardParams.SetMaxPath(BoardSize.Eight, 16);

        return(hardParams);
    }
コード例 #4
0
ファイル: PuzzleDifficulty.cs プロジェクト: NaterTots/Pikkit
    private static DifficultyParameters GetMedium()
    {
        var mediumParams = new DifficultyParameters()
        {
            Difficulty           = PuzzleDifficulty.Medium,
            MirrorsRatioMin      = 0.22f,
            MirrorsRatioMax      = 0.52f,
            UniqueSolutionPaths  = 0.74f,
            RandomFillComplexity = 0.4f
        };

        mediumParams.SetMaxPath(BoardSize.Four, 6);
        mediumParams.SetMaxPath(BoardSize.Five, 7);
        mediumParams.SetMaxPath(BoardSize.Six, 9);
        mediumParams.SetMaxPath(BoardSize.Eight, 12);

        return(mediumParams);
    }
コード例 #5
0
ファイル: PuzzleDifficulty.cs プロジェクト: NaterTots/Pikkit
    private static DifficultyParameters GetEasy()
    {
        var easyParams = new DifficultyParameters()
        {
            Difficulty           = PuzzleDifficulty.Easy,
            MirrorsRatioMin      = 0.22f,
            MirrorsRatioMax      = 0.52f,
            UniqueSolutionPaths  = 0.80f,
            RandomFillComplexity = 0.2f
        };

        easyParams.SetMaxPath(BoardSize.Four, 5);
        easyParams.SetMaxPath(BoardSize.Five, 6);
        easyParams.SetMaxPath(BoardSize.Six, 7);
        easyParams.SetMaxPath(BoardSize.Eight, 9);

        return(easyParams);
    }
コード例 #6
0
ファイル: PuzzleDifficulty.cs プロジェクト: NaterTots/Pikkit
    public static DifficultyParameters GetDifficultyParameters(PuzzleDifficulty difficulty)
    {
        DifficultyParameters difficultyParameters = null;

        switch (difficulty)
        {
        case PuzzleDifficulty.Easy:
            difficultyParameters = GetEasy();
            break;

        case PuzzleDifficulty.Medium:
            difficultyParameters = GetMedium();
            break;

        case PuzzleDifficulty.Hard:
            difficultyParameters = GetHard();
            break;

        case PuzzleDifficulty.VeryHard:
            difficultyParameters = GetVeryHard();
            break;
        }
        return(difficultyParameters);
    }
コード例 #7
0
 public StartGameEventArgs(DifficultyParameters difficultyParameters)
 {
     DifficultyParameters = difficultyParameters;
 }