So i'm working on a invaders project for school and i'm trying to add a power up that make the player shoot two bullets at once instead of the default single bullet. Any help would be greatly appreciated! Thanks!
Just add a boolean field to the player class; call it 'doubleShooting'. When the power-up is collected, change its value to true. In the method for shooting, add the code to shoot two bullets instead of one if the value of the field is true, and shoot only one bullet if the value of the field is false.