Something code from sm_hosties of this function
PHP Code:
// setup beam
decl Float:Prisoner_Pos[3], Float:Guard_Pos[3], Float:distance;
GetClientEyePosition(LR_Player_Prisoner, Prisoner_Pos);
Prisoner_Pos[2] -= 40.0;
GetClientEyePosition(LR_Player_Guard, Guard_Pos);
Guard_Pos[2] -= 40.0;
distance = GetVectorDistance(Prisoner_Pos, Guard_Pos);
if (distance > gShadow_LR_HelpBeams_Distance)
{
TE_SetupBeamPoints(Prisoner_Pos, Guard_Pos, LaserSprite, LaserHalo, 1, 1, 0.1, 5.0, 5.0, 0, 10.0, greyColor, 255);
TE_Send(clients, 2);
TE_SetupBeamPoints(Guard_Pos, Prisoner_Pos, LaserSprite, LaserHalo, 1, 1, 0.1, 5.0, 5.0, 0, 10.0, greyColor, 255);
TE_Send(clients, 2);
}
Is this function what you wanted?
__________________