by albanerendk Thu Jul 26, 2012 2:43 am
1312|navy101 wrote:stop hatin, aslong as he is not claiming the work to be his and he is not trying to sell it im fine by it, continue learning
Thanks for standing up to me
And yes guys, it's c+p but did I claim it was my work, nope.
I'm trying to change my current prediction into a ping prediction as Paradox said.
This is what I came up with.
I actually wrote that myself and yea, I know it's simple stuff ^^
- Code:
float fLatency = g_pEngine->GetNetChannelInfo()->GetLatency( FLOW_OUTGOING );
float fDelay = fLatency / 1000;
float vDelta = vEnemySpeed - vMySpeed; // this is the part where I need help.
Vector myVelocity = GetVelocity(pMe);
Vector enemyVelocity = GetVelocity(pEnemy);
vTarget += (vDelta * fDelay)
THe only thing I need is knowing the speed of myself and the enemy. Could any of you guys explain that to me?
Thanks in advance.