Game Development Community

Projectiles Not Showing up at Certain Angles

by Charlie Sibbach · in Torque Game Engine · 01/18/2009 (3:08 pm) · 4 replies

This is a wierd one. I think I read about this somewhere, but I sure can't find it now. Anyway, I have a pretty standard ShapeBaseImage based weapon mounted on a vehicle that is firing fine, for the most part, except that at certain view angles the projectile particles aren't showing up. I'm having trouble characterizing the problem, but it also appears as if the particles are not showing up within a certain radius of the ship. Depending on my actual coordinates in space, the particles seem to appear from behind the ship or so far in front of it that it looks like the don't show up (and sometimes, even all the way scrolled out, they still don't).

I'm having a lot of trouble just characterizing the problem still. Has anybody else run into this one? At first I thought the muzzlepoint calculation code was wrong, but I stuck the ship at 0 0 0, and echoed the point and it's magnitude- magnitude was the same all around the circle and the point was right. But the projectile particles showed differently at different angles.

Any help, or even debugging advice, is much appreciated!

#1
01/18/2009 (3:57 pm)
Oh man, this is 10 times stranger than I thought. I brought up the net graph and looked, and turned up the radius on the sound so that I could hear the guns going off. The weapons aren't even FIRING consistently at all rotation angles! At one angle, both guns will fire pretty consistently, and the ghost count goes from 10 to 50 for all the projectiles. If I turn around, the guns stop firing at all- there are actually huge dead zones!

I've done a lot of things to the engine, but the only part of the weapon code I've mucked with is allowing 32 images/weapons and allowing you to change the mount point of the weapon in mountImage() instead of in the datablock; both were done from resources here on GG.

Any help is much appreciated!
#2
01/18/2009 (4:11 pm)
I cranked up the newPacketSize and packetRateToClient, based on the flight game example, and now things are firing quite nicely.

I have no idea why things were not working before based on rotation. It's totally baffling to me.
#3
01/19/2009 (1:31 pm)
@Charlie - not sure if it's the same thing as you mention angles but Torque does have issues with projectiles fired at high velocities and what you see is they are fired at close ranges you don't see the bullet fired or any collision.
#4
01/26/2009 (11:42 pm)
Andy: Torque seems to have a lot of problems with high velocities period! I never did figure out the cause of my problems, but the packet size/rate tweak fixed the symptoms.