You are not logged in. Login or Signup
Home » links » Link 932303 | Random

This is a link post Game: Missile Command[er] I made this!
I wrote it because of the html5.
Post your scores.
(, Fri 25 Jan 2013, 0:18, Reply)
This is a normal post 250
But I have no idea what's going on. I know of the game, never played it before though.
Edit: Switched to Chrome, makes more sense now, doesn't work properly in Opera.
Edit2: It's fantastic, by the way
(, Fri 25 Jan 2013, 0:24, Reply)
This is a normal post It might have some bugs.
Well, a lot, really. A javascript console of errors would be fab.
(, Fri 25 Jan 2013, 0:32, Reply)
This is a normal post Sorry, got distracted actually playing :P
It seems to totally ignore the cursor and all the missiles go south-east.
Then there are errors on impact: see zoril.co.uk/down/misscom.jpg
(, Fri 25 Jan 2013, 0:41, Reply)
This is a normal post Alright, I've seen that index error before.
It's a mess, I know. (boo hoo hoo I need to get my idioms together)
But it might have to do with concurrency and a lack of resource locking, but I'm still struggling with concurrent programming.

Using setinterval can of course create a, what did they say at 4thur? Cardigan integrity?
(, Fri 25 Jan 2013, 0:47, Reply)
This is a normal post Fixed it.
It seems Opera/IE use offsetX/offsetY, not layerX/layerY.
This seems to work:

mouse_x = (evt.layerX || evt.offsetX) - xy[0];
mouse_y = (evt.layerY || evt.offsetY) - xy[1];
(, Fri 25 Jan 2013, 1:22, Reply)
This is a normal post You send me diff I fix now.
Well I did anyway, man that's funky to parse!
But thank you for the patch!! Does it work now?

www.zettix.com/Graphics/js/missile_command.js

Diffs are hard because of the angle brackets...
< var x = 0;
< var y = 0;
< if (evt.layerX || evt.layerX == 0) { // Firefox
< x = evt.layerX; y = evt.layerY;
< } else if (evt.offsetX || evt.offsetX == 0) { // Opera
< x = evt.offsetX; y = evt.offsetY;
< }
< mouse_x = x - xy[0];
< mouse_y = y - xy[1];
---
> mouse_x = evt.layerX - xy[0];
> mouse_y = evt.layerY - xy[1];


(, Fri 25 Jan 2013, 1:35, Reply)
This is a normal post Aye, scrap those brackets, I edited
Hah, I see what you meanabout the brackets
1075,1076c1075,1076
< mouse_x = (evt.layerX || evt.offsetX) - xy[0];
< mouse_y = (evt.layerY || evt.offsetY) - xy[1];
---
> mouse_x = evt.layerX - xy[0];
> mouse_y = evt.layerY - xy[1];


edit: obviously this diff won't work now, but if you wanted to compress those if statements, this works too.
(, Fri 25 Jan 2013, 1:41, Reply)
This is a normal post But yes, it works lovely now :)

