Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
🚀
This server has been upgraded to GitLab release
15.7
.
🚀
Open sidebar
grains
grains-web
Commits
752c6d24
Commit
752c6d24
authored
May 17, 2017
by
Jens-Christian Fischer
Browse files
Fix bouncing
parent
1d9fa980
Changes
2
Hide whitespace changes
Inline
Side-by-side
mix.exs
View file @
752c6d24
...
...
@@ -3,7 +3,7 @@ defmodule Grains.Mixfile do
def
project
do
[
app:
:grains
,
version:
"0.0.
69
"
,
version:
"0.0.
70
"
,
elixir:
"~> 1.2"
,
elixirc_paths:
elixirc_paths
(
Mix
.
env
),
compilers:
[
:phoenix
,
:gettext
]
++
Mix
.
compilers
,
...
...
web/static/js/presencesketch.js
View file @
752c6d24
...
...
@@ -111,10 +111,10 @@ Boid.prototype.render = function() {
// Wraparound
Boid
.
prototype
.
borders
=
function
()
{
if
(
this
.
position
.
x
<
-
this
.
radius
)
this
.
velocity
.
x
=
-
this
.
velocity
.
x
;
if
(
this
.
position
.
y
<
-
this
.
radius
)
this
.
velocity
.
y
=
-
this
.
velocity
.
y
;
if
(
this
.
position
.
x
>
PresenceSketch
.
width
+
this
.
radius
)
this
.
velocity
.
x
=
-
this
.
velocity
.
x
;
if
(
this
.
position
.
y
>
PresenceSketch
.
height
+
this
.
radius
)
this
.
velocity
.
y
=
-
this
.
velocity
.
y
;
if
(
this
.
position
.
x
<
this
.
radius
)
this
.
velocity
.
x
=
-
this
.
velocity
.
x
;
if
(
this
.
position
.
y
<
this
.
radius
)
this
.
velocity
.
y
=
-
this
.
velocity
.
y
;
if
(
this
.
position
.
x
>
PresenceSketch
.
width
-
this
.
radius
)
this
.
velocity
.
x
=
-
this
.
velocity
.
x
;
if
(
this
.
position
.
y
>
PresenceSketch
.
height
-
this
.
radius
)
this
.
velocity
.
y
=
-
this
.
velocity
.
y
;
};
// Separation
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment