viernes, 6 de junio de 2008

Begining GSOC

Finally this week I'm less constrained by school work, I have already finished most courses, only two are left for next week (pharmacology and immunology), thus I'm getting more and more free time to work on carcode.

It is unfortunate to lose 2 weeks, but I started working earlier and the code base is in good shape and ready to keep working.

Currently I'm working with sensors, I had the basic code but had some problems with positioning, I fixed that and now sensors are correctly positioned according car position and angle, the problem I had with this was that when rendering using usual OpenGL drawing functions, the origin is at the top left corner of the screen, however, when reading raw pixel data from backbuffer the origin is located at the bottom left corner of the screen, I catched this when I started drawing the sensors as small boxes.

The sensor will read it's data on the draw function of the car class, before the car is drawn, the sensor will read the pixel in a given position relative to the car center (the screen center).

I added the sensor class to the level script space as the class Sensor, you can also get the car class with the arena function Arena.get_car()

The next step is to add collision detection facilities, maybe I will start with placeholders to get to scripting faster, next would be car scripting, probably this would be a module or function that will be executed (like level scripts) after drawing each frame, but I still have concerns about parallel execution of rendering loop and car scripting, but this could be addressed later by the use of the threading module.

After adding some scripting facilities and documentation I will start making releases for courageous testers :)

No hay comentarios: