yoric / bouncer Goto Github PK
View Code? Open in Web Editor NEWHTML5 game of bouncing balls
Home Page: http://yoric.github.com/bouncer
License: Mozilla Public License 2.0
HTML5 game of bouncing balls
Home Page: http://yoric.github.com/bouncer
License: Mozilla Public License 2.0
So far, the game is not fun.
Here is a possible design to make it fun:
We'll add special effects to ball kind/colors in followup issues. Here are a few ideas:
Edit See also #69.
Add a bonus object that increases health.
Requires #21.
When the ball bounces close to the edge of a pad, we should not apply purely a vertical/horizontal mirror, but modify it to make it feel more natural.
A special case of bonus in which we show not one but two objects, the ends of the portal. Whenever the ball collides with one of the ends of the portal, it immediately re-appears with the same speed at the other end of the portal.
Depends on issue #22.
At the moment, when we play the game on a computer, we see the mouse cursor. We should hide it.
Add a malus object that increases the speed of the ball that traverses it.
Requires #21.
Issue #20 indicates clearly that Bouncer doesn't work with Chrome because we use for (x of ...)
which Chrome doesn't implement yet.
We need to fix this.
To make the game installable under FirefoxOS / Firefox, it needs an application manifest.
Add two kinds of bonus objects:
Requires #21.
Every few seconds, display an object somewhere on the screen, with the following properties:
In future issues, we will add other kinds of bonus objects.
Add a bonus object that randomly changes the direction of the ball.
Requires #21.
To make the game playable, it must be possible to move the pads using the touchscreen.
Add a bonus object that destroys all the balls currently on screen.
Requires #21 .
When we create balls, we should assign them a kind and color.
From this point, whenever a ball bounces, its color changes a little, randomly.
We will use the color at a later stage for bonus/malus stuff.
The pads are ugly. We should have graphics for them.
At the moment, we write directly to ball.style.color
. This is too hardcoded and too low-level. Rather, we should:
ball.element.classList
instead of ball.style.color
.Since #22, we have a score, but its display is ugly. Make it nicer.
This can also serve later when/if we start displaying health.
Adding a green ball which increase the sprite length on collision and a red ball which decrease the sprite length on collision
Add a bonus/malus object (requires issue #21) that "eats" the balls. When a ball is eaten, it disappears.
For testing purposes, it would be useful to move all pads using the mouse.
The balls are ugly, we should have graphics for them.
See also issue #8
Add a color mixer bonus object that randomly changes the color of a ball.
Requires #21.
At the moment, the game never ends.
We should make it possible to lose:
health
of 100
;health
by 10
;health
reaches 0
, the game is over;health
by 1
(i.e. regenerate).This health should be visible somewhere, e.g. by the color of the background or that of the screen borders.
Assigned to @Yoric
Whenever the ball bounces on a pad, increase the score by 100 points.
The score should be displayed somewhere on the screen.
Make it possible to move the pads by tilting the phone instead of touching the screen.
The position of pads is shifted to the South and East by half of their width. Fix this.
The latest version flickers, most lilkely because we update screen.style.width
and screen.style.height
at each frame. We should only update them when the window has been resized, see https://developer.mozilla.org/en-US/docs/Web/API/Window.onresize
At the moment, sprites are moved by using style.left: ...
and style.top: ...
. It would be much faster if we used transform: translateX(...) translateY(...)
.
At the moment, we sometimes encounter the issue Game.Config
is undefined. We need to fix it.
Initially the score increases by 100 points per bounce. Progressively increase this when the game lasts longer.
We also need to display a message with the multiplier once we enter this multiplier mode.
This requires issue #22.
At the moment, the speed of the ball is constant. We should increase it progressively.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.