Game Development Community

Bug: PhysX demo: ProjectileData muzzleVelocity issue

by Alex Huck · in Torque 3D Professional · 04/30/2009 (11:48 pm) · 4 replies

Hi,
For the PhysX demo:
After I went into game/art/datablocks/rocketLauncher.cs and changed line 393 from muzzleVelocity = 100; to muzzleVelocity = 20;
I then went a little distance away from the objects, and fired a shot at the sky. I saw, as expected, a slow moving projectile.

However I found if I aim at anything other than the sky, there is no projectile, instead it instantly causes an explosion at the point under my crosshair.

I'm running the latest version (2.8.1) of the nVidia PhysX SDK,
latest directX SDK and video drivers.
System specs:
Windows XP,
Core2duo e6600,
4 GB of ram,
Geforce GTX-285
Compiled with MS VS 2008 pro


#1
04/30/2009 (11:54 pm)
Hum... i'm sure i've seen this bug before without changing muzzleVelocity. Its probably a related issue... but its good to know how to recreate it.

I suppose the PhysX collision test is hitting the player bounds or something like that.

Thanks for the bug report!
#2
04/30/2009 (11:59 pm)
Yes, I tried reverting my changes on muzzleVelocity, setting it back to 100, and it still had problems
#4
06/01/2009 (1:14 pm)
Fixed!
In pxWorld.cpp line 659, in PxWorld::castRay...
//NxF32 maxDist = worldRay.dir.magnitude() + 200.0f;
//Changed to...
NxF32 maxDist = worldRay.dir.magnitude();