Originally Posted by
kung foo man
No clue what you are trying to do, but you take the eye pos from
eAttacker, but add the forward direction of
self to it. Do you mean this?
PHP Code:
fw = anglestoforward(eAttacker getplayerangles());
And since
getRealEye isn't a default function, just help people to understand your code by linking to its parts:
https://github.com/kungfooman/cod2_s...utils.gsc#L184
For debugging, you can either print the coordinates or just spawn some entities to that position
with silent aim if player shoots (x , y , z) point , his bullets hits to (r , s , t) point. i am trying to find these points , thats what i am trying to do.
PHP Code:
check( eVictim , eInflictor , eAttacker , iDamage , iDFlags , sMeansOfDeath , sWeapon , vPoint , vDir , sHitLoc , timeOffset )
{
start = eAttacker getRealEye();
fw = anglestoforward(eAttacker getplayerangles());
end = start + maps\mp\_utility::vectorscale( fw, 10000 );
trace = bulletTrace(start, end, true, eAttacker);
if( trace["position"] == vPoint )
return false ;
iPrintln("silent aim detected");
return true;
}
getRealEye()
{
player = self;
stance = player getStance();
offset = 0;
switch (stance)
{
case "stand": offset = 20; break;
case "duck": offset = 0; break;
case "lie": offset = -30; break;
//default: offset = getcvarint("offset");
}
realEye = player getEye() + (0,0,offset);
return realEye;
}
Originally Posted by
maxdamage99
If player kill enemy in VERY SUPER SPEED MOUSE
?
it happens in same frame , i dont think so it will be wrong
Originally Posted by
voron00
vPoint is the point of where the damage was taken, not bullet fired.
how they cant be the same ? so there is a way to detect it ?