- antilag_takeback(trace_ent, time - lag);
- hitplot = W_HitPlotNormalizedUntransform(org, trace_ent, screenforward, screenright, screenup, trace_endpos);
- antilag_restore(trace_ent);
- fputs(player.hitplotfh, strcat(ftos(hitplot.x), " ", ftos(hitplot.y), " ", ftos(hitplot.z), " ", ftos(player.switchweapon), "\n"));
+ entity store = IS_CLIENT(trace_ent) ? CS(trace_ent) : trace_ent;
+ antilag_takeback(trace_ent, store, time - lag);
+ vector hitplot = W_HitPlotNormalizedUntransform(org, trace_ent, screenforward, screenright, screenup, trace_endpos);
+ antilag_restore(trace_ent, store);
+ fputs(CS(player).hitplotfh, strcat(ftos(hitplot.x), " ", ftos(hitplot.y), " ", ftos(hitplot.z), " ", ftos(player.(weaponentity).m_switchweapon.m_id), "\n"));