Permalink
Browse files

Avoid shooting when not pointing to the target

  • Loading branch information...
1 parent 5b2576f commit 9a32e99698395e3f47d41fef0318afbb7b18698e @fisadev fisadev committed Jul 9, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 bots/fisa.py
View
@@ -41,7 +41,8 @@ def point_and_shoot(self, target):
self.angle)
# aim and shoot
self.command('turn', value=turn)
- self.command('fire')
+ if turn < 0.5:
+ self.command('fire')
def wall_between(self, position):
for wall_side in self.wall_sides:

0 comments on commit 9a32e99

Please sign in to comment.