(, Fri 25 Jan 2013, 1:43, Reply)
This is a normal post I am but a mouse among capybaras.
But if I don't chew on something I'm afraid I might puncture my skull with unused curiosity.
(, Fri 25 Jan 2013, 1:55, Reply)
This is a normal post A wonderfully mad mouse
Anyway, time for me to stop shooting stuff in favour of bed I think
(, Fri 25 Jan 2013, 2:06, Reply)
This is a normal post
I admire people who can code, because I wish i could do it. I love games. I want to make games. I can't code. Or draw. Or do maths.
(, Fri 25 Jan 2013, 2:06, Reply)
This is a normal post I wrote this as a sort of step 0 for these kinds of javascript pieces of poop.
You can read 300 lines of code, you can make a game.
The missile command clone is built on this real basic stuff:
www.zettix.com/Graphics/js/dodge.html
Hit "view source" and just relax and read it casually. It will click after a short while and then you will have your mental tsunamis.
[Copyedited sneak misspellings inserted by cr3's nefarious code]
(, Fri 25 Jan 2013, 2:09, Reply)
This is a normal post
I just looked at your code. I think the problem here is that I'm quite thick.
(, Fri 25 Jan 2013, 2:23, Reply)
This is a normal post It isn't you.
Everything made sense until HTML. Then legions of retards took over. The majority of web development these days is fixing bugs. Most people get 5 nosebleeds before making their 1st web page. When faced with viewing html source most people prefer sticking needles through their eyelids using lemon juice as a lubricant. After a while questions like "my dick goes where" lose meaning and you just do it so it works.

Then you have bugs and scramble like someone dying in quicksand for arcane advice.

In this case posting to b3ta was such a line.
(, Fri 25 Jan 2013, 2:34, Reply)
This is a normal post FWIW it took me over a year to understand how to do this:
www.zettix.com/Graphics/js/yellowtables.html

I kind of love 3w schools for the same reason I hate them. They are brief, and they expect you to get it real fast.

Still, you won't find my oddball quadtree program on 3schools, but the wealth of knowledge is without compare. Bookmark them now.
www.w3schools.com/
I could cry in joy for the rest of my life if I wasn't so dysfunctional, but I make my living in front of a computer. How cool is that?
(, Fri 25 Jan 2013, 2:46, Reply)
This is a normal post If your interested start here...
www.codeacademy.com

It'll get you all the basics and hopefully drive you enought o learn more. I'm currently working through the python. I'm a PHP dev but want to learn python for making shit games. Most languages have the same basic logic, but the syntax is different is all!
(, Fri 25 Jan 2013, 8:09, Reply)
This is a normal post Second that
Opera not co-operating well with this at all.
(, Fri 25 Jan 2013, 0:49, Reply)
This is a normal post I'd better craft a sorry letter for the QOTW.
Until then, I am deeply apologetic with regard to the incompatability with Apple's lovely renegade browser. While not having Opera myself is no excuse, pointing out browser friendliness is difficult will win no accolades, so submit to the blame. I am deeply sorry.
(, Fri 25 Jan 2013, 0:55, Reply)
This is a normal post 53030
Was hindered on the first level by not realising that A, S, and D fired the 3 interceptor stations.
Love me some Missile Command though. I used to rule at that game! =D
*clicky*
(, Fri 25 Jan 2013, 0:32, Reply)
This is a normal post A W D also work.
But I like games that don't tell you right away how they work! That's the new fun!
(, Fri 25 Jan 2013, 0:33, Reply)
This is a normal post 90175 on second go.
*smug*
(, Fri 25 Jan 2013, 0:46, Reply)
This is a normal post 123595
I'm enjoying this! =D
(, Fri 25 Jan 2013, 8:02, Reply)
This is a normal post nicely done
fun little distraction
(, Fri 25 Jan 2013, 0:50, Reply)
This is a normal post I didn't fire a thing
but still got 500. How do you fire? Don't tell me there are instructions to read, coz I won't.
(, Fri 25 Jan 2013, 1:24, Reply)
This is a normal post
A S D
(, Fri 25 Jan 2013, 1:39, Reply)
This is a normal post P also pauses.
I thought that was boss.
(, Fri 25 Jan 2013, 1:43, Reply)
This is a normal post 99380
That's a really good version, nice one
(, Fri 25 Jan 2013, 3:51, Reply)
This is a normal post :D
76085 on first go.
(, Fri 25 Jan 2013, 4:02, Reply)
This is a normal post I approve of this code

(, Fri 25 Jan 2013, 8:19, Reply)
This is a normal post 50540
Wicked game - nice one :)
Needs a rollerball ;)
(, Fri 25 Jan 2013, 9:08, Reply)
This is a normal post ^^this!!
60090
(, Fri 25 Jan 2013, 9:58, Reply)