Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

at the moment i'm developing a 3D-Vector-Coordinates-to-2D-Canvas-Calculation.
the code is ready, the canvas too, but something doesn't work right...
You can find my code at

I've posted my question already on, but there nobody could help me...

Already now, thanks for your answers ;)

Greetings P.M.

share|improve this question

closed as too localized by Byte56, Le Comte du Merde-fou, doppelgreener, Ricket Oct 15 '12 at 14:26

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Hey PM, welcome to the site. Unfortunately these types of questions are not a good fit for the site. Essentially this is "Here's my code, where's my problem?". You'll need to narrow down the problem to a small section of code, try to solve it and it you can't tell us what the problem is, how you tried to solve it, and why it didn't work. See the FAQ about what types of questions to ask here. – Byte56 Oct 13 '12 at 15:44
Well, that IS my problem. I tried to figure out where the problem is, but no one saw anything and the browser keeps saying: "script isn't answering"... I debugged it with firebug, until there was no more fault, but this failure continues... – Philip März Oct 13 '12 at 20:32
Please read this and update your question: – Le Comte du Merde-fou Oct 13 '12 at 21:15
up vote 1 down vote accepted

This line is the problem:

 for(var i=0;i<numberpoints;i+2) {

Change the i+2 to i += 2 because it is currently running as an endless loop.

share|improve this answer

If I may recommend, PlayN is a very interesting game engine, in that it has direct support for both desktop and HTML. It is started by some Google people, and was actually used for porting Angry Birds to HTML. Check it out at They already have rendering to both Canvas and WebGL, all automatically done for you.

share|improve this answer
Ok, good point for future projects, but for this one, i need a specific one... For this reason i wrote it, otherwise i would have used this one ;) – Philip März Oct 13 '12 at 20:46
You can try asking your question on their mailing list... They should have a high concentration of web/HTML graphics people there. – MikiJ Oct 13 '12 at 20:53

Not the answer you're looking for? Browse other questions tagged or ask your own question.