Just adding this for the people not looking to read a whole bunch of text, at least read this and look at the picture to understand my question; I have collision set up between the "player" and "objects", so that when the "player&...
I have got a little function in javascript and I want to split an array A into a 2d array. I will be used for square matrices. Obviously,I want it to be 2x2 if a square matrix of 2x2 is in the input and so on for 3x3 and. But I'm stuck after havi...
i want to use the phones accelerometer for rolling a Ball in a Ball. The movement works correctly, the problem is that when the ball hits the Wall. How can i get a smooth rolling animation that the ball slides along the inner side of the bigger ball?...
Let's say that I have the coordinates of a line (25,35 45,65, 30,85 - It would be a two part line). I need to move a point (car) along that line at a constant distance every frame. How can I do this?...
I have a 2D array that is 30 across, 20 down. However, the viewport only paints 15 across and 10 down. I had a game like that originally and I've been trying to achieve something like this:    Here's my fiddle: http://jsfiddle.net/sTr7q/...
I have a rather simple bird's-view 2D game where tower sprites defend against incoming moving sprites by shooting a bullet at them. My question: How do I calculate the needed bullet speed for the bullet to reach its moving target, provided that t...
How would I get 4 points rotated a certain degrees around a pointer to form a rectangle? I can rotate a point around a point, but I can't offset it to make a rectangle that isn't distorted....
Solved, see bottom of post for final algorithm  Background: I am working on a 2D platformer using JS and the HTML canvas element. The level map is tile-based, but the player is not clamped to the tiles. I am using a collision detection algorithm outl...
I am able to load image on canvas but now I want to replace the Image with pdf file. How to load Pdf file on Canvas as a image.src?...
So, I'm really interested in starting an HTML5/JavaScript project that mimics this type of 2.5D style: http://superflashbros.net/2009/02/22/blue-rabbits-climate-chaos/  I'm personally trying to stay away from third-party scripts, and just kee...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.