46 void cl_effects_lightningarc(
vector from,
vector to,
float seglength,
float drifts,
float drifte,
47 float branchfactor,
float branchfactor_add)
49 float length =
vlen(from - to);
50 if (length < 1)
return;
54 int steps =
min(16,
floor(length / seglength));
57 te_lightning1(
NULL, from, to);
61 float steplength = length / steps;
64 if (length > seglength)
66 for (
int i = 1; i < steps; i += 1)
68 float drift = drifts * (1 - (i / steps)) + drifte * (i / steps);
70 vector pos = pos_l + dirnew * steplength;
71 te_lightning1(
NULL, pos_l, pos);
78 te_lightning1(
NULL, pos_l, to);
82 te_lightning1(
NULL, from, to);
88 vector from = ReadVector();
92 if (autocvar_cl_effects_lightningarc_simple)
94 te_lightning1(
NULL, from, to);
98 float seglength = autocvar_cl_effects_lightningarc_segmentlength;
99 float drifts = autocvar_cl_effects_lightningarc_drift_start;
100 float drifte = autocvar_cl_effects_lightningarc_drift_end;
101 float branchfactor = autocvar_cl_effects_lightningarc_branchfactor_start;
102 float branchfactor_add = autocvar_cl_effects_lightningarc_branchfactor_add;
104 cl_effects_lightningarc(from, to, seglength, drifts, drifte, branchfactor, branchfactor_add);
#define NET_HANDLE(id, param)
vector(float skel, float bonenum) _skel_get_boneabs_hidden
#define REGISTER_NET_TEMP(id)