Exemplo n.º 1
0
        public Plane()
        {
            String         path   = GuiController.Instance.AlumnoEjemplosMediaDir + @"Jet_Pilot\caza\caza-TgcScene.xml";
            TgcSceneLoader loader = new TgcSceneLoader();
            TgcScene       scene  = loader.loadSceneFromFile(path);

            plane = scene.Meshes[0];
            plane.AutoTransformEnable = false;
            plane.setColor(Color.DarkGray);

            exhaust = scene.Meshes[1];
            exhaust.AutoTransformEnable = false;
            exhaust.setColor(Color.Orange);
            exhaust.AlphaBlendEnable = true;

            rollSpeed             = 2.5f;
            pitchSpeed            = 2.0f;
            velocidad_normal      = 0.6f;
            velocidad_aceleracion = 500.0f;

            initShaders();

            Reset();
        }