## Day.. 2? 3? I've lost track!

I'm working in pyglet to make a FPM - First Person Moon! The idea is that you'll steer the moon around in space to collide with incoming asteroids to destroy them and save the planet.I have a github repo up (fair warning, it's a mess right now!): https://github.com/wwwtyro/AegisLuna

If you want to try it out, you'll need pyglet and numpy installed.

So the first thing I did was build a function for creating a sphere geometry and lighting normals:

Then texture coordinates:

Then a skysphere:

Finally, I've just gotten procedural asteroid shapes working:

I used the same code as I did for a sphere, but I changed the radius of each vertex by the value of 3d perlin noise at that point on the sphere. The lighting normals were calculated by looking at the finite difference derivative of the noise at the surface.

Next I am going to start shooting asteroids at the earth and get some collision detection going.

Quick question - how do you guys handle 2d interfaces in pyglet? GUI type things?

Thanks for looking!

-- wwwtyro

(log in to comment)

permianlizard on 2013/09/02 17:14:

OMW this looks awesome