Author Topic: Bullets Gravity?  (Read 1088 times)

how do i change the bullets gravity like for the bow the arrow goes stright and goes down a little , how do i control it so it will just pop out of the weapon and onto the floor cause im working on the demogun from teamfortress 2

In your ProjectileData datablock, put isBallistic = True;  instead of False;

Then, change the gravMod = 0.0; value, to say 1.0;  or whichever value. Test it out and if it falls too slowly, make it a larger number.

Code: [Select]
AddDamageType("Lasher",   '<bitmap:add-ons/ci/Lasher> %1',    '%2 <bitmap:add-ons/ci/Lasher> %1',0.5,1);
datablock ProjectileData(LasherProjectile)
{
   projectileShapeName = "./shapes/LasherBullet.dts";
   directDamage        = 50;
   directDamageType    = $DamageType::Lasher;
   radiusDamageType    = $DamageType::Lasher;

   brickExplosionRadius = 10;
   brickExplosionImpact = true;          //destroy a brick if we hit it directly?
   brickExplosionForce  = 10;
   brickExplosionMaxVolume = 1;          //max volume of bricks that we can destroy
   brickExplosionMaxVolumeFloating = 2;  //max volume of bricks that we can destroy if they aren't connected to the ground

   impactImpulse      = 700;
   verticalImpulse   = 1000;
   explosion           = LasherExplosion;
   particleEmitter     = LasherTrailEmitter;

   muzzleVelocity      = 80;
   velInheritFactor    = 1;

   armingDelay         = 00;
   lifetime            = 4000;
   fadeDelay           = 3500;
   bounceElasticity    = 0.7;
   bounceFriction      = 0.40;
   isBallistic         = false;                       //This part here, set it to True instead of False
   gravityMod = 0.0;                              //Then, set this to a Positive non-zero number

   hasLight    = true;
   lightRadius = 10.0;
   lightColor  = "0 0 0.3";
};

would it be ok if i send the files to you and tou can script it for me ?

would it be ok if i send the files to you and tou can script it for me ?

No. You need to LEARN how the hell it's done, and if you post your problems on the forums then others might learn as well.

Simply sending me the files and having me change them won't help you very much in the grand scheme of things.

Agreed, we don't need another Mr.Pickle asking for coding help at least once for every script he makes.