Where? I thunked I got them, but still has the noise.
//flashlight.cs
//flashlight trail effects
datablock ParticleData(flashlightTrailParticle)
{
dragCoefficient = 0;
gravityCoefficient = -0.0;
inheritedVelFactor = 60.0;
constantAcceleration = 10.0;
lifetimeMS = 525;
lifetimeVarianceMS = 55;
textureName = "";
spinSpeed = 10.0;
spinRandomMin = -500.0;
spinRandomMax = 500.0;
colors[0] = "0.3 0.3 0.9 0.4";
colors[1] = "0.5 0.5 0.5 0.0";
sizes[0] = 2;
sizes[1] = 1;
useInvAlpha = false;
};
datablock ParticleEmitterData(flashlightTrailEmitter)
{
ejectionPeriodMS = 3;
periodVarianceMS = 0;
ejectionVelocity = 0.0;
velocityVariance = 0.0;
ejectionOffset = 0.0;
thetaMin = 0;
thetaMax = 0;
phiReferenceVel = 0;
phiVariance = 0;
overrideAdvance = false;
particles = "flashlightTrailParticle";
};
datablock ParticleData(flashlightExplosionRingPartic le)
{
dragCoefficient = 8;
gravityCoefficient = -0.5;
inheritedVelFactor = 0.2;
constantAcceleration = 0.0;
lifetimeMS = 300;
lifetimeVarianceMS = 100;
textureName = "";
spinSpeed = 0.0;
spinRandomMin = 0.0;
spinRandomMax = 0.0;
colors[0] = "1 1 0.0 0.9";
colors[1] = "0.9 0.0 0.0 0.0";
sizes[0] = 0;
sizes[1] = 0;
useInvAlpha = false;
};
datablock ParticleEmitterData(flashlightExplosionRingEmitte r)
{
lifeTimeMS = 50;
ejectionPeriodMS = 1;
periodVarianceMS = 0;
ejectionVelocity = 5;
velocityVariance = 0.0;
ejectionOffset = 0.0;
thetaMin = o;
thetaMax = 0;
phiReferenceVel = 0;
phiVariance = 0;
overrideAdvance = false;
particles = "flashlightExplosionRingPartic le";
};
datablock ExplosionData(flashlightExplosion)
{
//explosionShape = "";
soundProfile = flashlightHitSound;
lifeTimeMS = 150;
particleEmitter = flashlightExplosionEmitter;
particleDensity = 10;
particleRadius = 0.2;
emitter[0] = flashlightExplosionRingEmitte r;
faceViewer = true;
explosionScale = "0 0 0";
shakeCamera = false;
camShakeFreq = "10.0 11.0 10.0";
camShakeAmp = "1.0 1.0 1.0";
camShakeDuration = 0.5;
camShakeRadius = 10.0;
// Dynamic light
lightStartRadius = 3;
lightEndRadius = 3;
lightStartColor = "0.3 0.6 0.7";
lightEndColor = "0 0 0";
impulseRadius = 0;
impulseForce = 0;
impactImpulse = 0;
verticalImpulse = 0;
};
AddDamageType("flashlight", '<bitmap:add-ons/ci/generic> %1', '%2 <bitmap:add-ons/ci/generic> %1',1,1);
datablock ProjectileData(flashlightProjectile)
{
//projectileShapeName = "";
directDamage = 0;
impactImpulse = 0;
verticalImpulse = 0;
impulseRadius = 0;
impulseForce = 0;
impactImpulse = 0;
verticalImpulse = 0;
explosion = flashlightExplosion;
//particleEmitter = as;
muzzleVelocity = 999999999;
velInheritFactor = 500;
armingDelay = 0;
lifetime = 2000;
fadeDelay = 90;
bounceElasticity = 0;
bounceFriction = 0;
isBallistic = false;
gravityMod = 0.0;
hasLight = true;
lightRadius = 25.0;
lightColor = "0 0 0.30";
};
//////////
// item //
//////////
datablock ItemData(flashlightItem)
{
category = "Weapon"; // Mission editor category
className = "Weapon"; // For inventory system
// Basic Item Properties
shapeFile = "./shapes/flashlight.dts";
rotate = false;
mass = 1;
density = 0.2;
elasticity = 0.2;
friction = 0.6;
emap = true;
//gui stuff
uiName = "Flashlight";
iconName = "./ItemIcons/flashlight";
doColorShift = false;
colorShiftColor = "1 1 1 1.000";
// Dynamic properties defined by the scripts
image = flashlightImage;
canDrop = true;
};
////////////////
//weapon image//
////////////////
datablock ShapeBaseImageData(flashlightImage)
{
// Basic Item properties
shapeFile = "./shapes/flashlight.dts";
emap = true;
// Specify mount point & offset for 3rd person, and eye offset
// for first person rendering.
mountPoint = 0;
offset = "0 0 0";
eyeOffset = 0;
rotation = eulerToMatrix( "0 0 10" );
// When firing from a point offset from the eye, muzzle correction
// will adjust the muzzle vector to point to the eye LOS point.
// Since this weapon doesn't actually fire from the muzzle point,
// we need to turn this off.
correctMuzzleVector = true;
// Add the WeaponImage namespace as a parent, WeaponImage namespace
// provides some hooks into the inventory system.
className = "WeaponImage";
// Projectile && Ammo.
item = flashlightItem;
ammo = " ";
projectile = flashlightProjectile;
projectileType = Projectile;
//melee particles shoot from eye node for consistancy
melee = false;
//raise your arm up or not
armReady = true;
doColorShift = false;
colorShiftColor = flashlightItem.colorShiftColo r;//"0.400 0.196 0 1.000";
//casing = " ";
// Images have a state system which controls how the animations
// are run, which sounds are played, script callbacks, etc. This
// state system is downloaded to the client so that clients can
// predict state changes and animate accordingly. The following
// system supports basic ready->fire->reload transitions as
// well as a no-ammo->dryfire idle state.
// Initial start up state
stateName[0] = "Activate";
stateTimeoutValue[0] = 0.01;
stateTransitionOnTimeout[0] = "Ready";
stateSound[0] = weaponSwitchSound;
stateName[1] = "Ready";
stateTransitionOnTriggerDown[1] = "Fire";
stateAllowImageChange[1] = true;
stateName[2] = "Fire";
stateTransitionOnTimeout[2] = "Smoke";
stateTimeoutValue[2] = 0.00000;
stateFire[2] = true;
stateAllowImageChange[2] = false;
stateSequence[2] = "Fire";
stateScript[2] = "onFire";
stateWaitForTimeout[2] = true;
stateEmitter[2] = flashlightFlashEmitter;
stateEmitterTime[2] = 0.0001;
stateEmitterNode[2] = "muzzleNode";
stateEjectShell[2] = true;
stateName[3] = "Smoke";
stateEmitter[3] = flashlightSmokeEmitter;
stateEmitterTime[3] = 0.0001;
stateEmitterNode[3] = "muzzleNode";
stateTimeoutValue[3] = 0.00000;
stateTransitionOnTimeout[3] = "Reload";
stateName[4] = "Check";
stateTransitionOnTriggerUp[4] = "StopFire";
stateTransitionOnTriggerDown[4] = "Fire";
stateName[5] = "StopFire";
stateTransitionOnTimeout[5] = "Ready";
stateTimeoutValue[5] = 0.00000;
stateAllowImageChange[5] = false;
stateWaitForTimeout[5] = true;
//stateSequence[5] = "Reload";
stateScript[5] = "onStopFire";
};