Jump to content

[Complete] [Phaser] - Asteroids in a day.


Thigydaze
 Share

Recommended Posts

For 8hrs really amazing :) I like it. I have no real feedback, but a question/suggestion. Are the asteroids created somehow randomly (math) or do you have a set of possible shapes and just scale them?

 

Thanks, just option B - the asteroids are 3 png sprites to look as close to the originals, randomly assigned and scaled as you shoot them.

Link to comment
Share on other sites

It ran fine on my laptop, but it's just a black screen on my phone - Android L with Chrome.

8 hours though - I guess starting with a game framework helps a ton.

 

Thanks for the update. It now renders on a mobile, but doesn't play as it needs a whole new input mechanism obviously. I'm not a fan of 'virtual joysticks' on account of your fingers drift of the 'hotspots', just at the wrong time. Needs some thinking.   

Link to comment
Share on other sites

Thanks for the update. It now renders on a mobile, but doesn't play as it needs a whole new input mechanism obviously. I'm not a fan of 'virtual joysticks' on account of your fingers drift of the 'hotspots', just at the wrong time. Needs some thinking.   

 

Yeah, I'm trying to get touch-controls just right, too.

I was inspired by touchscreen Llamasoft games, especially Gridrunner; make the whole screen into a giant joystick. When you put your finger down, that becomes the center of the stick. If you drag farther away than some max distance from the center of stick, then the center gets ragged along. All my cave2d.com twin-stick stuff works like that - http://cave2d.com/fracas2 for example.

 

My stick controller code is at https://github.com/aaronwhyte/cave2d/tree/master/public_html/js/controls, and example use is at

https://github.com/aaronwhyte/cave2d/blob/master/public_html/fracas2/fracas2.js#L335

I don't do any platform detection - I just create stick controllers for keyboard, pointerlocked mouse, and touch, pipe them into a MultiStick which is a stick that adds together vectors from child sticks, and then the client code only knows that I passed it a Stick object, and doesn't care where the stick vector comes from.

 

I also had to capture and cancel all the touch-scrolling and junk for mobile browsers, which I think I handled entirely in my index.html pages, with meta-tags here:

https://github.com/aaronwhyte/cave2d/blob/master/public_html/fracas2/index.html#L6

and some prevent-default listeners here:

https://github.com/aaronwhyte/cave2d/blob/master/public_html/fracas2/index.html#L82

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...