File tree 1 file changed +7
-6
lines changed
1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -285,11 +285,12 @@ local function OnCreateMove(pCmd)
285
285
end
286
286
287
287
closestPlayer = GetClosestEnemy (pLocal , pLocalOrigin , players )
288
+ -- handle lack of enemies
288
289
if closestPlayer == nil then
289
- if pWeapon : GetCritTokenBucket () <= 27 and mAutoRefill : GetValue () == true then
290
- pCmd :SetButtons (pCmd :GetButtons () | IN_ATTACK )-- refill
291
- end
292
- goto continue end
290
+ if mAutoRefill : GetValue () and pWeapon : GetCritTokenBucket () <= 27 then
291
+ pCmd :SetButtons (pCmd :GetButtons () | IN_ATTACK )
292
+ end goto continue
293
+ end
293
294
294
295
vPlayerOrigin = closestPlayer :GetAbsOrigin ()
295
296
@@ -359,8 +360,8 @@ if closestPlayer == nil then
359
360
--warp.TriggerDoubleTap()
360
361
end]]
361
362
362
- elseif isMelee and not stop and pWeapon : GetCritTokenBucket () <= 27 and mAutoRefill : GetValue () == true then
363
- if fDistance > 400 then
363
+ elseif mAutoRefill : GetValue () and isMelee and not stop then
364
+ if pWeapon : GetCritTokenBucket () <= 27 and fDistance > 400 then
364
365
pCmd :SetButtons (pCmd :GetButtons () | IN_ATTACK )-- refill
365
366
end
366
367
end
You can’t perform that action at this time.
0 commit comments