sleddog / pool Goto Github PK
View Code? Open in Web Editor NEWPool by Devin Gray
Home Page: http://www.devingray.com/pool
License: MIT License
Pool by Devin Gray
Home Page: http://www.devingray.com/pool
License: MIT License
Add a simple mute button to suppress sounds
Currently this is a 1 player toy game... This ticket could add a robot to play against.
Would be cool to have sound effects during collisions or when balls are potted.
Currently the graphics are all 2D. This experimental PR could demonstrate how to render 3D balls via HTML/Javascript + some other graphing library (Open GL, etc...)
This would require some work, in conjunction with the ability to play a 9 ball game. This ticket would expose a new option to switch racks
8 Ball
Snooker
Snooker requires a bunch of new but smaller balls and changes the pocket sizes too...
It is time... We need 8 ball rules and two player mode.
Currently the bumper collisions are treated as elastic collisions just like striking a mirror.
ball = this.balls[i];
//if potted, no collision with bumper
if(!ball.potted) {
if(ball.position.x > X_MAX-PREFS.bumperWidth-ball.radius || ball.position.x < 0+PREFS.bumperWidth+ball.radius) {
ball.velocity.x *= -1;
}
if(ball.position.y > Y_MAX-PREFS.bumperWidth-ball.radius || ball.position.y < 0+PREFS.bumperWidth+ball.radius) {
ball.velocity.y *= -1;
}
}
ball.update();
Note the velocity is simply flipped. We should account for some velocity decrease after striking the rubber bumper. Also make this rubber bounce be a preference.
There are no instructions on how to play (use the keyboard to fire the ball, select your x/y location of the cue, and the power...)
Add a README.md file to describe this repo and how to develop.
Currently the balls are rendered on a 2D plane. We could make this much better to render in 3D. Perhaps use an existing 3D library.
Scope of this ticket could be a proof of concept new 8 ball that rolls...
There are a few ways to cause odd collisions. This ticket will track improving the main collision detecting and resolution functions.
Add ability to play against another human player. Keep track of scores, who shoots next, etc...
To improve development, this ticket could split out the main index.html file's various javascript functions into separate javascript files.
When ball enters hole and resets position, it keeps rolling if there's still momentum left from last shot.
Currently there is no clear power bar for how hard the cue ball is hit. This ticket could add this ability.
The cue ball moves at an ultra-high speed that causes many strange collisions when the player does not aim for the first shot.
Currently the cue ball moves by sliding. This ticket could make the cue ball actually "roll" by positioning the red dots accurately as it rolls.
Currently you have to click a specific spot for the cue ball to be in order to aim. This ticket could add the ability to drag and move this "ghost" ball around using the mouse.
Currently the cue stick is visible during aiming. When the shot is fired the cue ball immediately has velocity and the cue stick disappears. This ticket to add a nice animation after the shot is hit that shows the cue stick go back (based on the amount of velocity selected) then forward, imparting velocity onto the cue ball.
We now have a cool power slider on the left side, but you have to use the mouse to fire the shot. This ticket could bring back the keyboard to "power up" the shot.
The longer you hold the keyboard, the stronger the shot will be (until it maxes out).
A quick press, will be a slow shot
A long hold and release, will be a power shot
Becarefull, maybe it's a trap!
Implement some additional rules of pool.
Track who is shooting, if they are solid/stripes, and if they hit the wrong ball first cause a foul to occur.
Currently there is no collision support for the pocket corners. This ticket could improve how the ball behaves when it strikes these points on the side pockets
There are a number of constants and settings that would be nice to expose in some type of properties panel.
Felt color
bumper color
Max velocity
Friction / max constants
etc...
Add a simple dialog that allows the user to set these, and setup for future settings to be added.
In an effort to make the game fit only on 1 screen (no horizontal or vertical scroll bars), this ticket could move around the power bar to the left side and make it vertical. Lets see how we can get the screen to be as simple as possible.
Add a link to the sleddog/pool github page on the bottom right hand area of the application.
Would be sweet to see how the cue ball would collide with the object ball and where that object ball would travel.
Add MIT license
When the cue ball scratches it is placed automatically... Have the user be able to place the ball in hand anywhere on the table.
Currently the game defaults to 8 ball. This ticket could simply have the game load a nine ball rack as opposed to the 8 ball rack
Ball velocity resets to 50 after firing and also occasionally refuses to shoot the ball. Unsure how to recreate the issue, but it might affect all devices. More testing would need to be done.
Currently there is an annoying delay for all the balls to become stationary (which is a new feature to prevent shots until all balls stop), but this makes for some waiting.
This ticket could tweak the value of table friction to a more playable value.
Currently when a ball is potted, it immediattely shows up in the rail (on the right side). It would be slick to have an animation showing the ball "sliding down the rail" to its spot.
There is no favico logo for this pool game. This ticket will add one (that is pool related).
Currently the felt color is statically defined (green). This ticket could add the ability for a user to change the felt color (maybe using a defined list, or ideally some color picker).
Currently there is no cue stick. This ticket could introduce a cue stick to the UI.
When the ball is potted (and soon when other sounds are added) it is set to a static value. This ticket could introduce variable sound volume based on impact energy. Faster collisions == louder
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.