Yeah, FX_FireBullets() is for multiplayer, it uses a filter with UsePredictionRules(), so the shot code is run first on the client, then on the server. When it's run on the server, it transmits a bullet to everyone but the person who fired.
The reason player->FireBullet() is doubling tracers is because when it's run on the server, it's not using a UsePredictionRules(), so it's transmitting the tracer and what not back to the shooter. In my opinion, your best bet is to use FX_FireBullets On Mon, 31 Jan 2005 20:48:14 -0500, r00t 3:16 <[EMAIL PROTECTED]> wrote: > Some posted about bullet tracers awhile back and I gave them a quick idea > how to fix it. > When testing a map I noticed the the mp5 was firing 2 bullets every time you > quickly pushed the fire button. > > So debugging the info it seems the > > FireBulletsInfo_t Fire; > Fire.m_iShots = 1; > Fire.m_vecSrc = pPlayer->Weapon_ShootPosition( ); > Fire.m_vecDirShooting = pPlayer->GetAutoaimVector( flSpread ); > Fire.m_vecSpread = GetBulletSpread(); > Fire.m_flDistance = MAX_TRACE_LENGTH; > Fire.m_iAmmoType = m_iPrimaryAmmoType; > Fire.m_iTracerFreq = 3; > Fire.m_iDamage = 8; > Fire.m_iPlayerDamage = 20; > Fire.m_pAttacker = (CBaseEntity *) pPlayer; > Fire.m_nFlags = 0; > Fire.m_flDamageForceScale = 0.95f; > > player->FireBullets( Fire ); // causes the double bullet problem, but I get > tracers. > // also the other interesting thing about the above code as it seems to > override some of the var's from the weapon scripts file? > > // commenting out the code below > // I do not get the extra bullet fired, but I do not get sounds etc. > // the above code does not seem to be for multiplayer? as it has no > prediction random seed? > > FX_FireBullets( > pPlayer->entindex(), > pPlayer->Weapon_ShootPosition(), > pPlayer->EyeAngles() + pPlayer->GetPunchAngle(), > GetWeaponID(), > Primary_Mode, > CBaseEntity::GetPredictionRandomSeed() & 255, > flSpread ); > > Im guessing that FX_FireBullets(); Is for multiplayer because of the > prediction? > > FireBulletsInfo_t Fire; > player->FireBullets( Fire ); is for single player? > > r00t 3:16 > CQC Gaming > www.cqc-gaming.com > > _______________________________________________ > To unsubscribe, edit your list preferences, or view the list archives, please > visit: > http://list.valvesoftware.com/mailman/listinfo/hlcoders > > _______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders

