package edu.stuy.starlorn.upgrades;

public class DoubleShotUpgrade extends GunUpgrade {
    private int _shotNum;

    public DoubleShotUpgrade() {
        super();
        _shotNum = 0;
    }

    @Override
    public int getNumShots() {
        return 2;
    }

    @Override
    public double getAimAngle() {
        if (_shotNum == 0) {
            _shotNum++;
            return Math.PI/8;
        } else if (_shotNum == 1) {
            _shotNum--;
            return -Math.PI/8;
        } else { // If those failed, something weird is going on, reset and aim straight.
            _shotNum = 0;
            return 0;
        }
    }
}

@@ -94,19 +94,23 @@
 private 
-int
+boolean
  _shotNu
@@ -178,25 +178,29 @@
  _shotNum = 
-0
+false
 ;%0A    %7D%0A%0A   
@@ -310,24 +310,51 @@
 imAngle() %7B%0A
+        int direction = 0;%0A
         if (
@@ -365,13 +365,8 @@
 tNum
- == 0
 ) %7B%0A
@@ -389,10 +389,20 @@
 tNum
-++
+ = !_shotNum
 ;%0A  
@@ -415,24 +415,21 @@
     
-return Math.PI/8
+direction = 1
 ;%0A  
@@ -445,24 +445,25 @@
 lse if (
+!
 _shotNum
  == 1) %7B
@@ -458,13 +458,8 @@
 tNum
- == 1
 ) %7B%0A
@@ -482,10 +482,20 @@
 tNum
---
+ = !_shotNum
 ;%0A  
@@ -508,174 +508,71 @@
     
-return -Math.PI/8;%0A        %7D else %7B // If those failed, something weird is going on, reset and aim straight.%0A            _shotNum = 0;%0A            return 0;%0A        %7D
+direction = -1;%0A        %7D%0A        return direction * Math.PI/8;
 %0A   

Change DoubleShot to use a boolean