Wednesday, June 13, 2012

Rocket Tank - Cursor Control and Particle Effects

I've added some basic functionality to the game. There's now a crosshair shown on screen that will follow the mouse. The gun from the tank will always point towards this crosshair, so that the player can actually aim their rockets. (Ya know, aiming is usually a good thing in a game where you have to shoot stuff.) I'm considering also rendering a laser sight that will make it easier for players to judge the angles of their shots, but only if it's absolutely necessary. Rendering a good looking laser seems pretty difficult.

Also, I tried messing with an addon for Blender called EasyEmit: it's basically a particle system designed to work in the game engine. I was able to tweak it to get a good flow of fire shooting from the back of the rocket. 


Just one little problem though- when the rocket object ends, the flame particles just freeze in midair and stay there. I'm guessing this is because the particle emitter is simply parented to the rocket, and gets deleted along with the rocket. This leaves the emitted particles to freeze, since the emitter object that tells them what to do is gone. Not sure what to do about that; I'll have to look into it.

I'm also working on a custom particle explosion using EasyEmit- it's pretty easy to use and implement (hence the name EasyEmit :P), and it's great that I can get some decent looking particle effects even with the presets.

The next thing to work on would be the actual rocket-bouncing mechanic. This will be a bit tricky, but I realized that I can actually use part of the code from the kart racer's AI system and implement it here. I'll explain it more in depth in my next post. Until then..... lemons. Don't take 'em.

No comments:

Post a Comment