Exemple #1
0
        public AWorldNode(World world) :
            base(world)
        {
            this.nameTolevelNodes = new Dictionary <string, ALevelNode>();

            this.currentLevelNode  = null;
            this.nextLevelNodeName = null;
        }
Exemple #2
0
        public void UpdateCurrentLevelNode(World world)
        {
            if (string.IsNullOrEmpty(this.nextLevelNodeName) == false)
            {
                if (this.currentLevelNode != null)
                {
                    this.currentLevelNode.VisitEnd(world);
                }

                if (this.nameTolevelNodes.ContainsKey(this.nextLevelNodeName))
                {
                    this.currentLevelNode = this.nameTolevelNodes[this.nextLevelNodeName];
                    this.currentLevelNode.VisitStart(world);
                }

                this.nextLevelNodeName = null;
            }
        }