summaryrefslogtreecommitdiff
path: root/frontend/2d/_collisions
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/2d/_collisions')
-rw-r--r--frontend/2d/_collisions/circle_line.html2
-rw-r--r--frontend/2d/_collisions/rectangle_line.html2
-rw-r--r--frontend/2d/_collisions/rectangle_line.js4
3 files changed, 2 insertions, 6 deletions
diff --git a/frontend/2d/_collisions/circle_line.html b/frontend/2d/_collisions/circle_line.html
index 038c759..b6712f3 100644
--- a/frontend/2d/_collisions/circle_line.html
+++ b/frontend/2d/_collisions/circle_line.html
@@ -6,7 +6,7 @@
<script src="/index.js"></script>
<link rel="stylesheet" href="/index.css">
<link rel="shortcut icon" href="/favicon/favicon.ico" type="image/x-icon">
- <link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600,300" rel="stylesheet" type="text/css">
+
<title>Physics for Games</title>
<script src="/_shared/math/vec2.js"></script>
diff --git a/frontend/2d/_collisions/rectangle_line.html b/frontend/2d/_collisions/rectangle_line.html
index 5db958c..b37f47c 100644
--- a/frontend/2d/_collisions/rectangle_line.html
+++ b/frontend/2d/_collisions/rectangle_line.html
@@ -6,7 +6,7 @@
<script src="/index.js"></script>
<link rel="stylesheet" href="/index.css">
<link rel="shortcut icon" href="/favicon/favicon.ico" type="image/x-icon">
- <link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600,300" rel="stylesheet" type="text/css">
+
<title>Physics for Games</title>
<script src="/_shared/math/vec2.js"></script>
diff --git a/frontend/2d/_collisions/rectangle_line.js b/frontend/2d/_collisions/rectangle_line.js
index dec5108..e42cc84 100644
--- a/frontend/2d/_collisions/rectangle_line.js
+++ b/frontend/2d/_collisions/rectangle_line.js
@@ -107,19 +107,15 @@
lLowerRight = multMat4ByVec2(pRectangle.model, vec2(pRectangle.width / 2.0, -pRectangle.height / 2.0));
if (doesPointIntersect(lLowerLeft, pLine)) {
- console.log('Lwer left');
lCollisionPoint = vec2(-pRectangle.width / 2.0, -pRectangle.height / 2.0);
return true;
} else if (doesPointIntersect(lUpperLeft, pLine)) {
- console.log('Upper left');
lCollisionPoint = vec2(-pRectangle.width / 2.0, pRectangle.height / 2.0);
return true;
} else if (doesPointIntersect(lUpperRight, pLine)) {
- console.log('Upepr right');
lCollisionPoint = vec2(pRectangle.width / 2.0, pRectangle.height / 2.0);
return true;
} else if (doesPointIntersect(lLowerRight, pLine)) {
- console.log('Lower right');
lCollisionPoint = vec2(pRectangle.width / 2.0, -pRectangle.height / 2.0);
return true;
}