Quote:
Originally Posted by Silvers
Yeah, where are you putting the code?
Edit: I do this in one of my plugins:
PHP Code:
elay)
{
SetEntPropEnt(entity, Prop_Data, "m_hPhysicsAttacker", client);
SetEntPropFloat(entity, Prop_Data, "m_flLastPhysicsInfluenceTime", GetGameTime());
I think that last line might be required, I see it in a few of mine like this.
|
I did this, before moving the object.
PHP Code:
float f_Velocity[3], f_Power;
GetAngleVectors(f_Angles, f_Velocity, NULL_VECTOR, NULL_VECTOR);
f_Power = g_h_CvarChargerPower.FloatValue;
f_Velocity[0] *= f_Power;
f_Velocity[1] *= f_Power;
f_Velocity[2] *= f_Power;
SetEntPropEnt(i_Target, Prop_Data, "m_hPhysicsAttacker", i_Client);
TeleportEntity(i_Target, NULL_VECTOR, NULL_VECTOR, f_Velocity);
I will try the new method later, thank you.