This website works better with JavaScript.
Home
Explore
Help
Sign In
jrtechs
/
jrtechs-Club-Panda
mirror of
https://github.com/jrtechs/Club-Panda.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Releases
0
Wiki
Activity
Browse Source
Prevented the particles from going off screen
pull/1/head
jrtechs
7 years ago
parent
7495189694
commit
b5768bd866
1 changed files
with
15 additions
and
3 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+15
-3
games/bamboofield.html
+ 15
- 3
games/bamboofield.html
View File
@ -113,6 +113,15 @@
}
}
if(this.x
<
0
)
{
this.x += this.speed;
}
else if(this.x > width)
{
this.x -= this.speed;
}
}
}
@ -123,12 +132,15 @@
//object that falls from the sky
var Bamboo = function()
{
this.x = getRandomIntInclusive(0, width);
this.y = 0;
this.width = 25;
this.height = 75;
this.x = getRandomIntInclusive(0, width);
this.y = -this.height;
this.speed = 4;
@ -207,7 +219,7 @@
}
var count = 0;
var limit =
30
;
var limit =
25
;
var addBamboo = function()
{
count++;
Write
Preview
Loading…
Cancel
Save