0
0
Fork 0
mirror of https://github.com/liabru/matter-js.git synced 2024-11-23 09:26:51 -05:00

appease jshint

This commit is contained in:
liabru 2014-04-29 15:29:21 +01:00
parent a46851597a
commit 23a0fce2c0
4 changed files with 10 additions and 9 deletions

View file

@ -905,10 +905,10 @@
if (renderController.clear) if (renderController.clear)
renderController.clear(_engine.render); renderController.clear(_engine.render);
if (Events) { /*if (Events) {
// clear all events // clear all events
//Events.off(_engine); Events.off(_engine);
} }*/
_engine.enableSleeping = false; _engine.enableSleeping = false;
_engine.world.gravity.y = 1; _engine.world.gravity.y = 1;

View file

@ -372,13 +372,13 @@ var Composite = {};
object; object;
switch (type) { switch (type) {
case 'body': case 'body':
objects = Composite.allBodies(composite); objects = Composite.allBodies(composite);
break; break;
case 'constraint': case 'constraint':
objects = Composite.allConstraints(composite); objects = Composite.allConstraints(composite);
break; break;
case 'composite': case 'composite':
objects = Composite.allComposites(composite).concat(composite); objects = Composite.allComposites(composite).concat(composite);
break; break;
} }

View file

@ -17,8 +17,9 @@ var Query = {};
* @return {object[]} Collisions * @return {object[]} Collisions
*/ */
Query.ray = function(bodies, startPoint, endPoint, rayWidth) { Query.ray = function(bodies, startPoint, endPoint, rayWidth) {
rayWidth = rayWidth || Number.MIN_VALUE;
var rayAngle = Vector.angle(startPoint, endPoint), var rayAngle = Vector.angle(startPoint, endPoint),
rayWidth = rayWidth || Number.MIN_VALUE,
rayLength = Vector.magnitude(Vector.sub(startPoint, endPoint)), rayLength = Vector.magnitude(Vector.sub(startPoint, endPoint)),
rayX = (endPoint.x + startPoint.x) * 0.5, rayX = (endPoint.x + startPoint.x) * 0.5,
rayY = (endPoint.y + startPoint.y) * 0.5, rayY = (endPoint.y + startPoint.y) * 0.5,

View file

@ -175,7 +175,7 @@ var Vertices = {};
* @param {number} scaleY * @param {number} scaleY
* @param {vector} point * @param {vector} point
*/ */
Vertices.scale = function(vertices, scaleX, scaleY, point) { Vertices.scale = function(vertices, scaleX, scaleY, point) {
if (scaleX === 1 && scaleY === 1) if (scaleX === 1 && scaleY === 1)
return vertices; return vertices;
@ -192,6 +192,6 @@ var Vertices = {};
} }
return vertices; return vertices;
}; };
})(); })();