#include "../g_subs.qh"
#include "../antilag.qh"
-#include "../../common/constants.qh"
-#include "../../common/util.qh"
+#include <common/constants.qh>
+#include <common/util.qh>
-#include "../../common/weapons/all.qh"
+#include <common/weapons/all.qh>
-#include "../../lib/warpzone/common.qh"
+#include <lib/warpzone/common.qh>
// this function calculates w_shotorg and w_shotdir based on the weapon model
// offset, trueaim and antilag, and won't put w_shotorg inside a wall.
if (IS_PLAYER(ent) && accuracy_canbegooddamage(ent))
accuracy_add(ent, PS(ent).m_weapon.m_id, maxdamage, 0);
- W_HitPlotAnalysis(ent, v_forward, v_right, v_up);
+ if(IS_PLAYER(ent))
+ W_HitPlotAnalysis(ent, v_forward, v_right, v_up);
.entity weaponentity = weaponentities[0]; // TODO: unhardcode
vector md = ent.(weaponentity).movedir;
soundtoat(MSG_ONE, pseudoprojectile, beampos, CH_SHOTS, snd, VOL_BASE * f, ATTEN_NONE);
}
));
- FOR_EACH_REALCLIENT(msg_entity)
- if(msg_entity != self)
- if(!msg_entity.railgunhit)
- if(!(IS_SPEC(msg_entity) && msg_entity.enemy == self)) // we use realclient, so spectators can hear the whoosh too
- {
-
- }
if(pseudoprojectile)
remove(pseudoprojectile);