World {
  Name "Example World 2 (Cubes)";
  Version 0x00010101;

  Object {
    // first define the vertices
    Vertex A (-40,-40,-40);
    Vertex B ( 40,-40,-40);
    Vertex C ( 40, 40,-40);
    Vertex D (-40, 40,-40);
    Vertex E (-40,-40, 40);
    Vertex F ( 40,-40, 40);
    Vertex G ( 40, 40, 40);
    Vertex H (-40, 40, 40);
    // then define the polygons
    Poly (B,A,C);  // front
    Poly (D,C,A);  // front
    Poly (B,C,F);  // right
    Poly (G,F,C);  // right
    Poly (A,E,D);  // left
    Poly (H,D,E);  // left
    Poly (D,H,C);  // bottom
    Poly (G,C,H);  // bottom
    Poly (A,B,E);  // top
    Poly (F,E,B);  // top
    Poly (E,F,H);  // back
    Poly (G,H,F);  // back
    } Box80;
  }; // end of World block

Palette {
  Color 0    (96,0,96); 
  Color 32   (128,128,0);
  Color 255  (255,255,0);
  } SpecialYellow;

Palette {
  Color 0    (96,0,0);
  Color 32   (0,64,0);
  Color 255  (0,255,0);
  } SpecialGreen;

Scene {
  Name "Cubes";
  Version 0x00010101;
  Light (0,0,1);

  Item Box80 {
    Palette SpecialYellow;
    CmdStream Translation {
      Move   60  (0, -256, 512);
      Stay   100;
      Spline 120 (128, 0, 512) (0, 256, 400) 60 60;
      Stay   20;
      Move   120 (0, -256, 512);
      Orbit  240 (25, -200, 400) 0.0 2.2;  // Pc, Alpha(z) (degrees), V(theta) [degrees/frame]
      Move   120 (0, -256, 512);
      Orbit  120 BoxTwo 0.0 2.2;  // Object Name, Alpha(z) (degrees), V(theta) [degrees/frame]
      Stay   100;
      };
    CmdStream Rotation {
      Spin     60  -6.0;             // degrees/frame
      Stay     60;
      Move     120 0.0 -90.0 45.0;  // Phi(x) Phi(y) Theta(z)  [degrees]
      Stay     60;
      MoveSpin 120 4.5 90.0 0.0;    // V(Theta(z)) [degrees/frame] Phi(x) Phi(y) [degrees]
      Spin     60  6.0;             // degrees/frame
      Stay     60;
      };
    } BoxOne;


  Item Box80 {
    Palette SpecialGreen;
    CmdStream Translation {
      Move   60  (0, 256, 512);
      Stay   100;
      Spline 120 (-128, 0, 512) (0, -256, 400) 60 60;
      Stay   20;
      Move   120 (0, 256, 512);
      Stay   100;
      };
    CmdStream Rotation {
      Spin     60  6.0;             // degrees/frame
      Stay     60;
      Move     120 90.0 0.0 45.0;   // Phi(x) Phi(y) Theta(z)  [degrees]
      Stay     60;
      MoveSpin 120 3.0 0.0 -90.0;   // Phi(x) Phi(y) [degrees] V(Theta(z)) [degrees/frame]
      Spin     60  6.0;             // degrees/frame
      Stay     60;
      };
    } BoxTwo;


  Item Points {
    CmdStream Translation {
      Move 120 (0,-256,512);
      Stay 120;
      Move 120 (256,0,512);
      Stay 120;
      Move 120 (0,256,512);
      Stay 120;
      Move 120 (-256,0,512);
      Stay 120;
      Move 60 (0,0,400);
      Stay 60;
      };
    CmdStream Rotation {
      Stay 120;
      Move 180 90.0 0.0 90.0;
      Stay 60;
      Move 180 45.0 -45.0 120.0;
      Stay 60;
      Move 180 0.0 -45.0 180.0;
      Stay 60;
      Move 180 0.0 -90.0 180.0;
      Stay 60;
      Move 180 0.0 -90.0 -90.0;
      Stay 60;
      Move 180 0.0 0.0 0.0;
      // original position
      Spin 180 2.0;
      };
    CmdStream Morph {
      EmptyCube     60 1000 80;     // point spacing              [pixels]
      FilledCube    60 1000 80;     // point spacing              [pixels]
      BouncingCubes 60 720 800      // Arena Size                 [pixels]
                           70       // Cube Size                  [pixels]
                           8        // Inter Points               [count]
                           0.2539   // Gravity Strength           [coefficient]
                           0.39868  // Outer Spring Coefficient   [coefficient]
                           0.07629  // Outer Damper Coefficient   [coefficient]
                           0.58313  // Inner Spring Coefficient   [coefficient]
                           0.07019; // Inner Damper Coefficient   [coefficient]
      };  // end of morphing command stream


    };    // end of Points object definition
  
  };  // end of scene description


// end of file
