Difference between revisions of "3D Space Example.as"
From Organic Design wiki
(oops, didn't include ball) |
m |
||
Line 1: | Line 1: | ||
Mouse.hide(); | Mouse.hide(); | ||
allSpaces = []; | allSpaces = []; | ||
+ | #include "ball.as" | ||
#include "space.as" | #include "space.as" | ||
− | |||
// Instantiate a new 3D-space | // Instantiate a new 3D-space |
Revision as of 20:54, 24 March 2006
Mouse.hide(); allSpaces = [];
- include "ball.as"
- include "space.as"
// Instantiate a new 3D-space // - extends createEmptyMovieClip( name, layer ) createEmptySpace( 'mySpace', 1 ); allSpaces.push( mySpace ); mySpace._x = width / 2; mySpace._y = height / 2;
// Per frame function reduce() { now = new Date(); time = now.getTime(); for ( var i = 0; i < allSpaces.length; i++ ) if ( allSpaces[i].active ) allSpaces[i].reduce(); }
// Test object mySpace.create( [ 'torus', 'myTorus', 5, 200, 2000 ] );