Allow flipped shot patterns

This commit is contained in:
Anuke
2022-03-05 23:06:19 -05:00
parent 7bf25cc46e
commit cc3116f329
5 changed files with 43 additions and 4 deletions

View File

@@ -6,6 +6,14 @@ public class ShootBarrel extends ShootPattern{
/** offset of barrel to start on */
public int barrelOffset = 0;
@Override
public void flip(){
barrels = barrels.clone();
for(int i = 0; i < barrels.length; i += 3){
barrels[i] *= -1;
}
}
@Override
public void shoot(int totalShots, BulletHandler handler){
for(int i = 0; i < shots; i++){