seta g_nexball_safepass_holdtime 0.75 // How long to remeber last teammate you pointed at
seta g_nexball_viewmodel_scale 0.25 // How large the ball for the carrier
seta g_nexball_viewmodel_offset "8 8 0" // Where the ball is located on carrier "forward right up"
+seta g_nexball_tackling 1 // Allow ball theft?
+
seta g_ctf_win_mode 0 "0: captures only, 1: captures, then points, 2: points only"
seta g_ctf_ignore_frags 0 "1: regular frags give no points"
float autocvar_g_nexball_safepass_maxdist;
float autocvar_g_nexball_safepass_holdtime;
float autocvar_g_nexball_viewmodel_scale;
+float autocvar_g_nexball_tackling;
vector autocvar_g_nexball_viewmodel_offset;
void basketball_touch();
void W_Nexball_Attack2(void)
{
- if(ball.enemy)
+ if(self.ballcarried.enemy)
{
- ball.think = W_Nexball_Think;
- ball.nextthink = time;
- DropBall(ball, w_shotorg, trigger_push_calculatevelocity(ball.origin, ball.enemy, 32));
+ self.ballcarried.think = W_Nexball_Think;
+ self.ballcarried.nextthink = time;
+ DropBall(self.ballcarried, w_shotorg, trigger_push_calculatevelocity(self.ballcarried.origin, self.ballcarried.enemy, 32));
return;
}
-
+
+ if(!autocvar_g_nexball_tackling)
+ return;
+
entity missile;
if(!(balls & BALL_BASKET))
return;