Former-commit-id: b608bc09fad5bdd9172e69e94d21b9344b4b5dcd
This commit is contained in:
sasha240100 2016-12-22 07:39:28 +02:00
parent 96c7b06aa4
commit 4aada78bd6
22 changed files with 44 additions and 88 deletions

View File

@ -163,9 +163,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -191,7 +189,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -138,9 +138,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -166,7 +164,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -173,9 +173,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -201,7 +199,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -112,9 +112,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -140,7 +138,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -131,9 +131,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -159,7 +157,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -144,9 +144,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -172,7 +170,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -156,9 +156,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -184,7 +182,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -156,9 +156,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -184,7 +182,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -155,9 +155,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -183,7 +181,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -151,9 +151,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -179,7 +177,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -130,9 +130,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -158,7 +156,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -175,9 +175,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -203,7 +201,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -211,9 +211,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -239,7 +237,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -127,9 +127,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -155,7 +153,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -182,9 +182,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -210,7 +208,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -155,9 +155,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -183,7 +181,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -325,9 +325,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -353,7 +351,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -155,9 +155,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -183,7 +181,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -180,9 +180,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -208,7 +206,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -179,9 +179,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -207,7 +205,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -317,9 +317,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -345,7 +343,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,

View File

@ -151,9 +151,7 @@ function addBasicLights(world) {
function addPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
WHS.PlanePhysics = PHYSICS.RigidbodyComponent(WHS.Plane);
return new WHS.PlanePhysics({
return new (PHYSICS.$rigidBody(WHS.Plane, PHYSICS.PLANE))({
geometry: {
width: size,
height: size
@ -179,7 +177,7 @@ function addPlane(world) {
function addBoxPlane(world) {
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100;
return new WHS.Box({
return new (PHYSICS.$rigidBody(WHS.Box, PHYSICS.BOX))({
geometry: {
width: size,
height: 1,