Ejemplo n.º 1
0
        private static AchievementInstruction enterRootAST(RootAST rootAst)
        {
            AchievementInstruction achievement = new AchievementInstruction();

            achievement.Core = enterConditionGroupAST(rootAst.Core);

            foreach (var alt in rootAst.Alternates)
            {
                achievement.Alternates.Add(enterConditionGroupAST(alt));
            }
            return(achievement);
        }
Ejemplo n.º 2
0
        private RootAST parseRoot()
        {
            RootAST root = new RootAST();

            root.Core = parseConditionGroup();

            while (!IsEOF)
            {
                // Eat 'S'
                _ = eatToken();

                var alt = parseConditionGroup();
                root.Alternates.Add(alt);
            }

            return(root);
        }
Ejemplo n.º 3
0
 public static AchievementInstruction FromAST(RootAST rootAst)
 {
     return(enterRootAST(rootAst));
 }